https://github.com/alan-turing-institute/autoemulate
Emulate simulations easily
https://github.com/alan-turing-institute/autoemulate
hut23 hut23-1468
Last synced: about 1 month ago
JSON representation
Emulate simulations easily
- Host: GitHub
- URL: https://github.com/alan-turing-institute/autoemulate
- Owner: alan-turing-institute
- License: mit
- Created: 2023-08-01T13:06:39.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-12T09:16:36.000Z (about 2 months ago)
- Last Synced: 2025-03-12T10:26:01.545Z (about 2 months ago)
- Topics: hut23, hut23-1468
- Language: Python
- Homepage: https://alan-turing-institute.github.io/autoemulate/
- Size: 27 MB
- Stars: 28
- Watchers: 7
- Forks: 7
- Open Issues: 64
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README

[](https://codecov.io/gh/alan-turing-institute/autoemulate)
[](https://github.com/psf/black)
[](#contributors)
[](https://alan-turing-institute.github.io/autoemulate/)Simulations of physical systems are often slow and need lots of compute, which makes them unpractical for real-world applications like digital twins, or when they have to run thousands of times for sensitivity analyses. The goal of `AutoEmulate` is to make it easy to replace simulations with fast, accurate emulators. To do this, `AutoEmulate` automatically fits and compares various emulators, ranging from simple models like Radial Basis Functions and Second Order Polynomials to more complex models like Support Vector Machines, Gaussian Processes and Conditional Neural Processes to find the best emulator for a simulation.
The project is in early development.
## Installation
`AutoEmulate` requires Python `>=3.10` and `<3.13`.
There's lots of development at the moment, so we recommend installing the most current version from GitHub:
```bash
pip install git+https://github.com/alan-turing-institute/autoemulate.git
```There's also a release on PyPI:
```bash
pip install autoemulate
```For contributors using [Poetry](https://python-poetry.org/):
```bash
git clone https://github.com/alan-turing-institute/autoemulate.git
cd autoemulate
poetry install
```## Quick start
```python
import numpy as np
from autoemulate.compare import AutoEmulate
from autoemulate.experimental_design import LatinHypercube
from autoemulate.simulations.projectile import simulate_projectile# sample from a simulation
lhd = LatinHypercube([(-5., 1.), (0., 1000.)])
X = lhd.sample(100)
y = np.array([simulate_projectile(x) for x in X])# compare emulators
ae = AutoEmulate()
ae.setup(X, y)
best_emulator = ae.compare()# cross-validation results
ae.summarise_cv()
ae.plot_cv()# test set results for the best emulator
ae.evaluate(best_emulator)
ae.plot_eval(best_emulator)# refit on full data and emulate!
emulator = ae.refit(best_emulator)
emulator.predict(X)# global sensitivity analysis
si = ae.sensitivity_analysis(emulator)
ae.plot_sensitivity_analysis(si)
```## Documentation
You can find tutorials, FAQs and the API reference [here](https://alan-turing-institute.github.io/autoemulate/). The documentation is still work in progress.
## Contributors
Kalle Westerling
📖 💻 🖋
Bryan M. Li
💻
martin
💻 🤔 📖 🚧 🔬 👀
Eric Daub
🤔 📆 👀 💻
steven niederer
🤔 🖋 📆
Maximilian Balmus
💻 🐛
Sophie Arana
🖋 📖 📆
Andrew Duncan
🤔 📆
Marjan Famili
💻 🤔 📖
Radka Jersakova
💻 📆 🚧 🤔
Christopher Iliffe Sprague
💻 🎨 🤔
Will Usher
💻
Sam Greenbury
💻 🤔 👀 📆
Ed Chalstrey
💻 🎨 👀 📖