Skip to content

Commit

Permalink
fix edge case when beta is too low
Browse files Browse the repository at this point in the history
  • Loading branch information
adamchengtkc authored May 16, 2024
1 parent 818d861 commit 7e59d94
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions warmth/forward_modelling.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,9 @@ def _check_beta(self, wd_diff: float, beta_current: float, beta_all: np.ndarray[
"""
beta_found = False
beta_all = np.append(beta_all, beta_current)
if Wd_diff_all.size > 0:
if wd_diff >= Wd_diff_all[0]:
wd_diff +=1
Wd_diff_all = np.append(Wd_diff_all, wd_diff)
if wd_diff > 0:
beta_found = True
Expand Down

0 comments on commit 7e59d94

Please sign in to comment.