-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Validator: check for positive bounds for log-scaled parameter #278
Conversation
Check the parameter table for positive bounds for log-scaled estimated parameters that don't have an explicit intialization prior. See discussion in PEtab-dev#259 Supersedes and closes PEtab-dev#259
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #278 +/- ##
===========================================
- Coverage 75.68% 75.65% -0.03%
===========================================
Files 40 40
Lines 4137 4141 +4
Branches 891 893 +2
===========================================
+ Hits 3131 3133 +2
- Misses 744 745 +1
- Partials 262 263 +1 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
if ( | ||
row.get(PARAMETER_SCALE, LIN) in [LOG, LOG10] | ||
and (row[LOWER_BOUND] == 0.0 or row[UPPER_BOUND] == 0.0) | ||
and not row.get(INITIALIZATION_PRIOR_TYPE) | ||
): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would move row[UPPER_BOUND] == 0.0
above, i.e. change row[UPPER_BOUND] < 0.0
to row[UPPER_BOUND] <= 0.0
-- does not make sense to estimate something that can only take the value 0.0
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lb=ub is allowed so far. I'd say things that are legal but dumb shouldn't raise exceptions. Although we might want to add some optional hints for improvement at some point.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fine for me 👍 Should we check the initialization prior then, to make sure it's sampling in finite bounds?
Check the parameter table for positive bounds for log-scaled estimated parameters that don't have an explicit intialization prior.
See discussion in #259
Supersedes and closes #259