Bean Machine is a probabilistic programming language for inference over statistical models written in the Python language using a declarative syntax. Bean Machine is built on top of PyTorch and Bean Machine Graph, a custom C++ backend. Check out our tutorials and Quick Start to get started!
Bean Machine supports Python 3.7-3.9 and PyTorch 1.10.
python -m pip install beanmachineTo download the latest Bean Machine source code from GitHub:
git clone https://github.com/facebookresearch/beanmachine.git
cd beanmachineThen, you can choose from any of the following installation options.
We recommend using conda to manage the virtual environment and install the necessary build dependencies.
conda create -n {env name} python=3.8; conda activate {env name}
conda install -c conda-forge boost-cpp eigen=3.4.0
python -m pip install .docker build -t beanmachine .
docker run -it beanmachine:latest bashIf you would like to run the builtin unit tests:
python -m pip install "beanmachine[test]"
pytest srcBean Machine is MIT licensed, as found in the LICENSE file.