Skip to content

Commit 850c4ab

Browse files
lcsamaweimingzha0
authored andcommittedJan 4, 2022
fix magic number
1 parent 6785e01 commit 850c4ab

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed
 

‎lib/transforms/analyzer.cc

+2-1
Original file line numberDiff line numberDiff line change
@@ -674,7 +674,8 @@ void Analyzer::GenerateRscInfo(std::ostream& os) {
674674
const float t4_flops = hw_paras_["GPU_t4"].max_flops;
675675
const float step_sz = 0.05;
676676
float cur_qps = 0;
677-
for (float step = step_sz; step <= 1.01; step += step_sz) {
677+
const float max_step = 1.01;
678+
for (float step = step_sz; step <= max_step; step += step_sz) {
678679
std::map<std::string, HWInfo> hw_paras_step = hw_paras_;
679680
hw_paras_step["GPU_t4"].conv_time *= 1 / step;
680681
hw_paras_step["GPU_t4"].mm_time *= 1 / step;

0 commit comments

Comments
 (0)