Towards Generalized and Efficient Metric Learning on Riemannian Manifold

Pengfei Zhu, Hao Cheng, Qinghua Hu, Qilong Wang, Changqing Zhang

Metric learning on Riemannian manifolds has become a cornerstone of modern computer vision, particularly for tasks involving image sets or video sequences. However, traditional approaches have long been hampered by a lack of generality across different manifold types and the high computational cost of iterative optimization. This paper introduces Riemannian Manifold Metric Learning (RMML), a unified framework that provides a global closed-form solution for both Symmetric Positive Definite (SPD) and Grassmann manifolds, offering a principled and highly efficient alternative to existing "black magic" iterative methods.

The Challenge: Generality and Efficiency

In many computer vision applications, data naturally resides on non-linear Riemannian manifolds. For instance, covariance matrices form an SPD manifold, while linear subspaces are represented as points on a Grassmann manifold. Learning a distance metric in these spaces is essential for classification and recognition.

Existing methods typically suffer from two limitations:

  1. Siloed Design: Algorithms are often engineered for a specific manifold type, making them difficult to generalize.
  2. Computational Bottlenecks: Optimization usually relies on Riemannian gradient descent. This requires moving iteratively between the manifold and its tangent space, a process that is computationally expensive and difficult to scale to large datasets.

The RMML Framework

RMML addresses these issues by unifying the treatment of SPD and Grassmann manifolds through a shared mathematical formulation. The authors utilize the Log-Euclidean Riemannian Metric (LERM) for SPD matrices and projection distances for Grassmannian points. This allows the distance between two points to be expressed in a quadratic form involving a transformation matrix $A$.

Closed-Form Optimization

Rather than relying on iterative solvers, RMML formulates an objective to minimize geodesic distances between similar pairs while maximizing them for dissimilar pairs. The authors demonstrate that the optimal transformation matrix $A$ is the solution to a Riccati equation. The global optimum is found to be the Riemannian geometric mean of the similarity matrix ($P^{-1}$) and the dissimilarity matrix ($N$).

By performing these operations in the Log-Euclidean framework (the "log domain"), the solution becomes a simple matrix exponential: $$A = \exp\left(\frac{-\log(P) + \log(N)}{2}\right)$$ This approach bypasses iterative loops entirely, leveraging standard linear algebra for massive speed gains.

Experimental Evaluation

The authors evaluated RMML across five diverse benchmarks: object recognition (ETH-80), material classification (FMD, UIUC), and face recognition/verification (YTC, YTF).

Efficiency and Computational Performance

The most striking result of RMML is its training speed. By utilizing a closed-form solution, RMML reduces training times from hundreds or thousands of seconds to mere fractions of a second.

Table 1: Comparison of training time (seconds) for RMML versus state-of-the-art iterative methods.

As shown in the table above, on the Flickr Material Dataset (FMD), the iterative PML method takes nearly 3,000 seconds to train, while RMML-SPD achieves the same task in just 0.11 seconds. This efficiency makes RMML uniquely suited for large-scale or online learning scenarios.

Classification Accuracy

Despite the radical increase in speed, RMML does not sacrifice performance. In fact, it consistently outperforms or matches state-of-the-art iterative methods like LEML and PML across all tested datasets.

Table 2: Comparison of classification accuracy (%) across five diverse visual recognition benchmarks.

On the YouTube Celebrities (YTC) dataset, RMML-SPD achieved an accuracy of 78.05%, a significant improvement over the 69.85% achieved by LEML. The results indicate that the geometric mean provides a natural and effective equilibrium for balancing similarity and dissimilarity constraints.

Conclusion

RMML represents a significant advancement in manifold-based metric learning. By identifying the structural harmony between different Riemannian geometries and providing a closed-form solution via the geometric mean, the authors have created a framework that is both more accurate and orders of magnitude faster than previous iterative approaches. Future work may extend this generalized approach to other Riemannian spaces, further expanding the toolkit for non-linear computer vision.

Summary updated

BibTeX
@inproceedings{zhu2018towards,
  author = {Pengfei Zhu and Hao Cheng and Qinghua Hu and Qilong Wang and Changqing Zhang},
  title = {{Towards Generalized and Efficient Metric Learning on Riemannian Manifold}},
  booktitle = {International Joint Conference on Artificial Intelligence},
  year = {2018},
  doi = {10.24963/ijcai.2018/449},
}
Figure