Skip to content

Commit e30a504

Browse files
committed
added the changes
1 parent 7adad14 commit e30a504

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tests/tests_pytorch/trainer/optimization/test_optimizers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -703,7 +703,7 @@ def configure_optimizers(self):
703703

704704
# Calculate the total number of steps (iterations) and expected scheduler calls
705705
total_steps = 7 * 3 # Total iterations (7 batches per epoch * 3 epochs)
706-
expected_steps = total_steps // 5 # Scheduler steps every 5 iterations
706+
expected_steps = (total_steps-1) // 5 # Scheduler steps every 5 iterations
707707

708708
# Assert that the scheduler was called the expected number of times
709709
assert mocked_sched.call_count == expected_steps

0 commit comments

Comments
 (0)