Parallel Tempering With a Variational Reference

Nikola Surjanovic, Saifuddin Syed, Alexandre Bouchard-Côté, Trevor Campbell

Abstract

Sampling from complex target distributions is a fundamental challenge in Bayesian inference. Parallel tempering (PT) addresses this by interpolating between a target posterior and a reference distribution (typically the prior). However, as data size increases, the prior and posterior often become mutually singular, creating a "Global Communication Barrier" (GCB) that renders PT computationally prohibitive. This paper introduces an adaptive PT method using a variational reference tuned via gradient-free moment-matching. To ensure robustness in multi-modal landscapes, we propose a "stabilized" two-reference path. Our results demonstrate significant empirical gains, including orders-of-magnitude increases in restart rates across diverse Bayesian models.

The Problem: The Broken Bridge of Standard PT

In Bayesian inference, Parallel Tempering (PT) facilitates exploration by swapping states between a sequence of distributions that bridge a simple reference distribution (the prior, $\pi_0$) and the complex target (the posterior, $\pi_1$).

As more data is incorporated, the posterior concentrates, increasing the distance between $\pi_0$ and $\pi_1$. This creates a Global Communication Barrier (GCB) where the "bridge" becomes too steep for effective state swaps. In the large-data limit, the restart rate—a key metric of PT efficiency—drops to zero, causing the algorithm to fail.

Methodology: Variational References and Stabilization

To overcome the GCB, the authors propose replacing the fixed prior with an adaptive variational reference ($q_\phi$).

1. Adaptive Variational Reference

Instead of starting from a distant prior, the sampler begins at a parametric variational distribution $q_\phi$ designed to approximate the target. The reference is tuned using a gradient-free moment-matching procedure. By matching the moments of $q_\phi$ to the samples currently being drawn from the target, the algorithm effectively minimizes the forward (inclusive) KL divergence ($KL(\pi_{target} || q_{ref})$). This ensures the reference is "inclusive," covering all mass of the target to facilitate communication.

2. Stabilized Two-Reference Path

A purely adaptive reference can suffer from a "memory" problem: if it accidentally focuses on a single mode of a multi-modal distribution, it may "forget" others. To prevent this, the authors introduce a split annealing path. This architecture features two "legs": one connecting the target to the fixed prior (acting as a safety net) and another connecting it to the adaptive variational reference (the high-efficiency path).

Conceptual diagrams of Standard PT, Basic Variational PT, and the proposed Stabilized Variational PT with its split annealing path.

Key Results and Empirical Performance

The method was evaluated on 15 inference problems, ranging from synthetic benchmarks to real-world spatial and phylogenetic models.

Robustness to Multi-modality

The stabilized approach proves critical in complex landscapes. While basic variational PT can fail by collapsing onto a single mode, the stabilized version maintains exploration across all modes. As shown in the trace plots and target approximations below, the stabilized method avoids the "catastrophic failure" seen in simpler adaptive schemes.

Comparison of sampling performance. Basic Variational PT fails by "forgetting" modes (red trace), while Stabilized Variational PT (blue trace) captures all modes and maintains high tempered restart rates.

Efficiency Gains

  • Restart Rates: In spatial models like "Lip Cancer," standard PT achieved zero restarts (total failure), whereas the stabilized variational method achieved over 2,300.
  • Plug-and-Play Tuning: The moment-matching approach requires no hyperparameter tuning (unlike SGD), making it highly efficient and easy to implement in probabilistic programming frameworks.
  • Scalability: The authors prove that their stabilized method performs at least half as well as standard PT in the absolute worst case, while typically providing orders-of-magnitude improvements in practice.

Conclusion

By replacing the static prior-to-posterior bridge with an adaptive, stabilized variational path, this work resolves the Global Communication Barrier that has long limited Parallel Tempering. The resulting algorithm is robust, computationally efficient, and scales effectively to the large-data regimes common in modern Bayesian analysis.

Summary updated

BibTeX
@inproceedings{surjanovic2022parallel,
  author = {Nikola Surjanovic and Saifuddin Syed and Alexandre Bouchard-Côté and Trevor Campbell},
  title = {{Parallel Tempering With a Variational Reference}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2022},
}
Figure