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

CAGRA-Q search #2206

Merged
merged 36 commits into from
Mar 21, 2024
Merged

CAGRA-Q search #2206

merged 36 commits into from
Mar 21, 2024

Conversation

enp1s0
Copy link
Member

@enp1s0 enp1s0 commented Feb 29, 2024

Rel: #1889

Limitations

  • Only 8-bit PQ is supported
  • Sub-space size is only 2 supported

@enp1s0 enp1s0 requested a review from a team as a code owner February 29, 2024 09:13
Copy link

copy-pr-bot bot commented Feb 29, 2024

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@github-actions github-actions bot added the cpp label Feb 29, 2024
@enp1s0 enp1s0 added 5 - DO NOT MERGE Hold off on merging; see PR for details feature request New feature or request non-breaking Non-breaking change and removed cpp labels Feb 29, 2024
@enp1s0 enp1s0 self-assigned this Mar 1, 2024
@github-actions github-actions bot added the cpp label Mar 1, 2024
@enp1s0 enp1s0 requested review from a team as code owners March 1, 2024 09:16
@achirkin
Copy link
Contributor

achirkin commented Mar 4, 2024

/ok to test

Copy link
Contributor

@achirkin achirkin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @enp1s0, for working on this!
I love your modular approach of using dataset descriptor to abstract away the distance computation code. I think we'll have to think a bit later whether it's possible to unify/backport this to IVF methods.

I'm trying now integrate the index building (compression) part, and I want to figure out how much of the functionality to implement at first.
As far as I see now, both the ported code and the original prototype support only pq_bits = 8, is that correct? There's probably some limitation on possible pq_dim values as well.
Could you please write down these and possibly other limitations of the prototype/initial port (search part only) in the description of the PR?

@achirkin
Copy link
Contributor

achirkin commented Mar 5, 2024

/ok to test

achirkin added a commit to achirkin/raft that referenced this pull request Mar 13, 2024
@achirkin
Copy link
Contributor

/ok to test

Copy link
Contributor

@tfeher tfeher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @enp1s0 and @achirkin for your work. The PR looks good to me. There are a few additional issues that we can handle in a follow up PR.

Additionally, the test seem to compile too long, I will check whether there is any unintended template instantiation:

file compile time binary size
ann_cagra/test_half_uint32_t.cu.o 31:37 min 91.827 MB
ann_cagra/test_int8_t_uint32_t.cu.o 31:11 min 91.846 MB
ann_cagra/test_float_uint32_t.cu.o 30:41 min 91.709 MB
ann_cagra/test_uint8_t_uint32_t.cu.o 30:22 min 91.874 MB
ann_cagra_vpq/test_float_int64_t.cu.o 17:40 min 46.242 MB
ann_cagra/test_half_int64_t.cu.o 17:27 min 46.422 MB
ann_cagra/test_float_int64_t.cu.o 15:31 min 37.865 MB
bench/cagra_float_uint32_t.cu.o 14:09 min 47.566 MB
test_filter_float_int64_t.cu.o 10:49 min 19.376 MB
ann_cagra_vpq/test_float_uint32_t.cu.o 7:52 min 11.921 MB

cpp/include/raft/neighbors/detail/cagra/cagra_search.cuh Outdated Show resolved Hide resolved
cpp/test/neighbors/ann_cagra_vpq.cuh Outdated Show resolved Hide resolved
@tfeher tfeher dismissed achirkin’s stale review March 21, 2024 05:52

The issues have been addressed.

@tfeher
Copy link
Contributor

tfeher commented Mar 21, 2024

/merge

@rapids-bot rapids-bot bot merged commit de7341e into rapidsai:branch-24.04 Mar 21, 2024
71 checks passed
rapids-bot bot pushed a commit that referenced this pull request Mar 21, 2024
Add the relevant options to the CAGRA parameter parser and refinement to the CAGRA ANN benchmark.
No changes to the library code.

NB: the new option won't work correctly until #2206 is merged.

Authors:
  - Artem M. Chirkin (https://github.com/achirkin)

Approvers:
  - Tamas Bela Feher (https://github.com/tfeher)

URL: #2233
@tfeher tfeher mentioned this pull request Mar 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging this pull request may close these issues.

3 participants