Skip to content

Commit

Permalink
nan check
Browse files Browse the repository at this point in the history
  • Loading branch information
abhisrkckl committed Jan 19, 2024
1 parent fdaf292 commit bf7df7c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/pint/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -2969,4 +2969,6 @@ def find_optimal_nharms(model, toas, component, nharms_max=45):
frozen=False,
)

assert all(np.isfinite(aics)), "Infs/NaNs found in AICs!"

return np.argmin(aics), np.array(aics) - np.min(aics)

0 comments on commit bf7df7c

Please sign in to comment.