Adaptive Tuning of Hamiltonian Monte Carlo Within Sequential Monte Carlo

Alexander Buchholz, Nicolás Chopin, Pierre JacobBayesian 2020

Abstract

Sequential Monte Carlo (SMC) samplers are an alternative to MCMC for Bayesian computation. However, their performance depends strongly on the Markov kernels used to rejuvenate particles. We discuss how to calibrate automatically (using the current particles) Hamiltonian Monte Carlo kernels within SMC. To do so, we build upon the adaptive SMC approach of Fearnhead and Taylor (2013), and we also suggest alternative methods. We illustrate the advantages of using HMC kernels within an SMC sampler via an extensive numerical study.

Introduction

Sequential Monte Carlo (SMC) samplers have emerged as a robust alternative to standard Markov Chain Monte Carlo (MCMC) for complex Bayesian inference. These samplers evolve a population of "particles" through a sequence of distributions, typically moving from a simple prior to a complex posterior. A critical challenge in SMC is "weight degeneracy," where a few particles dominate the population. To maintain diversity, particles must be "rejuvenated" using MCMC kernels.

While Hamiltonian Monte Carlo (HMC) is the gold standard for high-dimensional rejuvenation due to its efficient exploration of the state space, it is notoriously sensitive to its hyperparameters: the step size ($\epsilon$) and the number of leapfrog steps ($L$). In an SMC context, the target distribution changes at every step, making manual tuning impossible. This work introduces automated, "plug-and-play" methods to dynamically calibrate HMC kernels within the SMC framework.

Methodology

The core of the proposed approach is to use the existing particle cloud—a unique asset of SMC—to learn optimal HMC parameters on the fly. The standard HMC kernel, which the authors aim to automate, is detailed in Algorithm 1.

Algorithm 1: The Hamiltonian Monte Carlo transition kernel used for particle rejuvenation in SMC.

The authors propose two primary strategies for adaptive tuning:

  1. The FT Approach (Fearnhead and Taylor): An evolutionary strategy where different particles are assigned different HMC parameters. The algorithm tracks the Expected Squared Jumping Distance (ESJD) for each set of parameters. Parameters that yield better mixing "survive" to the next SMC step with minor random perturbations.
  2. The PR Approach (Preliminary Run): A two-stage "look-ahead" strategy. At each step, a quick pilot run is performed with randomized parameters. Quantile regression on energy variations is used to find a stable step size, and the best-performing $(\epsilon, L)$ pairs are selected for the actual production move.

Furthermore, the Mass Matrix ($M$) is calibrated using the diagonal of the empirical covariance of the current particle cloud. This effectively rescales the problem, making the HMC integrator more efficient without the $O(d^3)$ cost of a full covariance matrix.

Experimental Evaluation

The methods were evaluated across several benchmarks, ranging from synthetic toy distributions to high-dimensional spatial models:

  • Toy Distributions: Gaussian and Student-t distributions up to $d=500$ to test scaling and heavy-tail handling.
  • Binary Regression (Sonar & Musk): Standard benchmarks with dimensions $d=61$ and $d=95$.
  • Log Gaussian Cox Process: A spatial statistics model applied to Finnish pine saplings, scaled up to a massive $d=16,384$.

Key Results and Discussion

The results demonstrate that tuned HMC-SMC significantly outperforms traditional rejuvenation kernels like Random Walk Metropolis or MALA. In the "Musk" dataset ($d=95$), while simpler kernels failed to converge after 48 hours, the adaptive HMC-SMC completed the task in under 45 minutes.

Crucially, the HMC kernels achieved significantly higher ESJD per gradient evaluation. The study also highlighted a trade-off: the FT approach is computationally cheaper as it adapts across steps, while the PR approach is more robust to "jerky" changes in the sequence of distributions. Even at $d=16,384$, the HMC-SMC approach provided stable estimates of the normalizing constant, where other methods collapsed.

Limitations

Despite its success, HMC can struggle with distributions that have very heavy tails (non-geometric ergodicity), requiring more conservative tuning. Additionally, the use of a diagonal mass matrix, while efficient at $O(d)$, may not capture complex correlations as well as a full matrix. Finally, the requirement for gradients limits the method to continuously differentiable target densities.

Summary updated

BibTeX
@inproceedings{buchholz2020adaptive,
  author = {Alexander Buchholz and Nicolás Chopin and Pierre Jacob},
  title = {{Adaptive Tuning of Hamiltonian Monte Carlo Within Sequential Monte Carlo}},
  booktitle = {Bayesian},
  year = {2020},
  doi = {10.1214/20-ba1222},
}
Figure