This project will initially be a Python port of the R package EBM for maximum likelihood estimation of k-box stochastic energy balance models. In the future, it will serve as a base upon which to add new methodologies and features as and when they are developed.
Cummins, D. P., Stephenson, D. B., & Stott, P. A. (2020). Optimal Estimation of Stochastic Energy Balance Model Parameters, Journal of Climate, 33(18), 7909-7926, https://doi.org/10.1175/JCLI-D-19-0589.1
The easiest way to try out EBM is to clone this repository and build a fresh conda environment from the YAML file.
git clone git@github.com:cemac/EBM.git
cd EBM
conda env create -f EBM.yml
conda activate EBM
You can then import EBM as a Python module from within the interpreter.
import energy_balance_model as ebm
The file demo.py contains a script showing how to generate synthetic data from a three-box stochastic EBM and how to estimate the EBM's parameters via maximum likelihood. Note that to generate the figure at the end of the script you will need to have matplotlib installed.
conda install matplotlib
EBM is licenced under the MIT license - see the LICENSE file for details.
Thanks to Chris Smith for providing an ensemble of calibrated parameter values, which we use here for initialisation and (optionally) regularisation of the maximum likelihood estimation.
Cummins, D. P., Stephenson, D. B., & Stott, P. A. (2020). Optimal Estimation of Stochastic Energy Balance Model Parameters, Journal of Climate, 33(18), 7909-7926, https://doi.org/10.1175/JCLI-D-19-0589.1
Smith, C. (2024). FaIR calibration data (1.4.2) [Data set]. Zenodo. https://doi.org/10.5281/zenodo.13142999