Source-linked AI summary

Automatic Posterior Transformation for Likelihood-Free Inference

David S. Greenberg, Marcel Nonnenmacher, Jakob H. Macke

arXiv:1905.07488v1cs.LGstat.ML

TL;DR

Likelihood-free inference must estimate posteriors when simulator likelihoods are intractable, while adaptive posterior estimation is constrained by proposal flexibility and importance-weight variance. APT recasts inference as a density-ratio problem to transform posterior estimates under arbitrary dynamic proposals, and it outperforms previous posterior density estimators while scaling to high-dimensional data.

  • Problem

    Simulator likelihoods can be intractable, while existing sequential posterior methods face restricted proposals or importance weights that increase learning variance.

  • Method

    APT recasts posterior inference as density-ratio estimation, transforming posterior estimates for arbitrary dynamically updated proposals without importance weights or post-hoc corrections.

  • Results

    APT outperforms previous posterior density estimation methods and efficiently handles Lokta-Volterra time series and 10k-dimensional image data without summary statistics.

  • Takeaways & Limitations

    APT provides a flexible sequential neural posterior estimator that can use mixture- or flow-based density estimators and operate on high-dimensional observations.

  • Takeaways & Limitations

    With atomic proposals and truncated priors, APT recovers the posterior shape only up to an unknown scale factor and may require rejection sampling.

Abstract

from arXiv · show

How can one perform Bayesian inference on stochastic simulators with intractable likelihoods? A recent approach is to learn the posterior from adaptively proposed simulations using neural network-based conditional density estimators. However, existing methods are limited to a narrow range of proposal distributions or require importance weighting that can limit performance in practice. Here we present automatic posterior transformation (APT), a new sequential neural posterior estimation method for simulation-based inference. APT can modify the posterior estimate using arbitrary, dynamically updated proposals, and is compatible with powerful flow-based density estimators. It is more flexible, scalable and efficient than previous simulation-based inference techniques. APT can operate directly on high-dimensional time series and image data, opening up new applications for likelihood-free inference.

1. Introduction

Likelihood-free inference is needed when simulator likelihoods are intractable, but existing neural posterior methods face proposal and weighting constraints. APT addresses these constraints with flexible posterior transformation and performs efficiently on high-dimensional data.

  • Likelihood-free inference is often necessary because simulator likelihoods involve intractable integrals, unavailable internal states, or real-world experiments.
  • Existing conditional-density approaches estimate either the likelihood or the posterior, with posterior estimation offering direct, amortized inference and learned data features.
  • Adaptive posterior proposals improve simulation relevance, but prior methods require restricted proposals, post-hoc corrections, or importance weights that can increase learning variance.
  • APT combines direct posterior estimation with flexible proposals while avoiding importance weights and post-hoc corrections.
  • APT outperforms previous posterior density estimation methods and performs efficient inference on Lokta-Volterra time series and 10k-dimensional images without summary statistics.

2. Simulation-based inference with conditional density estimators

Likelihood-free inference maps simulator outputs to posterior estimates when the likelihood is unavailable, but adaptive proposals create a correction problem. Sequential methods address this with proposal refinement, while APT targets the posterior under flexible proposals without importance weighting.

  • Likelihood-free inference estimates p(θ|x_o) from limited simulations when p(x|θ) is unknown or intractable.
  • Conditional density estimation learns a neural mapping from simulator output x to parameters of a posterior density q_F(x,φ)(θ).
  • Sequential neural posterior estimation refines posterior estimates and proposals because prior simulations may be uninformative about the observed data.
  • Training on proposal samples yields a proposal posterior rather than the target posterior, creating the central correction problem for sequential methods.
  • SNPE-A restricts proposals and densities for post-hoc correction, whereas SNPE-B removes those restrictions but uses importance weights that can slow or impair inference.
  • SNL supports arbitrary proposals by estimating the likelihood, but requires additional MCMC sampling to obtain the posterior.

3. Automatic Posterior Transformation

APT transforms posterior estimates to accommodate arbitrary proposals while retaining direct posterior learning, amortization, and flow-based density estimation. Its atomic formulation supports flexible proposals and provides posterior-ratio consistency under support-coverage conditions, with a stated limitation for truncated priors.

  • APT transforms between true and proposal posteriors, allowing direct posterior estimation with arbitrary, dynamically updated proposals.The transformation is optimized during learning and avoids the numerical challenges associated with previous SNPE techniques.
  • APT trains a conditional density estimator by minimizing a transformed negative log-probability loss, recovering both true and proposal posteriors under an expressive-model assumption.Consistency is stated as the number of simulations increases when the estimator can represent the true posterior.
  • Mixture-of-Gaussian atomic transformations produce LK-component proposal posteriors, enabling simulation parameters to be proposed from multimodal distributions.The construction combines L proposal components with K posterior-estimator components.
  • Atomic proposals replace intractable integrals with sums over finite parameter sets, enabling flows and other density families when densities are evaluable and differentiable.The proposal can emphasize posterior peaks or tails and support active-learning schemes.
  • For atomic proposals, training recovers posterior density ratios across atoms and the full posterior shape as simulations increase when sampled atoms cover the posterior support.A fixed nonzero fraction of atoms can cover the support while the remainder is assigned for purposes such as active learning.
  • With atomic proposals and limited-support priors, APT recovers posterior shape only up to an unknown scale factor, requiring rejection to obtain posterior samples.The paper describes this as less convenient than direct posterior sampling but simpler and more efficient than full MCMC.

4. Experiments

Across toy, ecological, time-series, image, and benchmark problems, APT outperforms previous posterior-estimation methods and remains effective as data become high-dimensional or uninformative.

  • 4.1. Illustrative toy example with multiple modes: APT identifies multimodal and crescent-shaped posteriors in the two-moons simulator and uses this structure to guide later proposals efficiently.The MDN and masked autoregressive flow implementations both support flexible posterior representations.
  • 4.2. Toy example with simple likelihood but complex posterior: On SLCP, flow-based APT produces posterior estimates similar to SNL and quantitatively outperforms SNPE-A and SNPE-B.The comparison uses maximum mean discrepancy against the ground-truth posterior over repeated initializations.
  • 4.3. Effect of non-informative observations: As uninformative dimensions increase, APT degrades only slightly, whereas SNL’s posterior estimates become no better than the prior at large d.Both methods recover the posterior at moderate data dimensionality.
  • 4.4. Population ecology model: For Lotka-Volterra summary statistics, APT produces tight posteriors around the true parameters with fewer simulations than other methods and approaches SNL for large N.The ground-truth posterior is unavailable, so the comparison is based on posterior behavior and similarity between APT and SNL estimates.
  • 4.5. Inference on raw time-series: APT operates directly on raw Lotka-Volterra time series, and its RNN-based posteriors remain clustered around true parameters under observation noise while outperforming summary-statistic posteriors.The method extracts relevant information end-to-end without bespoke summary statistics.
  • 4.6. Rock-paper-scissors reaction-diffusion model: With a CNN on 10,000-dimensional RPS images, APT posteriors closely encompass the generating parameters, and APT outperforms SNPE-A/B on additional benchmarks.On M/G/1, APT approaches SNL; on GLM, it is slightly more accurate than SNPE-A.

5. Related work

Related likelihood-free inference methods estimate likelihoods or posteriors, but classical ABC requires hand-designed reductions, while adaptive posterior methods face correction or weighting challenges.

  • ABC accepts simulations using summary statistics, distances, and rejection thresholds, remaining exact only in the limit of high rejection rates.
  • Classifier-based approaches include binary discrimination between conditional and marginal distributions, likelihood-ratio approximation, and multiple-choice training.
  • Additional simulator information can improve efficiency, while some implicit-generative-model approaches require differentiability with respect to parameters.

6. Discussion

APT supports arbitrary proposals and diverse conditional density estimators, improving simulation efficiency and scaling to higher-dimensional observations while retaining scope-dependent trade-offs.

  • APT applies to arbitrary proposals and a wide range of conditional density estimators.This flexibility supports extensions combining posterior estimation with active-learning rules or loss-calibrated likelihood-free inference.
  • APT is more simulation-efficient than previous posterior density estimation approaches across varied problems and scales to higher-dimensional observations.
  • Direct posterior targeting yields a mapping from data to posterior without an additional inference step, thereby amortizing inference.
  • Specialized neural architectures can exploit known data structure, as demonstrated with RNNs and CNNs for time series and image data.
  • The likelihood or posterior may be easier to approximate depending on the model and analysis problem, so APT is not claimed to always outperform synthetic likelihood.
  • The paper anticipates that flexible estimators, adaptive simulation schemes, and stable learning frameworks could make inference more efficient, easy, and automated.

A.1. Derivation of MoG proposals for APT with MDNs

The appendix specifies the Gaussian-mixture setting used to derive APT proposal transformations and notes that mixture weights must be normalized.

  • The derivation considers qF(x,φ) as an M-component Gaussian mixture, ˜p(θ) as an L-component Gaussian mixture, and p(θ) as Gaussian.
  • The proportionality symbol indicates that the weights ζik must be normalized so their total satisfies the proposal distribution.

A.2. Algorithm and computational complexity for atomic APT

Atomic APT uses multiple-choice-style minibatch training with dynamically sampled proposals; its quadratic minibatch term can be practical, though very large inputs may benefit from dimensionality reduction.

  • Algorithm: Atomic APT is presented as an algorithm with simulations per round, rounds, and a specified number of atoms M.
  • Algorithm: The procedure initializes the proposal to p(θ), repeatedly samples θc from the current proposal, and simulates xc from p(x|θc).
  • Algorithm: Each minibatch samples M previously simulated indices without replacement and computes the gradient with respect to network parameters φ.
  • Computational complexity: Atomic APT’s computational complexity is quadratic in minibatch size M because qF(x,φ)(θ) is evaluated for every parameter-observation pair.
  • Computational complexity: No wall-clock difference was observed between minibatch sizes M = 10 and M = 100 on an nVidia GeForce RTX 2080.For the Lokta-Volterra and RPS models, simulations took longer than all other calculations for every method.
  • Computational complexity: For MDN estimators, only the final computational term is quadratic in M, while SNPE-A/B and non-atomic MDN-based APT are linear in M.
  • Computational complexity: For conditional MADEs, tasks scaling with input dimension d scale only linearly with M because x can be transformed independently of θ.

A.3. Conditional flow normalization and truncated priors

APT respects prior support through normalization during training and optional post-hoc truncation, but conditional MAFs may accumulate leakage outside the prior.

  • Uniform-prior posteriors should be zero outside prior support, but SNPE-A correction fails for tight priors and SNPE-B leakage complicates interpretation.
  • APT’s normalized probabilities cancel the conditional density model’s normalization, automatically normalizing training with atomic proposals.
  • MDN outputs can be truncated to valid truncated Normal posteriors, while MAF truncation can use rejection sampling and rejection-rate normalization estimates.
  • Conditional MAFs can leak increasingly more mass outside prior support across rounds, although posterior shape quality within that support was unaffected in these observations.
  • Suggested leakage controls include reinitializing flows, training normalized flows, or applying scaled logistic transformations for box-shaped priors.

A.4. Proof of proposition 1

The proposition’s notation defines transformed distributions relative to a specific parameter-support choice Θ.

  • The proof refers to transformed distributions ˜p(θ), ˜p(θ|x), and ˜p(x) defined using a specific choice of Θ.
  • The proposition’s proof begins by clarifying that every transformed distribution is tied to a specified parameter domain Θ.
  • The notation ˜p distinguishes distributions defined under the chosen Θ throughout the proposition’s proof.

Proof of proposition 1

The supplied passages describe posterior-estimation experiments across several simulators, architectures, and evaluation settings, including implementation details and figure-based comparisons.

  • Two moons model: For θ ∈ R2, the two-moons simulator generates x ∈ R2, with a uniform prior over [−1, 1]2 and observed data xo = (0, 0)⊤.
  • Two moons model: Figure 7 compares average maximum mean discrepancies with ground-truth posteriors across algorithms, 10 random initializations, and x = (0, 0).
  • Two moons model: SNL’s MCMC chains failed to sample both posterior modes in most two-moons cases, producing high discrepancies.
  • SLCP model: The SLCP simulator has four posterior modes visible in the pairwise marginal over (θ3, θ4), with MMDs estimated using ground-truth posterior MCMC samples.
  • SLCP model: Added uninformative simulator outputs consisted of mixtures of t-distributions appended to the original eight-dimensional output.
  • SLCP model: MAF dimension ordering used a fixed random permutation to avoid effects from the estimators’ autoregressive nature.
  • SLCP model: The true posterior’s MMD in Figure 3 is nonzero because only a finite number of samples was used.
Loading 1905.07488v1…