-
Notifications
You must be signed in to change notification settings - Fork 107
Common knn graph build params #949
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
base: branch-25.08
Are you sure you want to change the base?
Conversation
@@ -0,0 +1,78 @@ | |||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cuVS isn't header-only, so the header files are very lightweight. Instead of introducing new headers for structs and enums, can we just reuse common.hpp?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
common.hpp
has the base index_params
(link), so declaring graph_build_params
in that file results in a circular dependency (because we make use of ivf_pq::index_params
and nn_descent::index_params
inside `graph_build_params)
struct ivf_pq_params { | ||
cuvs::neighbors::ivf_pq::index_params build_params; | ||
cuvs::neighbors::ivf_pq::search_params search_params; | ||
float refinement_rate = 2.0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the default value 1 or 2?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a bit tricky here... cagra uses the ivf_pq_params()
constructor and expects a default refinement rate of 1.0, whereas all neighbors expects a default refinement rate of 2.0.
I agree that this is confusing. Maybe we should set the default to 1.0 and make changes from the all neighbors usage.
@lowener Changed defaults. Ready for another round of reviews : ) |
Reusing graph build params for cagra and all neighbors.
Related issue: #931