NVIDIA / NVIDIA/cuvs

Lucene: missing safeguard to prevent user from accidentally choosing an odd CagraGraphDegree

Open
#2,455 3 comments 0 reactions 1 assignee View on GitHub

@imotov is already working on this.

Since Aug 17, 2026.

Dominant language
Cuda
Stars
854
Forks
236
Avg merge
3d 3h
Merged PRs (30d)
62

Description

When I pick an odd number as my CagraGraphDegree, we spend the normal amount of time to index, but then we skip querying altogether and provide NaN values for recall. I think Cagra technically requires CagraGraphDegree to be even, but there is no enforcement of this and it took me a while to figure out that setting CagraGraphDegree to be even was one way around this issue -- since others may face this issue in the future, I'm creating this issue to address potentially adding in some sort of enforcement or message to the user (or alternatively would it make sense to just automatically round up to the nearest even number?)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.