Skip to content
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

PEtab import: fix handling of fixed parameters for rule targets #1915

Merged
merged 2 commits into from
Dec 22, 2022

Conversation

dweindl
Copy link
Member

@dweindl dweindl commented Dec 21, 2022

Previously, targets of initial assignments or rules could have been selected as fixed parameters, which would lead to errors during model import. Those target parameters should be ignored.

Previously, targets of initial assignments or rules could have been selected as fixed parameters, which would lead to errors during model import. Those target parameters should be ignored.
@codecov
Copy link

codecov bot commented Dec 21, 2022

Codecov Report

Merging #1915 (a5d5f85) into develop (45e311b) will decrease coverage by 0.01%.
The diff coverage is 66.66%.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##           develop    #1915      +/-   ##
===========================================
- Coverage    76.01%   75.99%   -0.02%     
===========================================
  Files           76       76              
  Lines        12957    12960       +3     
===========================================
  Hits          9849     9849              
- Misses        3108     3111       +3     
Flag Coverage Δ
cpp 73.11% <ø> (-0.03%) ⬇️
petab 59.72% <66.66%> (+<0.01%) ⬆️
python 69.10% <0.00%> (-0.05%) ⬇️
sbmlsuite ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
python/sdist/amici/petab_import.py 65.86% <66.66%> (+<0.01%) ⬆️
src/sundials_matrix_wrapper.cpp 80.61% <0.00%> (-0.41%) ⬇️

@dweindl dweindl marked this pull request as ready for review December 21, 2022 15:56
@dweindl dweindl requested a review from FFroehlich December 21, 2022 15:56
@FFroehlich
Copy link
Member

Previously, targets of initial assignments or rules could have been selected as fixed parameters, which would lead to errors during model import. Those target parameters should be ignored.

Hmm, but this would be an invalid petab file then, right?

@dweindl
Copy link
Member Author

dweindl commented Dec 21, 2022

Hmm, but this would be an invalid petab file then, right?

No, I don't mean that the targets were specified as non-estimated in the parameters table, but that during amici import most non-estimated parameters are turned into fixed parameters for performance reasons. And the current logic tries to also do that for rule-targets, which is wrong. (Problem introduced in #1810)

@FFroehlich
Copy link
Member

Hmm, but this would be an invalid petab file then, right?

No, I don't mean that the targets were specified as non-estimated in the parameters table, but that during amici import most non-estimated parameters are turned into fixed parameters for performance reasons. And the current logic tries to also do that for rule-targets, which is wrong. (Problem introduced in #1810)

Ah, I see, so the parameter table doesn't need to account for all parameters in a model and the rest are assumed to remain at their default values, right?

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@dweindl
Copy link
Member Author

dweindl commented Dec 22, 2022

Ah, I see, so the parameter table doesn't need to account for all parameters in a model and the rest are assumed to remain at their default values, right?

Correct.

@dweindl dweindl merged commit a4d66b0 into develop Dec 22, 2022
@dweindl dweindl deleted the fix_petab_fixed_pars branch December 22, 2022 10:30
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.

2 participants