Skip to content

Conversation

@dweindl
Copy link
Member

@dweindl dweindl commented Dec 3, 2025

To check for the type of objective function encoded in the PEtab problem.

@dweindl dweindl requested a review from a team as a code owner December 3, 2025 08:38
@codecov-commenter
Copy link

codecov-commenter commented Dec 3, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 75.21%. Comparing base (3d4ff07) to head (f5ae21a).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #463      +/-   ##
==========================================
+ Coverage   75.18%   75.21%   +0.02%     
==========================================
  Files          62       62              
  Lines        6856     6862       +6     
  Branches     1224     1224              
==========================================
+ Hits         5155     5161       +6     
  Misses       1234     1234              
  Partials      467      467              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@dweindl dweindl self-assigned this Dec 3, 2025
To check for the type of objective function encoded in the PEtab problem.
Copy link
Member

@dilpath dilpath left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Comment on lines +1842 to +1843
Note that this will default to uniform distributions over the
parameter bounds for parameters without an explicit prior.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add this to avoid invalid behavior? if self.has_ml_objective: return None

Comment on lines +1835 to +1837
return all(
p.prior_distribution is None for p in self.parameters if p.estimate
)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since it's binary

Suggested change
return all(
p.prior_distribution is None for p in self.parameters if p.estimate
)
return not self.has_map_objective

:returns: The prior distributions for the estimated parameters.
"""
return {p.id: p.prior_dist for p in self.parameters if p.estimate}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unrelated but Parameter.prior_dist seems confusing since it can differ from Parameter.prior_distribution. It seems like this default to the uniform distribution should be handled by Problem-level methods, rather than within the Parameter?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants