Betancourt 2015 - Riemannian HMC and the SoftAbs Metric
Summary
Riemannian HMC lets the momentum covariance depend on position, π(p∣q)=N(0,Σ(q)), adding a 21log∣Σ(q)∣ term that acts as an energy reservoir, so potential-energy variation is no longer capped at d/2. A good metric resembles the Hessian; the SoftAbs transformation makes the Hessian positive definite. With it, trajectories span the entire funnel and give nearly independent transitions.
Allow position-dependent covariance: π(p∣q)=N(p∣0,Σ(q)) with kinetic energy
T(p,q)=21p⊤Σ−1(q)p+21log∣Σ(q)∣.
The Hamiltonian now generates dynamics on a Riemannian manifold with metric Σ. The dynamic metric acts as a local correction to the target; if well chosen it compensates position-dependent correlations, reducing computational burden and sensitivity to step size.
The log-determinant energy reservoir
The term 21log∣Σ(q)∣ is nominally the normalisation of the momentum density, but it functions as a reservoir that absorbs and releases energy along the trajectory, allowing much larger variations in potential energy (Fig. 10: V is essentially unconstrained in practice even though V variation is still bounded by T variation, because T now varies greatly).
Choosing the metric. To correct position-dependent geometry, the metric should leave the target locally isotropic, which suggests the Hessian of the target. The Hessian itself is not guaranteed positive definite.
)
Apply the SoftAbs transformation to the eigenvalues of the Hessian to obtain a smooth, positive-definite metric; it yields a generic and efficient RHMC implementation. (Footnote 4: the Fisher-Rao metric from information geometry is an alternative regulariser, but it regularises by integrating out exactly the correlations needed for effective corrections in hierarchical models.) The paper does not restate the formula; the standard SoftAbs map (Betancourt 2013, arXiv:1212.4693) replaces each Hessian eigenvalue λ by λcoth(αλ) with a regularisation constant α.
Figure 11: funnel exploration
RHMC with SoftAbs on the 101-dimensional funnel: trajectories sweep the entire funnel and the chain of v (only 100 iterations plotted, compared with 2500 for Figure 7) has mean 0.42 and standard deviation 2.76 against the true (0,3): nearly independent transitions and drastically smaller autocorrelations.
Why λcoth(αλ) is positive definite
For λ→±∞, λcoth(αλ)→∣λ∣; at λ→0, it tends to 1/α. Hence every eigenvalue maps to a positive number at least 1/α, behaving like ∣λ∣ for large curvature. A numpy check:
Cost. RHMC needs Hessians (second derivatives) and an implicit integrator in general, so it is considerably more expensive per step; the paper notes that RHMC was not run in the Stan benchmarks because its Stan implementation was still under development. In practice (2020s) Stan/PyMC use Euclidean NUTS with reparameterisation.