NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Simulation-Based Inference: A Practical Guide

Michael Deistler, Jan Boelts, Peter Steinbach, Guy Moss, Thomas Moreau, Manuel Glöckler, Pedro L. C. Rodrigues, Julia Linhart, Janne K. Lappalainen, Benjamin Kurt Miller, Pedro J. Gonçalves, Jan-Matthis Lueckmann, Cornelius Schröder, Jakob H. MackearXiv 2025

TL;DR

This paper provides a comprehensive guide to Simulation-Based Inference (SBI), a powerful set of techniques that use neural networks to perform Bayesian inference on complex, stochastic simulators. It offers a practical workflow and diagnostic tools, making SBI accessible for researchers across various scientific disciplines.

What Problem Does This Paper Address?

Many scientific and engineering fields rely on complex computer simulations to understand phenomena. However, inferring the underlying parameters of these simulators from observed data is often a significant challenge. Traditional Bayesian inference methods, like MCMC, struggle with stochastic simulators that lack explicit likelihood functions or are computationally prohibitive to evaluate. This intractability hinders scientific discovery by making it difficult to estimate model parameters, quantify uncertainty, and build accurate predictive models. SBI aims to bridge this gap by enabling Bayesian inference directly from simulator outputs, bypassing the need for explicit likelihood calculations.

Methods

The paper introduces Simulation-Based Inference (SBI) as a suite of methods that leverage neural networks. The core idea is to train an "inference network" on data generated by the simulator. This network learns the relationship between simulator parameters and the resulting data. Once trained, this network can rapidly infer posterior distributions for new observations without further simulations. The paper details a structured SBI workflow, covering:

  • Simulator and Prior Setup: Defining the forward model and incorporating prior knowledge.
  • Component Selection: Choosing data representations (summary statistics, embedding networks), inference algorithms (NPE, NLE, NRE), and inference network architectures (normalizing flows, diffusion models).
  • Execution: Generating simulated data, training the inference network, and performing inference.
  • Validation: Using diagnostic tools like posterior predictive checks and coverage diagnostics to assess the accuracy of the inferred posterior.
  • Analysis: Leveraging the posterior distribution for scientific insight.

Key methods discussed include Neural Posterior Estimation (NPE), Neural Likelihood Estimation (NLE), and Neural Ratio Estimation (NRE), each with different strengths and weaknesses regarding inference speed, data handling, and computational cost.

Datasets

The paper uses simulated data generated from three example simulators:

  • Gravitational Wave Simulator: A simplified model for gravitational wave signals from merging black holes, generating time series data.
  • Drift-Diffusion Model (DDM): A model from psychophysics used to analyze decision tasks, generating mixed discrete-continuous data (choices and reaction times).
  • Pyloric Network Simulator: A biophysics simulator from neuroscience modeling neural activity, generating voltage recordings.

The paper also references a database of published SBI applications for exploring trends in parameter counts versus simulation numbers.

Key Insights and Ideas

  • Amortized Inference is Key: SBI's ability to train a neural network once and then rapidly perform inference on many new observations (amortized inference) is a major advantage, enabling real-time analysis and high-throughput applications.
  • Likelihood-Free Inference: SBI bypasses the need for explicit likelihood functions, making it applicable to a wide range of complex simulators that were previously intractable for Bayesian inference.
  • Neural Networks as Inference Engines: Deep learning models, particularly neural networks, are central to SBI, learning the complex mapping from simulator outputs to parameter posteriors.
  • Diagnostic Tools are Crucial: Robust validation of the inferred posterior is essential. The paper highlights various diagnostic methods to ensure the reliability and accuracy of SBI results.
  • Model Misspecification is a Pitfall: Both simulator and prior misspecification can lead to unreliable inference, emphasizing the importance of careful model checking.
  • Trade-offs in Method Choice: Different SBI methods (NPE, NLE, NRE) offer distinct trade-offs in terms of inference speed, simulation efficiency, and handling of data types, requiring careful consideration for specific problems.

Key Results

The paper demonstrates the application of SBI across three diverse examples:

  • Gravitational Wave Inference: Achieved real-time analysis of high-dimensional time series data using NPE with an embedding network, showing well-calibrated posteriors.
  • Drift-Diffusion Model Inference: Successfully applied NLE to analyze i.i.d. trial data from psychophysics, demonstrating efficient inference for multiple subjects with varying trial numbers.
  • Neuroscience Model Inference: Showcased SBI's scalability to models with dozens of parameters using an ensemble of NPE models, highlighting the importance of ensembles for robust calibration.

The paper also provides practical guidance and recommendations for choosing between different SBI methods based on factors like inference speed, data dimensionality, and computational constraints.

Limitations and Future Work

  • Simulation Requirements: While SBI reduces the need for likelihood evaluations, it can still require a significant number of simulations, especially for complex models or high-dimensional parameter spaces.
  • Model Misspecification Sensitivity: Neural network-based SBI methods can be sensitive to model misspecification, leading to unreliable results. Future work aims to improve robustness in this regard.
  • Hyperparameter Tuning: While tools exist, hyperparameter tuning for both neural networks and inference algorithms (especially for NLE/NRE) can be complex and time-consuming.
  • Emerging Methods: The field is rapidly evolving, with new methods constantly being developed to address limitations in simulation efficiency, sample quality, and robustness. The paper points to ongoing research in improved generative models, robustness to misspecification, and enhanced inference flexibility.

Summary updated

BibTeX
@misc{deistler2025simulation,
  author = {Michael Deistler and Jan Boelts and Peter Steinbach and Guy Moss and Thomas Moreau and Manuel Glöckler and Pedro L. C. Rodrigues and Julia Linhart and Janne K. Lappalainen and Benjamin Kurt Miller and Pedro J. Gonçalves and Jan-Matthis Lueckmann and Cornelius Schröder and Jakob H. Macke},
  title = {{Simulation-Based Inference: A Practical Guide}},
  year = {2025},
  eprint = {2508.12939},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2508.12939},
}
Figure