LSSTDESC / lsstdesc-diffsky

Library for differentiable generation of synthetic skies for LSST DESC
BSD 3-Clause "New" or "Revised" License
1 stars 0 forks source link

Log safe ssfr fix #82

Closed aphearin closed 8 months ago

aphearin commented 8 months ago

This PR fixes a bug in the formulation of test_get_log_safe_ssfr. The behavior of the get_log_safe_ssfr function is stochastic, and so the way this test was written, it sometimes fails and it sometimes passes, depending on the random number generator (this failure was caught here during our semi-weekly cron test, but not in the workflow run at the time of the PR). I have fixed this in two ways:

  1. I increased the number of tested points to 1e6 so that it always fails as it was originally written
  2. I relaxed the tolerance on the expectation of the returned values so that the random number generator never returns a value below the expected tolerance

@evevkovacs

codecov[bot] commented 8 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (3c6da50) 59.54% compared to head (01c1972) 59.54%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #82 +/- ## ======================================= Coverage 59.54% 59.54% ======================================= Files 93 93 Lines 6555 6555 ======================================= Hits 3903 3903 Misses 2652 2652 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.