facebookresearch / faiss

A library for efficient similarity search and clustering of dense vectors.
https://faiss.ai
MIT License
31.35k stars 3.64k forks source link

Bug: Build Frome Srouce 'GpuIndexIVFPQ' object has no attribute 'setNumProbes' #2790

Closed matchyc closed 4 months ago

matchyc commented 1 year ago

Summary

Building Frome Srouce 'GpuIndexIVFPQ' object has no attribute 'setNumProbes'

Run bench_gpu_sift1m.py Exact Search Totally OK Approximate Search with IVFPQ NO: 'GpuIndexIVFPQ' object has no attribute 'setNumProbes'

Platform

OS: Ubuntu 20.04

Faiss version: 1.7.3 (main branch)

Installed from: Build From Source

Faiss compilation options:

Running on:

Interface:

Reproduction instructions

Strictly Follow INSTALL.md Section "Building from source"

except cmake step command: cmake -B build . -DFAISS_ENABLE_GPU=ON -DFAISS_ENABLE_PYTHON=ON -DCMAKE_BUILD_TYPE=Release -DPython_EXECUTABLE=\<my conda environment interpreter path>

Note:

  1. Working well using GpuFlatIndex
  2. Working well if faiss installed by conda (conda install faiss-gpu)
mdouze commented 1 year ago

the function was removed, please set the number of probes directly, with

index.nprobe = 123