Skip to content

Commit 1aafa36

Browse files
authored
Merge pull request #216 from PEtab-dev/release_0.2.3
Release 0.2.3
2 parents 058bf1a + 5c052f1 commit 1aafa36

File tree

4 files changed

+36
-15
lines changed

4 files changed

+36
-15
lines changed

CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,30 @@
22

33
## 0.2 series
44

5+
### 0.2.3
6+
7+
* Fixed validation failures in case of missing optional fields in visualization tables
8+
by @dweindl in https://github.com/PEtab-dev/libpetab-python/pull/214
9+
* Make validate_visualization_df work without matplotlib installation
10+
by @dweindl @dilpath in https://github.com/PEtab-dev/libpetab-python/pull/215
11+
12+
**Full Changelog**: https://github.com/PEtab-dev/libpetab-python/compare/v0.2.2...v0.2.3
13+
514
### 0.2.2
615

716
* Fixed IndexError with numpy 1.25.0 by @dweindl in https://github.com/PEtab-dev/libpetab-python/pull/209
817
* Made `SbmlModel.from_file(..., model_id)` optional by @dilpath in https://github.com/PEtab-dev/libpetab-python/pull/207
918

19+
**Full Changelog**: https://github.com/PEtab-dev/libpetab-python/compare/v0.2.1...v0.2.2
20+
1021
### 0.2.1
1122

1223
Fixes:
1324
* Fixed an issue in `Problem.to_files(model_file=...)` (#204)
1425
* Fixed `PySBModel.get_parameter_value`, which incorrectly returned the parameter name instead of its value (#203)
1526

27+
**Full Changelog**: https://github.com/PEtab-dev/libpetab-python/compare/v0.2.0...v0.2.1
28+
1629
### 0.2.0
1730

1831
Note: petab 0.2.0 requires Python>=3.9

petab/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
"""PEtab library version"""
2-
__version__ = '0.2.2'
2+
__version__ = '0.2.3'

petab/visualize/__init__.py

Lines changed: 21 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,24 +6,32 @@
66
``import petab.visualize``.
77
88
"""
9+
import importlib.util
910

10-
from .plot_data_and_simulation import (
11-
plot_without_vis_spec,
12-
plot_with_vis_spec,
13-
plot_problem,
14-
)
11+
mpl_spec = importlib.util.find_spec("matplotlib")
1512

16-
from .plot_residuals import plot_goodness_of_fit, plot_residuals_vs_simulation
17-
from .plotter import MPLPlotter
1813
from .plotting import DataProvider, Figure
1914

2015
__all__ = [
21-
"plot_without_vis_spec",
22-
"plot_with_vis_spec",
23-
"plot_problem",
24-
"plot_goodness_of_fit",
25-
"plot_residuals_vs_simulation",
26-
"MPLPlotter",
2716
"DataProvider",
2817
"Figure"
2918
]
19+
20+
if mpl_spec is not None:
21+
from .plot_data_and_simulation import (
22+
plot_without_vis_spec,
23+
plot_with_vis_spec,
24+
plot_problem,
25+
)
26+
27+
from .plot_residuals import plot_goodness_of_fit, plot_residuals_vs_simulation
28+
from .plotter import MPLPlotter
29+
30+
__all__.extend([
31+
"plot_without_vis_spec",
32+
"plot_with_vis_spec",
33+
"plot_problem",
34+
"plot_goodness_of_fit",
35+
"plot_residuals_vs_simulation",
36+
"MPLPlotter",
37+
])

petab/visualize/lint.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ def set_default(column: str, value):
124124
if column not in vis_df:
125125
vis_df[column] = value
126126
elif value is not None:
127-
vis_df[column].fillna(value)
127+
vis_df[column].fillna(value, inplace=True)
128128

129129
set_default(C.PLOT_NAME, "")
130130
set_default(C.PLOT_TYPE_SIMULATION, C.LINE_PLOT)

0 commit comments

Comments
 (0)