Amortized Simulation-Based Inference in Generalized Bayes via Neural Posterior Estimation
Abstract
Lay Summary
Many scientific fields use computer simulators to understand complex systems, such as physical processes, biological dynamics, or neural activity. These simulators can generate realistic synthetic data, but they often make it difficult to compute uncertainty about the unknown parameters of the system. Standard Bayesian methods can provide such uncertainty estimates, but they may be computationally expensive because they often require a new sampling procedure for each new dataset and for each choice of robustness setting. In this work, we develop a faster approach for this problem. Instead of rerunning an expensive inference algorithm every time, we train a single neural network to approximate a whole family of Bayesian answers. The network takes both the observed data and a tuning parameter as inputs, and then quickly produces samples from the corresponding uncertainty distribution. This tuning parameter controls how strongly the data are trusted relative to the prior information, which can be useful when the simulator is imperfect or misspecified. We propose two ways to train this neural network and test them on several standard simulation-based inference examples, including a chaotic dynamical system and a neuron model. Our results show that the trained model can often match the quality of more expensive sampling-based methods, while allowing much faster inference after training. The method is therefore useful when many datasets or many robustness settings need to be explored, although it still requires a substantial upfront simulation and training cost.