English

Bayesian Metric Learning for Uncertainty Quantification in Image Retrieval

Machine Learning 2023-02-07 v2 Computer Vision and Pattern Recognition

Abstract

We propose the first Bayesian encoder for metric learning. Rather than relying on neural amortization as done in prior works, we learn a distribution over the network weights with the Laplace Approximation. We actualize this by first proving that the contrastive loss is a valid log-posterior. We then propose three methods that ensure a positive definite Hessian. Lastly, we present a novel decomposition of the Generalized Gauss-Newton approximation. Empirically, we show that our Laplacian Metric Learner (LAM) estimates well-calibrated uncertainties, reliably detects out-of-distribution examples, and yields state-of-the-art predictive performance.

Keywords

Cite

@article{arxiv.2302.01332,
  title  = {Bayesian Metric Learning for Uncertainty Quantification in Image Retrieval},
  author = {Frederik Warburg and Marco Miani and Silas Brack and Soren Hauberg},
  journal= {arXiv preprint arXiv:2302.01332},
  year   = {2023}
}

Comments

Code: https://github.com/FrederikWarburg/bayesian-metric-learning

R2 v1 2026-06-28T08:30:41.992Z