lmcinnes / lmcinnes/umap

ParameticUMAP does not separate classes in supervised regime, while UMAP does

Open
#971 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
8.3k
Forks
871
Avg merge
1d 13h
Merged PRs (30d)
5

Description

Hello, I have a peculiar situation with ParametricUMAP. I have 12000 kind-of 8x8 images, which I want to reduce to 2 dimensions. Each image has a class label (0 or 1). The two classes are perfectly separated if I use regular UMAP in a supervised mode, however, applying the transform to new data points is painfully slow. It takes ca. 5 seconds for a single 8x8 image. My data comes in batches of 1 sample and thus I cannot combine multiple images into a single batch to speed up processing.
UmapSupervised
So I decided to try ParametricUMAP, which should help me to speed up the inference. But when applying ParametricUMAP to my data I completely lose class separation and the result looks very much like unsupervised UMAP.
Here is how it looks for supervised parametric

ParametricUmapSupervised

and unsupervised regular UMAP
UmapUnsupervised

I tried setting target_weight to 0.9 and it didn't change a thing.
Any idea what's causing such behavior?

Thank you.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the supervised ParametricUMAP behavior with the 8x8 images, binary labels, and target_weight=0.9 described in the issue, then compare it with supervised regular UMAP and unsupervised UMAP. Done means identifying why class separation is lost or documenting the relevant limitation while preserving the intended faster inference for single-sample batches.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
machine-learning
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.