Skip to content

Commit

Permalink
Comment with link to #381
Browse files Browse the repository at this point in the history
  • Loading branch information
PhilMiller committed Mar 30, 2020
1 parent cc0360c commit 3c65eef
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/penn_chime/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,8 @@ def get_loss(self) -> float:


def get_argmin_ds(census_df: pd.DataFrame, current_hospitalized: float) -> float:
# By design, this forbids choosing a day after the peak
# If that's a problem, see #381
peak_day = census_df.hospitalized.argmax()
losses_df = (census_df.hospitalized[:peak_day] - current_hospitalized) ** 2.0
return losses_df.argmin()
Expand Down

0 comments on commit 3c65eef

Please sign in to comment.