Python Battery Optimisation and Parameterisation
Project description
PyBOP provides a complete set of tools for parameterisation and optimisation of battery models, using both Bayesian and frequentist approaches, with example workflows to assist the user. PyBOP can be used to parameterise various battery models, including electrochemical and equivalent circuit models available in PyBaMM. PyBOP prioritises clear and informative diagnostics for the user, while also allowing for advanced probabilistic methods.
The diagram below shows the conceptual framework of PyBOP. This package is currently under development, so users can expect the API to evolve with future releases.
Installation
Within your virtual environment, install PyBOP:
pip install pybop
To install the most recent state of PyBOP, install from the develop
branch,
pip install git+https://github.com/pybop-team/PyBOP.git@develop
To install a previous version of PyBOP, use the following template and replace the version number:
pip install pybop==v24.3
To check that PyBOP is installed correctly, run one of the examples in the following section. For a development installation, see the Contribution Guide. More installation information is available in our documentation and the extended installation instructions for PyBaMM.
Using PyBOP
PyBOP has two intended uses:
-
Parameter inference from battery test data.
-
Design optimisation under battery manufacturing/use constraints.
These include a wide variety of optimisation problems that require careful consideration due to the choice of battery model, data availability and/or the choice of design parameters.
Jupyter Notebooks
Explore our example notebooks for hands-on demonstrations:
- Gravimetric design optimisation (SPM)
- GITT fitting of an ECM for an LG M50
- Non-linear constrained ECM parameter identification
- Optimiser comparison for parameter identification
- Parameter identification for spatial pouch cell model
Python Scripts
Find additional script-based examples in the examples directory:
- UKF parameter identification (SPM)
- BPX format parameter import/export
- Electrochemical Impendence Spectroscopy (EIS) parameter identification
- Maximum a Posteriori parameter identification (SPM)
- Gradient-based parameter identification (SPM)
Supported Methods
The table below lists the currently supported models, optimisers, and cost functions in PyBOP.
Battery Models | Optimization Algorithms | Cost Functions |
---|---|---|
Single Particle Model (SPM) | Covariance Matrix Adaptation Evolution Strategy (CMA-ES) | Sum of Squared Errors (SSE) |
Single Particle Model with Electrolyte (SPMe) | Particle Swarm Optimization (PSO) | Root Mean Squared Error (RMSE) |
Doyle-Fuller-Newman (DFN) | Exponential Natural Evolution Strategy (xNES) | Minkowski |
Many Particle Model (MPM) | Separable Natural Evolution Strategy (sNES) | Sum of Power |
Multi-Species Multi-Reactants (MSMR) | Adaptive Moment Estimation with Weight Decay (AdamW) | Gaussian Log Likelihood |
Weppner-Huggins | Improved Resilient Backpropagation (iRProp-) | Log Posterior |
Equivalent Circuit Models (ECM) | SciPy Minimize & Differential Evolution | Unscented Kalman Filter (UKF) |
Cuckoo Search | Gravimetric Energy Density | |
Gradient Descent | Volumetric Energy Density | |
Nelder-Mead | ||
Code of Conduct
PyBOP aims to foster a broad consortium of developers and users, building on and learning from the success of the PyBaMM community. Our values are:
-
Inclusivity and fairness (those who wish to contribute may do so, and their input is appropriately recognised)
-
Interoperability (modularity for maximum impact and inclusivity)
-
User-friendliness (putting user requirements first via user-assistance & workflows)
License
PyBOP is released under the BSD 3-Clause License.
Contributors ✨
Thanks goes to these wonderful people (emoji key):
This project follows the all-contributors specifications. Contributions of any kind are welcome! See CONTRIBUTING.md
for ways to get started.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file pybop-24.9.1.tar.gz
.
File metadata
- Download URL: pybop-24.9.1.tar.gz
- Upload date:
- Size: 91.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7e1d6c78f8c4cf51187c67e53f611f47792a6ea431a1a9489b32064172e29e15 |
|
MD5 | 84ed087ec32173daea8f57638586b862 |
|
BLAKE2b-256 | cc628bb8d1aeca6b7865fa3ab8c76dc9f6b99992bb5606d91dd0b15e02e7d7f3 |
File details
Details for the file pybop-24.9.1-py3-none-any.whl
.
File metadata
- Download URL: pybop-24.9.1-py3-none-any.whl
- Upload date:
- Size: 111.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 374170f189d4c1cec2123f0b746eb30282875208ba00857d9b53dbe0e0304dbb |
|
MD5 | 6118946a000c82e8395cf5e4bc8dda65 |
|
BLAKE2b-256 | eedcab6620267718c8ce0fb3c2825610ad50a3b0e833699ab156fcc3638621d9 |