Learning Low-Dimensional Metrics

Blake Mason, Lalit Jain, Robert D. NowakNeurIPS 2017

Overview

This paper provides the first tight theoretical guarantees for learning low-dimensional and sparse metrics from human-style "triplet" comparisons (e.g., "Is item A more similar to B than it is to C?"). The authors prove that the number of samples needed scales with the intrinsic dimensionality of the metric rather than the raw feature size. Furthermore, they demonstrate how to accurately recover the underlying "true" metric, paving the way for better interpretability in fields ranging from cognitive science to recommendation systems.

The Challenge of Metric Learning

In many domains, we want to understand how humans perceive similarity. While a computer might represent an image using thousands of raw pixels (high-dimensional features), a human might only care about a few key attributes like color or shape (a low-dimensional metric).

The standard approach to this problem is Metric Learning, where the goal is to find a transformation matrix $K$ that maps raw features into a space where distances match human judgments. These judgments are usually collected as triplets: "Is the distance between $i$ and $j$ less than the distance between $i$ and $k$?"

Prior research left several critical gaps:

  1. Sample Complexity: Exactly how many comparisons do we need if the underlying metric is low-rank or sparse?
  2. Optimality: Are our current algorithms theoretically as good as they can possibly be?
  3. Model Identification: Can we actually find the true underlying metric $K^*$, or are we just getting good at predicting future triplets? This distinction is vital for scientists who want to know which specific features drive human perception.

Methods: Regularizing for Human Perception

The authors frame the problem as learning a symmetric positive semi-definite (PSD) matrix $K$. To handle high-dimensional data efficiently, they focus on two types of regularization:

  • Nuclear Norm Regularization: Encourages a low-rank $K$, meaning the metric depends on a small number of latent factors (linear combinations of features).
  • $\ell_{1,2}$ (Group Lasso) Regularization: Encourages row-sparsity, meaning the metric completely ignores "irrelevant" raw features.

Technically, the study analyzes the Generalization Error (how well the learned metric predicts unseen triplets) and the Model Identification Error (the Frobenius distance between the learned $K$ and the true $K^*$). They use advanced tools from statistical learning theory, including Rademacher complexity and minimax analysis, to prove their bounds.

Key Insights and Scaling Laws

  • The $dp$ Scaling Law: The authors show that for isotropic data, the sample complexity scales roughly as $O(dp \log p)$, where $p$ is the feature dimension and $d$ is the rank of the metric. This confirms the intuition that learning a low-rank metric is significantly easier than learning a full-rank one (which would scale with $p^2$).
Linear dependence of sample complexity on the number of features
  • Sparsity Isn't a "Free Lunch": Surprisingly, the minimax lower bounds show that learning a sparse metric is theoretically just as difficult as learning a general low-rank metric in the worst case. However, in practice, if the ground truth is indeed sparse, $\ell_{1,2}$ regularization still provides a noticeable performance boost.
  • Recovering the "Truth": The paper provides a novel way to bound the error of the matrix $K$ itself. They show that if you have enough samples and the data is "centered," you can accurately identify the parameters of the human perception model, not just mimic its output.
  • Ordinal Embedding Link: They demonstrate that "Ordinal Embedding" (finding coordinates for points given only distance comparisons) is a special case of their framework where the feature matrix is simply the identity matrix.

Key Results and Simulations

Using synthetic simulations with $n=200$ items and $p=100$ features (generated from standard normal distributions), the authors validated their theoretical findings. They established tight upper bounds on prediction error and proved matching lower bounds (up to logarithmic factors), showing their analysis is nearly optimal.

Excess risk and recovery error for different regularizations

The experiments confirmed that:

  • When the true metric is sparse, $\ell_{1,2}$ regularization significantly outperforms standard PSD constraints.
  • When the metric is dense but low-rank, Nuclear Norm regularization is superior.
  • The number of samples required to reach a specific error threshold grows linearly with both the embedding dimension $d$ and the number of features $p$.

Limitations and Future Work

While the theoretical guarantees are strong, the paper notes a few limitations:

  • Isotropic Assumption: Much of the clean "sample complexity" results rely on the features being isotropic (distributed evenly in all directions). Real-world features, like deep learning embeddings, are often highly correlated, which might complicate the bounds.
  • Computational Complexity: The paper focuses on the statistical limits (how much data is needed). Solving the resulting optimization problems for very large $p$ (e.g., millions of features) remains a significant computational challenge.
  • Link Function Sensitivity: The recovery of the true metric $K^*$ assumes we know the "link function"—how distance differences translate into the probability of a human choice. If this model is misspecified, the identification guarantees may degrade.

Summary updated

BibTeX
@inproceedings{mason2017learning,
  author = {Blake Mason and Lalit Jain and Robert D. Nowak},
  title = {{Learning Low-Dimensional Metrics}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2017},
  url = {https://openreview.net/forum?id=HkV7lKWObB},
}
Figure