Hi All,
I am one of the developers of BayesFlow, which is a multi-backend library for amortized Bayesian inference. In the latest release, we have included an alpha-version of a PyMC wrapper which lets us plug a trained continuous density estimator or a neural ratio estimator into a PyMC sampling routine:
- Example 1: Likelihood Estimation with BayesFlow and PyMC
- Example 2: Neural Ratio Estimation with BayesFlow and PyMC
As I am fairly new to the PyMC internals, I would like to extend an invitation for contributions and will greatly appreciate any feedback you may have in improving this / making it more general. For now, only JAX backend is supported, but I’ve coded it in anticipation for extending it with Torch/TF as well. The wrapper source code is here.
Many thanks,
Stefan