Skip to content

Commit

Permalink
fix: return averaged flops
Browse files Browse the repository at this point in the history
  • Loading branch information
marsggbo committed Apr 29, 2022
1 parent be59c7b commit e1084b9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hyperbox/utils/calc_model_size.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ def remove_buffer(m_):
total_params += m.total_params
# print("%s: %.2f %.2f" % (name, m.total_ops.item(), m.total_params.item()))

total_ops = total_ops.item()
total_ops = total_ops.item() / input_size[0]
total_params = total_params.item()

model.train(training).to(original_device)
Expand Down

0 comments on commit e1084b9

Please sign in to comment.