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

MB-60202 - IDMap2 Selector #12

Merged
merged 2 commits into from
Jan 12, 2024
Merged

MB-60202 - IDMap2 Selector #12

merged 2 commits into from
Jan 12, 2024

Conversation

metonymic-smokey
Copy link
Member

@metonymic-smokey metonymic-smokey commented Jan 10, 2024

This PR

  • cherry picks a commit which adds a selector which accounts for the user provided custom vector IDs when searching within a FAISS index.
  • adds a helper function to set the selector for IVF search parameters.

@metonymic-smokey metonymic-smokey changed the title IDMap2 Selector MB-60202 - IDMap2 Selector Jan 10, 2024
@metonymic-smokey metonymic-smokey marked this pull request as ready for review January 11, 2024 16:43
c_api/impl/AuxIndexStructures_c.cpp Outdated Show resolved Hide resolved
c_api/impl/AuxIndexStructures_c.cpp Outdated Show resolved Hide resolved
c_api/impl/AuxIndexStructures_c.cpp Outdated Show resolved Hide resolved
faiss/IndexIDMap.cpp Show resolved Hide resolved
Summary:
Pull Request resolved: facebookresearch#2848

Add selector support for IDMap wrapped indices.
Caveat: this requires to wrap the IDSelector with another selector. Since the params are const, the const is casted away.

This is a problem if the same params are used from multiple execution threads with different selectors. However, this seems rare enough to take the risk.

Reviewed By: alexanderguzhva

Differential Revision: D45598823

fbshipit-source-id: ec23465c13f1f8273a6a46f9aa869ccae2cdb79c
@abhinavdangeti abhinavdangeti merged commit b34ccf6 into bleve Jan 12, 2024
@abhinavdangeti abhinavdangeti deleted the idmap-sel branch January 12, 2024 17:25
CascadingRadium pushed a commit that referenced this pull request Aug 16, 2024
* Support Selector for IDMap (facebookresearch#2848)

Summary:
Pull Request resolved: facebookresearch#2848

Add selector support for IDMap wrapped indices.
Caveat: this requires to wrap the IDSelector with another selector. Since the params are const, the const is casted away.

This is a problem if the same params are used from multiple execution threads with different selectors. However, this seems rare enough to take the risk.

Reviewed By: alexanderguzhva

Differential Revision: D45598823

fbshipit-source-id: ec23465c13f1f8273a6a46f9aa869ccae2cdb79c

* added C API helper func

---------

Co-authored-by: Matthijs Douze <[email protected]>
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

Successfully merging this pull request may close these issues.

3 participants