Parallel Affine Transformation Tuning of Markov Chain Monte Carlo

Philip Schär, Michael Habeck, Daniel Rudolf

Abstract

The performance of Markov chain Monte Carlo samplers strongly depends on the properties of the target distribution such as its covariance structure, the location of its probability mass and its tail behavior. We explore the use of bijective affine transformations of the sample space to improve the properties of the target distribution and thereby the performance of samplers running in the transformed space. In particular, we propose a flexible and user-friendly scheme for adaptively learning the affine transformation during sampling. Moreover, the combination of our scheme with Gibbsian polar slice sampling is shown to produce samples of high quality at comparatively low computational cost in several settings based on real-world data.

Introduction

Markov Chain Monte Carlo (MCMC) methods are indispensable for Bayesian inference, yet their efficiency is often hampered by the geometric properties of the target distribution. Standard samplers, such as Random Walk Metropolis (RWM) or Hamiltonian Monte Carlo (HMC), typically perform optimally when the target distribution is isotropic—meaning it is centered and has a spherical covariance structure. However, real-world posterior distributions frequently exhibit high correlations, varying scales, and complex tail behaviors, leading to poor mixing and slow convergence.

While adaptive MCMC methods attempt to learn these features during sampling, they often face challenges in high-dimensional spaces or incur significant computational overhead. This paper introduces Parallel Affine Transformation Tuning (PATT), a framework designed to adaptively "reshape" difficult distributions into more manageable forms through linear transformations.

The PATT Framework

The core of the proposed approach is Affine Transformation Tuning (ATT). Instead of sampling directly in the original, potentially ill-conditioned space $\mathcal{X}$, the algorithm operates in a "latent space" $\mathcal{Y}$. The two spaces are linked by a bijective affine transformation: $x = Wy + c$, where $c$ represents a centering shift and $W$ is a transformation matrix (e.g., the Cholesky factor of the covariance). By running the sampler in $\mathcal{Y}$, where the distribution is closer to being isotropic, the efficiency of the underlying MCMC kernel is significantly enhanced.

Parallelization (PATT) further improves this process by running multiple chains in parallel. These chains pool their samples to estimate the global mean and covariance of the target distribution more rapidly and accurately. To minimize communication costs, the transformation parameters are updated according to a sparse schedule, ensuring that the tuning process does not become a computational bottleneck.

A key advantage of this framework is its synergy with Gibbsian Polar Slice Sampling (GPSS). Unlike many preconditioning techniques that assume Gaussianity, affine transformations preserve the tail behavior of the distribution. GPSS is naturally robust to diverse tail behaviors, making the PATT-GPSS combination exceptionally effective for heavy-tailed or otherwise non-Gaussian targets.

Experimental Evaluation

The authors evaluated PATT across a range of benchmarks, including synthetic multivariate exponential distributions and Bayesian Logistic Regression (BLR) tasks on real-world datasets such as German Credit, Breast Cancer, Pima Diabetes, and Red Wine Quality.

Bayesian Logistic Regression

In the BLR tasks, PATT-based samplers were compared against established methods like the No-U-Turn Sampler (NUTS), AdaRWM, and GESS. As shown in Table 1, PATT-ESS and PATT-GPSS consistently achieved lower Target Density Evaluations (TDE) per effective sample (ES) compared to their competitors.

Table 1: Efficiency (TDE/ES) across four real-world Bayesian Logistic Regression datasets.

Notably, in the Red Wine Quality task ($d=78$), PATT-ESS required only 12.6 TDE per effective sample, whereas NUTS required 227.5. This efficiency allows PATT-ESS to achieve over 2,000 effective samples per second in this setting.

Synthetic Benchmarks

The efficiency gains were even more pronounced in synthetic experiments. For a 50-dimensional multivariate exponential distribution, PATT-GPSS demonstrated remarkable performance metrics.

Table 2: Performance comparison on the synthetic multivariate exponential distribution ($d=50$).

As detailed in Table 2, PATT-GPSS required only 6.68 TDE/ES, while NUTS required 670.33. Furthermore, PATT-GPSS achieved an effective sampling rate (ES/s) of 5554.64, orders of magnitude higher than NUTS (3.66) or HRUSS (2.65).

Conclusion

Parallel Affine Transformation Tuning provides a robust and flexible framework for improving MCMC performance by addressing the geometric challenges of target distributions. By leveraging parallel chains and sparse update schedules, PATT learns optimal transformations with minimal overhead. While affine transformations are limited to linear reshaping, they offer a computationally efficient alternative to more complex non-linear methods like Normalizing Flows. Future work may explore more frequent update schedules for extremely expensive target densities and further scaling to higher-dimensional problems.

Summary updated

BibTeX
@inproceedings{schar2024parallel,
  author = {Philip Schär and Michael Habeck and Daniel Rudolf},
  title = {{Parallel Affine Transformation Tuning of Markov Chain Monte Carlo}},
  booktitle = {International Conference on Machine Learning},
  year = {2024},
  url = {https://openreview.net/forum?id=SAXp5dMYv7},
}
Figure