Update FlopCounterMode usage in throughput.py (#19926)
`mods` argument is not needed anymore for `FlopCounterMode`:
ffe506e853/torch/utils/flop_counter.py (L595-L596)
This commit is contained in:
parent
95d6b6b9da
commit
dffc0f96ec
|
@ -296,7 +296,7 @@ def measure_flops(
|
|||
raise ImportError("`measure_flops` requires PyTorch >= 2.1.")
|
||||
from torch.utils.flop_counter import FlopCounterMode
|
||||
|
||||
flop_counter = FlopCounterMode(model, display=False)
|
||||
flop_counter = FlopCounterMode(display=False)
|
||||
with flop_counter:
|
||||
if loss_fn is None:
|
||||
forward_fn()
|
||||
|
|
Loading…
Reference in New Issue