PESTpy
A pure-Python parameter estimation and uncertainty analysis package for
environmental and geophysical models. pestpy bridges the gap between
scipy.optimize.least_squares and PEST++ by providing two core algorithms:
- GLM (Gauss-Levenberg-Marquardt) – A deterministic optimizer with an explicit multi-lambda testing loop and Marquardt scaling. Suitable for non-linear least-squares calibration problems.
- iES (Iterative Ensemble Smoother) – A stochastic ensemble-based smoother based on the mathematics from Fienen et al. (2025). It simultaneously upgrades an ensemble of parameter realizations while adding observation noise to prevent ensemble collapse.
Installation
pip install pestpysuite
Or directly from source:
pip install .
Quick Start
import numpy as np
from pestpy import GLMOptimizer, IESOptimizer
# --- GLM example ---
def model(params):
return params[0] * np.array([1.0, 2.0, 3.0]) + params[1]
obs = np.array([2.1, 4.0, 6.1])
p0 = np.array([1.0, 0.0])
glm = GLMOptimizer(model, obs)
result = glm.fit(p0)
print("GLM solution:", result)
# --- iES example ---
n_params, n_obs, n_real = 2, 3, 50
ensemble = np.random.randn(n_params, n_real)
ies = IESOptimizer(model, obs)
ensemble_updated = ies.fit(ensemble)
print("iES posterior mean:", ensemble_updated.mean(axis=1))
Release files for pestpysuite 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pestpysuite-0.0.1.tar.gz | 7.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pestpysuite-0.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 19.1 kB
Release files / pestpysuite-0.0.1.tar.gz
| Download URL | pestpysuite-0.0.1.tar.gz |
|---|---|
| Size | 7.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
87cd585a34317165b274f525d0e5b981388b34db2fea61da5645e96bab2cb5a3
|
|
BLAKE2b-256 checksum How to use checksums |
a2aaeaaf7cd7d45abe1ef1d64737bf555b08fe67f4aac6fed2bd397556e871b4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.14
|
Release files / pestpysuite-0.0.1-py3-none-any.whl
| Download URL | pestpysuite-0.0.1-py3-none-any.whl |
|---|---|
| Size | 11.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e358d3ce2ac68b6062ce9b7689e09a27b6b24ea021e7a971aa57335c935ac79a
|
|
BLAKE2b-256 checksum How to use checksums |
4afde313d9b554634e6dcd385a4eae3f6e8d52c08034f0d8c9af4556a04e99e7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.14
|