English

On UMAP's true loss function

Machine Learning 2021-04-23 v2 Machine Learning

Abstract

UMAP has supplanted t-SNE as state-of-the-art for visualizing high-dimensional datasets in many disciplines, but the reason for its success is not well understood. In this work, we investigate UMAP's sampling based optimization scheme in detail. We derive UMAP's effective loss function in closed form and find that it differs from the published one. As a consequence, we show that UMAP does not aim to reproduce its theoretically motivated high-dimensional UMAP similarities. Instead, it tries to reproduce similarities that only encode the shared kk nearest neighbor graph, thereby challenging the previous understanding of UMAP's effectiveness. Instead, we claim that the key to UMAP's success is its implicit balancing of attraction and repulsion resulting from negative sampling. This balancing in turn facilitates optimization via gradient descent. We corroborate our theoretical findings on toy and single cell RNA sequencing data.

Keywords

Cite

@article{arxiv.2103.14608,
  title  = {On UMAP's true loss function},
  author = {Sebastian Damrich and Fred A. Hamprecht},
  journal= {arXiv preprint arXiv:2103.14608},
  year   = {2021}
}

Comments

20 pages, 15 figures; minor changes, added run-times and error bars

R2 v1 2026-06-24T00:35:44.855Z