Skip to content

Commit

Permalink
Bugfix
Browse files Browse the repository at this point in the history
There is no need to assert this if we are only doing a single timestep for warmup
  • Loading branch information
eikehmueller committed Sep 11, 2024
1 parent 35a3ebc commit 94ab69a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/timesteppers/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ def get_timesteps(self, t_final, warmup):
"""
nt = 1 if warmup else int(np.round(t_final / self._dt)) # number of timesteps
# check that dt divides the final time
assert abs(nt * self._dt - t_final) < 1.0e-12
assert warmup or (abs(nt * self._dt - t_final) < 1.0e-12)
return nt

@property
Expand Down

0 comments on commit 94ab69a

Please sign in to comment.