This repo contains code for the paper Learning noisy-OR Bayesian Networks with Max-Product Belief Propagation accepted at the International Conference on Machine Learning 2023.
pip install git+https://github.com/deepmind/max_product_noisy_or.git
You need Python 3.10 to get started. While you can install this package in your standard python environment, we recommend using a Python virtual environment to manage your dependencies. This should help to avoid version conflicts and just generally make the installation process easier.
git clone https://github.com/deepmind/max_product_noisy_or.git
cd max_product_noisy_or
python -m venv mp_noisy_or_env
source mp_noisy_or_env/bin/activate
python -m pip install --upgrade pip
python -m pip install -r requirements.txt
python -m pip install -e .
python setup.py install
By default the above commands install JAX for CPU. If you have access to a GPU, follow the official instructions here to install JAX for GPU.
The example script shows a training and testing demonstration and can be run via
python3 examples/example.py
Its notebook version displays some additional figures.
This is not an officially supported Google product.