mirror of
https://github.com/facebookresearch/faiss.git
synced 2025-06-03 21:54:02 +08:00
Summary: **Bugs:** When following rocksdb_ivf demo to build executable file, its output as: ```bash faiss/demos/rocksdb_ivf/RocksDBInvertedLists.h:52:35: error: 'faiss::InvertedListsIterator* faiss_rocksdb::RocksDBInvertedLists::get_iterator(size_t) const' marked 'override', but does not override 52 | faiss::InvertedListsIterator* get_iterator(size_t list_no) const override; | ^~~~~~~~~~~~ make[2]: *** [CMakeFiles/demo_rocksdb_ivf.dir/build.make:90: CMakeFiles/demo_rocksdb_ivf.dir/RocksDBInvertedLists.cpp.o] Error 1 ``` **Solution:** Add relevant variable `void* inverted_list_contex` corresponding `get_iterator`'s base virtual function. Pull Request resolved: https://github.com/facebookresearch/faiss/pull/3326 Reviewed By: mlomeli1, mdouze Differential Revision: D55629580 Pulled By: algoriddle fbshipit-source-id: a12fcacb483e0dd576411ad91a3dd1e0de94abec
Demos for a few Faiss functionalities
demo_auto_tune.py
Demonstrates the auto-tuning functionality of Faiss
demo_ondisk_ivf.py
Shows how to construct a Faiss index that stores the inverted file data on disk, eg. when it does not fit in RAM. The script works on a small dataset (sift1M) for demonstration and proceeds in stages:
0: train on the dataset
1-4: build 4 indexes, each containing 1/4 of the dataset. This can be done in parallel on several machines
5: merge the 4 indexes into one that is written directly to disk (needs not to fit in RAM)
6: load and test the index