A solution for the mean parametrization of the von Mises-Fisher distribution

Marcel Nonnenmacher, Maneesh SahaniarXiv 2024 · DOI

Abstract

The von Mises-Fisher distribution as an exponential family can be expressed in terms of either its natural or its mean parameters. Unfortunately, however, the normalization function for the distribution in terms of its mean parameters is not available in closed form, limiting the practicality of the mean parametrization and complicating maximum-likelihood estimation more generally. We derive a second-order ordinary differential equation, the solution to which yields the mean-parameter normalizer along with its first two derivatives, as well as the variance function of the family. We also provide closed-form approximations to the solution of the differential equation. This allows rapid evaluation of both densities and natural parameters in terms of mean parameters. We show applications to topic modeling with mixtures of von Mises-Fisher distributions using Bregman Clustering.

Introduction

The von Mises-Fisher (vMF) distribution is a fundamental tool for directional statistics, often described as the "Gaussian of the hypersphere." In machine learning, it is frequently used to model data on a unit sphere, such as normalized text embeddings or directional statistics. While the natural parametrization (direction and concentration) is standard, the mean parametrization is often more intuitive for learning and clustering tasks.

However, the negative entropy function ($\Psi$), which serves as the normalizer for the mean parameters, lacks a closed-form expression. Historically, researchers have relied on iterative root-finding involving ratios of modified Bessel functions, which is computationally expensive and numerically finicky in high dimensions. This has limited the adoption of efficient algorithms like Bregman clustering for vMF models.

Methodology: An ODE-based Approach

The authors bridge this gap by deriving a second-order nonlinear ordinary differential equation (ODE) that exactly describes the radial profile of the negative entropy. This derivation leverages two key properties of the vMF distribution: its radial symmetry and its support strictly on the surface of the hypersphere ($S^{D-1}$).

A key insight, termed the "Trace Trick," links the trace of the variance function to the geometric constraint of the unit sphere. Because all data points lie on the sphere, the trace of the covariance matrix is bounded by $1 - \|\mu\|^2$. This constraint allows the derivation of the ODE, which provides the normalizer and its first two derivatives (relating to the variance).

Beyond numerical solutions to the ODE, the paper introduces high-precision closed-form approximations using rational functions. These approximations are computationally efficient, requiring only a handful of algebraic operations compared to the hundreds needed for traditional iterative solvers.

Accuracy of the closed-form approximations for the negative entropy and its derivatives across different dimensions.

Experimental Results

The proposed methods were evaluated for both numerical precision and practical utility in high-dimensional clustering tasks.

Numerical Precision and the Blessing of Dimensionality

The ODE approach achieves numerical errors as low as $10^{-12}$. Notably, the rational function approximations exhibit a "blessing of dimensionality": their accuracy improves as the dimension $D$ increases. For very high dimensions ($D \geq 50,000$), the approximations become virtually indistinguishable from exact numerical solutions.

Document Clustering Performance

To test real-world applicability, the authors performed document clustering on benchmarks such as Classic3 ($D=4,674$) and News20 ($D=28,571$). Using the new approximations, mean-parameter Bregman clustering was compared against standard natural-parameter EM.

Comparison of Bregman clustering (using the new approximations) and standard EM on document datasets, showing nearly identical performance.

As shown in the figure, the performance (measured by Normalized Mutual Information) of Bregman clustering using the mean-parameter approximations is nearly identical to that of standard EM. This demonstrates that the approximations are sufficiently accurate for high-dimensional machine learning pipelines, providing a significant speedup without sacrificing quality.

Conclusion

This work provides a robust mathematical foundation for the mean parametrization of the vMF distribution. By transforming a difficult root-finding problem into a well-behaved ODE and providing efficient approximations, the authors enable the practical use of Bregman clustering for directional data. Future work may explore applying the "trace condition" to discover new exponential families on the hypersphere.

Summary updated

BibTeX
@misc{nonnenmacher2024solution,
  author = {Marcel Nonnenmacher and Maneesh Sahani},
  title = {{A solution for the mean parametrization of the von Mises-Fisher distribution}},
  year = {2024},
  eprint = {2404.07358},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2404.07358},
}
Figure