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

umap.UMAP accepts strings as n_neighbors and min_dist, causing later failures #1099

Open
conchoecia opened this issue Mar 8, 2024 · 0 comments

Comments

@conchoecia
Copy link

Hello, when I run this code, it does not fail.

>>> import umap
>>> n_neighbors = "5"
>>> min_dist = "0.01"
>>> reducer = umap.UMAP(n_neighbors = n_neighbors, min_dist = min_dist)
>>> 

The problem is that when I try to fit the data, I get an error:

mapper = reducer.fit(df.to_numpy())

results in '<' not supported between instances of 'numpy.ndarray' and 'str'

It would be nice if umap.UMAP enforced a type float or int for the variables n_neighbors or min_dist to avoid failing later without a clear error message. Thank you!

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

1 participant