sbiax
Fast, lightweight and parallel simulation-based inference.
sbiax is a lightweight library for simulation-based inference (SBI) with a fixed grid of simulations.
Design
In a typical inference problem the data likelihood is unknown. Using density-estimation SBI, we can proceed by
- simulating a set of data and model parameters ${(\boldsymbol{\xi}, \boldsymbol{\pi})_0, ..., (\boldsymbol{\xi}, \boldsymbol{\pi})_N}$,
- obtaining a measurement $\hat{\boldsymbol{\xi}}$,
- compressing the simulations and the measurements - usually with a neural network or linear compression - to a set of summaries ${(\boldsymbol{x}, \boldsymbol{\pi})_0, ..., (\boldsymbol{x}, \boldsymbol{\pi})_N}$ and $\hat{\boldsymbol{x}}$,
- fitting an ensemble of normalising flow or similar density estimation algorithms (e.g. a Gaussian mixture model),
- the optional optimisation of the parameters for the architecture and fitting hyperparameters of the algorithms,
- sampling the ensemble posterior (using an MCMC sampler if the likelihood is fit directly) conditioned on the datavector to obtain parameter constraints on the parameters of a physical model, $\boldsymbol{\pi}$.
sbiax is a code for implementing each of these steps.
Usage
Install via
pip install sbiax
and have a look at examples.
Contributing
Want to add something? See CONTRIBUTING.md.
Citation
If you found this library to be useful in academic work, please cite:
@misc{homer2024simulationbasedinferencedodelsonschneidereffect,
title={Simulation-based inference has its own Dodelson-Schneider effect (but it knows that it does)},
author={Jed Homer and Oliver Friedrich and Daniel Gruen},
year={2024},
eprint={2412.02311},
archivePrefix={arXiv},
primaryClass={astro-ph.CO},
url={https://arxiv.org/abs/2412.02311},
}
@article{
Homer2025,
doi = {10.21105/joss.07606},
url = {https://doi.org/10.21105/joss.07606},
year = {2025},
publisher = {The Open Journal},
volume = {10},
number = {105},
pages = {7606},
author = {Jed Homer and Oliver Friedrich},
title = {SBIAX: Density-estimation simulation-based inference in JAX},
journal = {Journal of Open Source Software}
}
Metadata
Release files for sbiax 0.0.57
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| sbiax-0.0.57.tar.gz | 4.4 MB | With provenance | Details for sbiax-0.0.57.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| sbiax-0.0.57-py3-none-any.whl | Python 3 | none | any | Details for sbiax-0.0.57-py3-none-any.whl |
Total release size: 8.7 MB
Release files / sbiax-0.0.57.tar.gz
| Download URL | sbiax-0.0.57.tar.gz |
|---|---|
| Size | 4.4 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
11c69219557da7b6e4bec839e953803595f72d086f6fd25be5322c7c414b3e45
|
|
BLAKE2b-256 checksum How to use checksums |
dc1308e2c3ee2667666a11bf7890b08d9491f62904f0ae8c59e51b45a977a83d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 3, 2025.
Transparency logRelease files / sbiax-0.0.57-py3-none-any.whl
| Download URL | sbiax-0.0.57-py3-none-any.whl |
|---|---|
| Size | 4.4 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
aeec46134be4cef7e38db6ef32e88667cf6e812568cb15d5f65877a8a038262d
|
|
BLAKE2b-256 checksum How to use checksums |
36a030e05e9fbb17dc7b997cfda28ddd357664dabe6b707806e185305fca485c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 3, 2025.
Transparency logSecurity for sbiax 0.0.57
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for sbiax-0.0.57.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 3, 2025.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.