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

adding nan_euclidean metric #3355

Open
PolarBean opened this issue Apr 8, 2024 · 2 comments
Open

adding nan_euclidean metric #3355

PolarBean opened this issue Apr 8, 2024 · 2 comments

Comments

@PolarBean
Copy link

Summary

Sklearn has recently added support for the nan_euclidean as detailed in this issue scikit-learn/scikit-learn#25319

Is it possible this will be added to faiss in the future? thank you.

@mdouze
Copy link
Contributor

mdouze commented Apr 11, 2024

We can make an enhancement of it.
For new metrics, the first stage is to support them for brute force search in

https://github.com/facebookresearch/faiss/blob/main/faiss/utils/extra_distances-inl.h

this will enable them for FlatCodes search and HNSW search.

facebook-github-bot pushed a commit that referenced this issue May 6, 2024
Summary:
#3355

A couple open questions:
- Given L2 was squared, I figured I would leave this one as squared as well?
- Also, wasn't sure if we wanted to return nan when present == 0 or -1?

Differential Revision: D57017608
asadoughi pushed a commit that referenced this issue May 6, 2024
Summary:

#3355

A couple open questions:
- Given L2 was squared, I figured I would leave this one as squared as well?
- Also, wasn't sure if we wanted to return nan when present == 0 or -1?

Differential Revision: D57017608
facebook-github-bot pushed a commit that referenced this issue May 15, 2024
Summary:

#3355

A couple open questions:
- Given L2 was squared, I figured I would leave this one as squared as well?
- Also, wasn't sure if we wanted to return nan when present == 0 or -1?

Reviewed By: mdouze

Differential Revision: D57017608
facebook-github-bot pushed a commit that referenced this issue May 15, 2024
Summary:

#3355

A couple open questions:
- Given L2 was squared, I figured I would leave this one as squared as well?
- Also, wasn't sure if we wanted to return nan when present == 0 or -1?

Reviewed By: mdouze

Differential Revision: D57017608
asadoughi pushed a commit that referenced this issue May 15, 2024
Summary:

#3355

A couple open questions:
- Given L2 was squared, I figured I would leave this one as squared as well?
- Also, wasn't sure if we wanted to return nan when present == 0 or -1?

Reviewed By: mdouze

Differential Revision: D57017608
facebook-github-bot pushed a commit that referenced this issue May 16, 2024
Summary:
Pull Request resolved: #3414

#3355

A couple open questions:
- Given L2 was squared, I figured I would leave this one as squared as well?
- Also, wasn't sure if we wanted to return nan when present == 0 or -1?

Reviewed By: mdouze

Differential Revision: D57017608

fbshipit-source-id: ba14458b92c8b055f3bf2a871565175935c8333a
@MarcYin
Copy link

MarcYin commented Jun 3, 2024

Is this going to be implemented for the gpu case?

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

No branches or pull requests

3 participants