Releases: pybamm-team/PyBaMM
Releases · pybamm-team/PyBaMM
v25.10.2
v25.10.1
What's Changed
- Sync develop with main by @BradyPlanden in #5252
- fix wsl links by @valentinsulzer in #5251
- chore: modernise uv usage in CI + fix cache by @Saransh-cpp in #5249
- Add docstrings to FuzzyDict methods by @swastim01 in #5242
- fix: Fixing non-deterministic CI issues by @Rishab87 in #5255
- Build(deps): bump the actions group with 2 updates by @dependabot[bot] in #5259
- Fix bug with initial conditions that violate events by @MarcBerliner in #5260
- Fix/discussion autoresponder 5186 by @swastim01 in #5261
- update to pytest 9.0, remove pytest-subtests by @valentinsulzer in #5271
- Set initial conditions from y slice by @rtimms in #5257
- Plot voltage components bugfix by @Daniel-Nicolae23 in #5270
- Composite electrode bug-fix for swelling submodel by @BradyPlanden in #5272
Full Changelog: https://github.com/pybamm-team/PyBaMM/blob/develop/CHANGELOG.md#v25100---2025-10-29
v25.10.0
What's Changed
- Build(deps): bump the actions group with 2 updates by @dependabot[bot] in #5148
- Sync v25.8.0 with develop by @brosaplanella in #5149
- Fixed non-deterministic plotting CI issues by @Rishab87 in #5150
- 2D by @aabills in #5106
- Generalise initial state setting by @NicolaCourtier in #5129
- Attempt to Patch few non-deterministic CI issues. by @Rishab87 in #5156
- chore: update pre-commit hooks by @pre-commit-ci[bot] in #5147
- Build(deps): bump the actions group with 6 updates by @dependabot[bot] in #5157
- composite esoh by @aabills in #5160
- Total surface area to volume by @rtimms in #5165
- chore: update pre-commit hooks by @pre-commit-ci[bot] in #5166
- Build(deps): bump github/codeql-action from 3.29.8 to 3.29.10 in the actions group by @dependabot[bot] in #5167
- Added
load_mesh_from_filefunction to support external 3D meshes. by @Rishab87 in #5162 - [GSoC 2025] Saving and Loading Custom Models by @medha-14 in #5056
- Fix drive cycle duration bug by @MarcBerliner in #5153
- chore: update pre-commit hooks by @pre-commit-ci[bot] in #5172
- Build(deps): bump the actions group with 3 updates by @dependabot[bot] in #5173
- fix 2d inner product by @aabills in #5175
- constant extrapolation in 2d by @aabills in #5178
- fix calculation of bulk ocp in hysteresis models by @rtimms in #5169
- Composite esoh half cell by @aabills in #5179
- chore: update pre-commit hooks by @pre-commit-ci[bot] in #5182
- Added an option for multiple initial conditions in IDAKLU solver by @Rishab87 in #4981
- chore: update pre-commit hooks by @pre-commit-ci[bot] in #5187
- Use T_init in initial_state by @rtimms in #5189
- Hysteresis ESOH by @aabills in #5163
- Build(deps): bump the actions group across 1 directory with 5 updates by @dependabot[bot] in #5188
- Update
pybammsolverstov0.2.0by @MarcBerliner in #5199 - 1D+ sensitivities error with IDAKLU output_variables by @pipliggins in #5118
- Make time-based heaviside and modulo inputs explicit
t_evalpoints withIDAKLUSolverby @MarcBerliner in #4994 - Add options to terminate
IDAKLUSolverearly when there's little progress by @MarcBerliner in #5201 - Computing Bruggeman coefficient from BPX porosity instead of hardcoding by @r0hansaxena in #5196
- Unpin
numpy, bumppybammsolversby @MarcBerliner in #5204 - Fix bug with out-of-bounds discontinuities in time by @MarcBerliner in #5205
- Fix doc links (make lychee happy) by @DavidMStraub in #5208
- Removes the default solver change warning by @BradyPlanden in #5209
- Added warning about installation through conda to docs and suggested installation via pip by @r0hansaxena in #5206
- [CI] Change MacOS runner from macos-13 to macos-15-intel by @DavidMStraub in #5213
- Remove deprecated JAX funtions by @DavidMStraub in #5203
- Build(deps): bump the actions group across 1 directory with 3 updates by @dependabot[bot] in #5216
- feat(EvaluateAt): add support for children evaluated at edges by @martinjrobins in #5190
- Build(deps): bump the actions group with 3 updates by @dependabot[bot] in #5220
- Allow sim to be pickled with output variables by @pipliggins in #5225
- Plot voltage components for composite electrodes by @Daniel-Nicolae23 in #5229
- Change fundamental SEI variable from thickness to concentration: attempt 2 by @DrSOKane in #4869
- #5198 update definition of hysteresis decay rate by @rtimms in #5217
- Serialise refactor by @aabills in #5235
- IDAKLU options property, fixes pickling issue with getstate by @BradyPlanden in #5234
- Serialise geometry varpts etc by @aabills in #5236
- [GSoC 2025] Serialising Parameter Sets by @medha-14 in #5177
- Update broken link by @valentinsulzer in #5246
- Build(deps): bump the actions group across 1 directory with 4 updates by @dependabot[bot] in #5243
- Set zip(..., strict=True) in key solver/expression tree files for len… by @swastim01 in #5241
- Fix: correct temperature initialisation in lumped and x_full thermal … by @swastim01 in #5248
- Enable contact overpotential display by @Jhah2025 in #5247
- Serialization refactor by @aabills in #5244
- Release v25.10.0 by @BradyPlanden in #5250
New Contributors
- @r0hansaxena made their first contribution in #5196
- @Daniel-Nicolae23 made their first contribution in #5229
- @swastim01 made their first contribution in #5241
- @Jhah2025 made their first contribution in #5247
Full Changelog: v25.8.0...v25.10.0
v25.8.0
Features
- Added
plot_3d_cross_section&plot_3d_heatmapfunctions to support plotting for 3D thermal simulations. (#5130) - Added a
Basic3DThermalSPMwith two way coupling. (#5112) - Enables the passing of
inputsthroughoutset_initial_soc. (#5122) - Adds
on_failureoption toBaseSolverwith options for"warn","ignore", and"raise"to change behaviour on solver failure. Defaults to "raise" to retain historic functionality. (#5105) - Creates a boundary mesh size object that returns the distance from the center of the leftmost/rightmost control volume to the boundary of the domain (#5108)
- Introduced entry points for models, similar to parameter sets, and moved entry point handling to
pybamm.dispatch.entry_points. There is now experimental support for loading third-party models outside of the PyBaMM framework viapybamm.Model("model_name"). This API is currently unstable until further notice and may be subject to change without warning. (#4490) - Allow for overriding the spatial method's extrapolation and for using constant extrapolation of boundary values (#5107)
- Creates
BaseProcessedVariableto enable object combination when adding solutions together (#5076) - Added a
Constantsymbol for named constants. This is a subclass ofScalarand is used to represent named constants such as the gas constant. This avoids constants being simplified out when constructing expressions. (#5070) - Generalise
pybamm.DiscreteTimeSumto allow it to be embedded in other expressions (#5044) - Adds
allkey-value pair tooutput_variablessensitivity dictionaries, accessible throughsolution[var].sensitivities['all']. Aligns shape with conventional solution sensitivities object. (#5067) - Added a new
BaseHysteresisOpenCircuitPotentialclass that sets variables for the lithiation and delithiation OCP and the hysteresis voltage (H = U_lith - U_delith). Allow the initial hysteresis state to be a function of position through the electrode. Allow the hysteresis decay rates of the Axen and Wycisk models to be a function of stoichiometry and temperature. Added a heat source term in each active material phaseQ_hys = i_vol * (U - U_eq)wherei_volis the volumetric interfacial current density,Uis the OCP (i.e. includes hysteresis), andU_eqis the "equilibrium OCP". Renamed the open-circuit potential models to be more descriptive. The options "Axen" and "Wycisk" are now "one-state hysteresis" and "one-state differential capacity hysteresis". The old option names still work but will raise a warning. (#4893) - Add support for
output_variablestopybamm.DiscreteTimeSumandpybamm.ExplicitTimeIntegralexpressions. (#5071) - Added 3D FEM and meshes supporting rectangular and cylindrical geometries (#5009)
Bug fixes
- Fix non-deterministic ShapeError in 3D FEM gradient method (#5143)
- Fixes negative electrode boundary values for half-cell voltage contributions. (#5139)
- Makes
A_ccL_z * L_y * number of layers (#5138) - Fixes
TimeIntegralexpression node summation when dependent on an input parameter. (#5119) - Fixed a bug that ignored the default duration of drive cycles for
CRatesteps and a bug that overwrote customperiodarguments for drive cycles. (#5090) - Converts sensitivities to numpy objects, fixing bug in
DiscreteTimeSumsensitivity calculation (#5037) - Raises error if
pybamm.Interpolantgiven 1D x values that are not strictly increasing (#5061) - Fixes inconsistency of the returned shape of a
pybamm.DiscreteTimeSumvariable depending onoutput_variablesbeing set or not. (#5098) - Fixed a bug where simplifications cause heavisides to evaluate as booleans (#4893)
- Fixed a bug in the
WyciskOpenCircuitPotentialmodel where the differential capacity was not being evaluated correctly. (#4893)
Breaking changes
- Changed behavior of drive cycle steps in
pybamm.Experiments to treat each time point as a discontinuity, consistent with how input interpolants work. This ensures more accurate simulation of drive cycles with rapid changes. (#5141) - Removed the IREE code from the IDAKLU solver (#5080)
- Removed support for Python 3.9 (#5052)
- In OCP hysteresis models, users need to explicitly give the equilibrium, delithiation, and lithiation OCPs when using a hysteresis model. E.g., you must provide all three of "Negative electrode OCP [V]", "Negative electrode delithiation OCP [V]", and "Negative electrode lithiation OCP [V]". (#4893)
v25.6.0
Features
- Renamed MSMR parameters from symbols to written out names with units as a non-breaking change with a deprecation warning. (#5027)
Optimizations
- Update docs, examples and tests to use
IDAKLUSolver. (#4996) - Add a solver option to change
on_extrapolationbehavior to"error","warn", or"ignore"on extrapolation events. (#4993) - Improve reliability of
CasadiAlgebraicSolverand added an option for thestep_tolof the Newton iteration. (#4985) - Speed up calculation of variable sensitivities in
ProcessedVariable(#5000)
Bug fixes
- Fixed a bug in the
QuickPlotwhich would return empty values for 1D variables at the beginning and end of a timespan. (#4991) - Fixed a bug in the
Exponential1DSubMeshwhere the mesh was not being created correctly for non-zero minimum values. (#4989) - Fixed sensitivity calculation for
pybamm.DiscreteTimeSum. (#5007)
Breaking changes
- Remove sensitivity functionality for Casadi and Scipy solvers, only
pybamm.IDAKLUsolver can calculate sensitivities. (#4975)
v25.4.2
v25.4.1
v25.4.0
Features
- Revision of the hysteresis notebook to include the method implemented in the module
axen_ocp. (#4880) - Added
axen_ocpmodule within submodelinterface.open_circuit_potentialto handle an OCP with hysteresis. (#4816) - Creates a 'calc_esoh' property in battery models (#4825)
- Added 'get_summary_variables' to return dictionary of computed summary variables (#4824)
- Added support for particle size distributions combined with particle mechanics. (#4807)
- Added InputParameter support in PyBamm experiments (#4826)
- Added support for the
"pchip"interpolator using the CasADI backend. (#4871)
Breaking changes
- Added
skip_okoption tostepto allow for steps to be skipped if they are infeasible at initial conditions. (#4839) - Deprecated
CrateTerminationand renamed it toCRateTermination. (#4834)
Bug fixes
- Fixed a bug with observing the outputs of 2D FEM simulations. (#4912)
- Fixed a bug in simulating FEM models with the
IDAKLUSolver. (#4879) - Moved concentration inside x-averaged when calculating LLI due to LAM variables (#4858)
- Fixed a bug that caused the variable
"Loss of lithium due to {domain} lithium plating"to have the domain"current collector"(should not have any domain at all) if the"x-average side reactions"option was set to"true". (#4844) - Fixed interpolation bug in
pybamm.QuickPlotwith spatial variables. (#4841)
Optimizations
v25.1.1
v25.1.0
Features
- Added a
dt_minoption to the (IDAKLUSolver). (#4736) - Automatically add state variables of the model to the output variables if they are not already present (#4700)
- Enabled using SEI models with particle size distributions. (#4693)
- Added symbolic mesh which allows for using InputParameters for geometric parameters (#4665)
- Enhanced the
searchmethod to accept multiple search terms in the form of a string or a list. (#4650) - Made composite electrode model compatible with particle size distribution (#4687)
- Added
Symbol.post_order()method to return an iterable that steps through the tree in post-order fashion. (#4684) - Porosity change now works for composite electrode (#4417)
- Added two more submodels (options) for the SEI: Lars von Kolzenberg (2020) model and Tunneling Limit model (#4394)
Breaking changes
- Updated BPX to v0.5.0 and made changes for the switch to Pydantic V2 (#4701)
- Summary variables now calculated only when called, accessed via a class in the same manner as other variables rather than a dictionary. (#4621)
- The conda distribution (
pybamm) now installs all optional dependencies available on conda-forge. Use the newpybamm-baseconda
package to install PyBaMM with only the required dependencies. (conda-forge/pybamm-feedstock#70) - Separated extrapolation options for
pybamm.BoundaryValueandpybamm.BoundaryGradient, and updated the default to be "linear" for the value and "quadratic" for the gradient. (#4614) - Double-layer SEI models have been removed (with the corresponding parameters). All models assume now a single SEI layer. (#4470)
- Moved the IDAKLU solver to a standalone
pybammsolverspackage. This will
make PyBaMM a pure Python package and make installing and using the solver
easier. (#4487) - Wycisk OCP model now requires an parameter to set the initial condition. (#4374)
Bug fixes
- Fixed bug when using stoichiometry-dependent diffusivity with the DFN model with a particle size distribution. (#4726)
- Remove internal use of deprecated
set_parametersfunction in theSimulationclass which caused warnings. (#4638) - Provide default value for
Symbol.meshattribute to avoid errors when adding variables after discretisation. (#4644)