[FEA] Follow-up work on Cosine distance for IVF-Flat (Norm precomputation)
Nobody has claimed this yet.
- Dominant language
- Cuda
- Stars
- 854
- Forks
- 236
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 62
Description
As pointed by Tamas in his review, we should consider whether it is more efficient to pre-computing the norms before the distance computation kernel.
https://github.com/rapidsai/cuvs/pull/179#pullrequestreview-2189437185
We should ask the question whether it is more efficient to compute the norms here or precompute them:
- we could store norm of database vectors in the index
- query norm is recalculated every time we process vector in the cluster. I expect that it would be better to use precalculated query norm, but we should confirm that by measurement. Please open an issue to track this, and improve this in a follow-up PR.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked PR review and the IVF-Flat cosine distance computation kernel mentioned there. Benchmark computing norms during distance evaluation against precomputing database and query norms; done means recording the comparison and implementing the more efficient approach in a follow-up change.
Written by the indexing model from the issue text.
Assessment
- Domain
- performance, search
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100