Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Accept custom distance function based on labels #46

Open
krrishh-org opened this issue Apr 13, 2022 · 2 comments
Open

Comments

@krrishh-org
Copy link

I have a distance matrix precalculated for each pair of labels, and I would like to pass that distance instead of eucliden or some other method.

It will e helpful if the distanceFn accepts a function that takes two labels as arguments and return the distance.

@zdk123
Copy link

zdk123 commented May 12, 2022

You can already do this. See this example: https://observablehq.com/@fil/umap-simple-topologies

@krrishh-org
Copy link
Author

Hi @zdk123,

Thank you for this. But I needed the distanceFn to be invoked using the labels instead of indices for supervised projection. I created a workaround in my local by mapping labels to indices.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants