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

Fix / refactor parameter mapping (breaking change) #344

Merged
merged 7 commits into from
Feb 28, 2020
Merged

Conversation

dweindl
Copy link
Member

@dweindl dweindl commented Feb 26, 2020

Fixes #342

Parameter value and parameter scale mapping now always done together.
Fixed handling of parameter scale for non-estimated scaled parameters.

Fixes #342

Parameter value and parameter scale mapping now always done together.
Fixed handling of parameter scale for non-estimated scaled parameters.
@codecov
Copy link

codecov bot commented Feb 26, 2020

Codecov Report

Merging #344 into develop will increase coverage by 0.62%.
The diff coverage is 89.47%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #344      +/-   ##
===========================================
+ Coverage    76.31%   76.93%   +0.62%     
===========================================
  Files           23       23              
  Lines         1925     2012      +87     
  Branches       424      446      +22     
===========================================
+ Hits          1469     1548      +79     
- Misses         348      349       +1     
- Partials       108      115       +7
Impacted Files Coverage Δ
petab/C.py 100% <100%> (ø) ⬆️
petab/calculate.py 89.14% <89.36%> (+3.1%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f1e369a...20191ab. Read the comment docs.

Copy link
Member

@yannikschaelte yannikschaelte left a comment

Choose a reason for hiding this comment

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

looks great, seems reasonable.

second for simulation. ``NaN`` is used where no mapping exists.
Parameter value and parameter scale mapping for all conditions.

The length of the returned array is the number of unique combinations
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
The length of the returned array is the number of unique combinations
The lengths of the returned array are respectively the numbers of unique combinations

Copy link
Member Author

Choose a reason for hiding this comment

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

I'd say it was correct before. It's an array of tuples, not a tuple of arrays.

Copy link
Member

Choose a reason for hiding this comment

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

of course, you are right!

Parameter value and parameter scale mapping for all conditions.

The length of the returned array is the number of unique combinations
of simulationConditionId and preequilibrationConditionId from the
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
of simulationConditionId and preequilibrationConditionId from the
of simulationConditionIds and preequilibrationConditionIds from the


# Replace any leftover mapped parameter coming from condition table
for key, value in mapping.items():
for key, value in par_mapping.items():
Copy link
Member

Choose a reason for hiding this comment

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

use more descriptive than key and value?

condition_df=condition_df,
parameter_df=parameter_df,
sbml_model=model,
scaled_parameters=True
Copy link
Member

Choose a reason for hiding this comment

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

good

@dweindl dweindl merged commit 77fd607 into develop Feb 28, 2020
@dweindl dweindl deleted the fix_342 branch February 28, 2020 10:08
@dweindl dweindl mentioned this pull request Feb 28, 2020
dweindl added a commit that referenced this pull request Feb 28, 2020
Release 0.1.3

File format:

* Updated documentation
* Observables table in YAML file now mandatory in schema (was implicitly 
  mandatory before, as observable table was required already)

Library:
* petablint:
  * Fix: allow specifying observables file via CLI (Closes #302)
  * Fix: nominalValue is optional unless estimated!=1 anywhere (Fixes #303)
  * Fix: handle undefined observables more gracefully (Closes #300) (#351)
* Parameter mapping: 
  * Fix / refactor parameter mapping (breaking change) (#344)
    (now performing parameter value and scale mapping together)
  * check optional measurement cols in mapping (#350)
* allow calculating llhs (#349), chi2 values (#348) and residuals (#345)
* Visualization
  * Basic Scatterplots & lot of bar plot fixes (#270)
  * Fix incorrect length of bool `bool_preequ` when subsetting with ind_meas 
    (Closes #322)
* make libcombine optional (#338)
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