Table of Contents
Fetching ...

PolyChord: next-generation nested sampling

W. J. Handley, M. P. Hobson, A. N. Lasenby

TL;DR

PolyChord introduces a high-dimensional nested sampling algorithm that combines multi-dimensional slice sampling, contour whitening, and clustering to efficiently explore multimodal posteriors and estimate evidences. It leverages a fast-slow parameter hierarchy (CosmoChord) and OpenMPI parallelization to achieve superior scaling over MultiNest, with accurate local evidences for individual modes. The approach is demonstrated on Gaussian, Rosenbrock, and Rastrigin tests, as well as Gaussian shells and Planck-era cosmological likelihoods, showing robust performance in challenging, high-dimensional spaces. This work enables practical Bayesian model comparison and parameter estimation in complex cosmological analyses, making PolyChord a valuable tool for large-scale inference.

Abstract

PolyChord is a novel nested sampling algorithm tailored for high-dimensional parameter spaces. This paper coincides with the release of PolyChord v1.3, and provides an extensive account of the algorithm. PolyChord utilises slice sampling at each iteration to sample within the hard likelihood constraint of nested sampling. It can identify and evolve separate modes of a posterior semi-independently, and is parallelised using openMPI. It is capable of exploiting a hierarchy of parameter speeds such as those present in CosmoMC and CAMB, and is now in use in the CosmoChord and ModeChord codes. PolyChord is available for download at: http://ccpforge.cse.rl.ac.uk/gf/project/polychord/

PolyChord: next-generation nested sampling

TL;DR

PolyChord introduces a high-dimensional nested sampling algorithm that combines multi-dimensional slice sampling, contour whitening, and clustering to efficiently explore multimodal posteriors and estimate evidences. It leverages a fast-slow parameter hierarchy (CosmoChord) and OpenMPI parallelization to achieve superior scaling over MultiNest, with accurate local evidences for individual modes. The approach is demonstrated on Gaussian, Rosenbrock, and Rastrigin tests, as well as Gaussian shells and Planck-era cosmological likelihoods, showing robust performance in challenging, high-dimensional spaces. This work enables practical Bayesian model comparison and parameter estimation in complex cosmological analyses, making PolyChord a valuable tool for large-scale inference.

Abstract

PolyChord is a novel nested sampling algorithm tailored for high-dimensional parameter spaces. This paper coincides with the release of PolyChord v1.3, and provides an extensive account of the algorithm. PolyChord utilises slice sampling at each iteration to sample within the hard likelihood constraint of nested sampling. It can identify and evolve separate modes of a posterior semi-independently, and is parallelised using openMPI. It is capable of exploiting a hierarchy of parameter speeds such as those present in CosmoMC and CAMB, and is now in use in the CosmoChord and ModeChord codes. PolyChord is available for download at: http://ccpforge.cse.rl.ac.uk/gf/project/polychord/

Paper Structure

This paper contains 48 sections, 54 equations, 14 figures.

Figures (14)

  • Figure 1: The nested sampling volume transformation. Left: five iso-likelihood contours of a two-dimensional multi-modal likelihood function $\mathcal{L}(\theta)$. Each contour encloses some fraction of the prior $X$, indicated by colour. Right: Likelihood $\mathcal{L}$ as a function of the volume $X$ enclosed by the contour. The evidence is the area under this curve.
  • Figure 2: Plot of a generic likelihood as a function of the prior volume $\mathcal{L}(X)$. In high dimensions, the likelihood is only visible if plotted against $\log X$ (dashed curve). However, the evidence is better visualised by plotting $X\log(X)$ (solid curve). The area under the solid curve corresponds to the evidence. The magnitude of the solid curve is proportional to the importance weighting. Nested sampling proceeds from high to low volumes. After some time, the live points no longer contribute significantly to the evidence, and the algorithm terminates at this point.
  • Figure 3: Slice sampling in one dimension. Given a probability level (or slice) $\mathcal{P}_0$, slice sampling samples within the horizontal region defined by $\mathcal{P}>\mathcal{P}_0$. From an initial point $x_0$ within the slice ($\mathcal{P}(x_0)>\mathcal{P}_0$), a new point $x_1$ is generated within the slice with a distribution $P(x_1|x_0)$. External bounds are first set on the slice $\hat{L}<x_0<\hat{R}$ by uniformly expanding a random initial bound of width $w$ until they lie outside the slice (Neal terms this the stepping out procedure). $x_1$ is then sampled uniformly within these bounds. If $x_1$ is not in the slice, then $\hat{L}$ or $\hat{R}$ is replaced with $x_1$, ensuring that $x_0$ is still within the slice. This procedure is guaranteed to generate a new point $x_1$, and satisfies detailed balance $P(x_0|x_1) = P(x_1|x_0)$. Thus, if $x_0$ is drawn from a uniform distribution within the slice, so is $x_1$.
  • Figure 4: Slice sampling in $D$ dimensions. We begin by "whitening" the unit hypercube by making a linear transformation which turns a degenerate contour into one with dimensions ${\sim\mathcal{O}{\left(1\right)}}$ in all directions. This is a linear skew transformation defined by the inverse of the Cholesky decomposition of the live points' covariance matrix. We term this whitened space the sampling space. Starting from a randomly chosen live point ${\bf x}_{0}$, we pick a random direction and perform one-dimensional slice sampling in that direction (Figure \ref{['fig:1d_slice']}), using $w=1$ in the sampling space. This generates a new point ${\bf x}_{1}$ in ${\sim\mathcal{O}{\left(\text{a few}\right)}}$ likelihood evaluations. This process is repeated ${\sim\mathcal{O}{\left(n_\mathrm{dims}\right)}}$ times to generate a new uniformly sampled point ${\bf x}_{N}$ which is decorrelated from ${\bf x}_{0}$.
  • Figure 5: Parallelisation of PolyChord. The algorithm parallelises nearly linearly, providing that $n_\mathrm{procs}<n_\mathrm{live}$. For most astronomical applications this is more than sufficient.
  • ...and 9 more figures