NVIDIA / NVIDIA/cuvs

[BUG]CuVS-bench cagra + hnswlib runs into issue with quantized vector evaluation

Open
#752 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

Describe the bug
For hnswlin: Getting ERROR OCCURRED:'Failed to create an algo:invalid'hnswlib' '

Image
Image
Image

For cagra: Getting extremely low recall score
Image

Steps/Code to reproduce bug

  1. generates config.yaml the corresponding binary files as listed. Note the base and query are in int8(after scalar quantization), Ground truth is int32 as per the cuvs guidance.
    - name: hotpotqa-2048-euclidean-sq dims: 2048 base_file: hotpotqa-2048-euclidean-sq/base.i8bin query_file: hotpotqa-2048-euclidean-sq/query.i8bin groundtruth_neighbors_file: hotpotqa-2048-euclidean-sq/groundtruth.neighbors.ibin distance: euclidean
  2. In cuvs-bench:24.12a-cuda12.0-py3.11 this version of cuvs-bench container
  3. Export correct DATASET_PATH and DATASET_NAME
  4. python -m cuvs_bench.run -k 10 -bs 10000 --algorithms cuvs_cagra --groups base -f -m 'latency' --raft-log-level 'info' --dataset-configuration $DATASET_PATH/$DATASET_NAME/config.yaml --dataset $DATASET_NAME --dataset-path $DATASET_PATH --algorithms hnswlib,cuvs_cagra.

Expected behavior
hnswlib generates the evaluation results, and cagra generate reasonable score

Environment details (please complete the following information):

  • Environment location: [cuvs-bench:24.12a-cuda12.0-py3.11]
  • Method of RAFT install: [conda, Docker, or from source]
    • If method of install is [Docker], provide docker pull & docker run commands used: ```
      docker run --gpus all --rm -it -u $(id -u)
      --entrypoint /bin/bash
      --workdir /data/benchmarks
      -v $DATA_FOLDER:/data/benchmarks
      rapidsai/cuvs-bench:24.12a-cuda12.0-py3.11



**Additional context**
Add any other context about the problem here.

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.

Research direction

Start by reproducing the command from the issue in the cuvs-bench:24.12a-cuda12.0-py3.11 container with the supplied config.yaml and quantized dataset files. Compare the hnswlib failure and cuvs_cagra recall results with the expected evaluation output, then narrow the issue to the relevant benchmark or algorithm integration path. Done means hnswlib produces evaluation results and cagra reports reasonable recall.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, python
Domain
machine-learning, search, testing-qa
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.