Commit Graph

3 Commits (50f323249be955180f2f84db76444729bbef67f0)

Author SHA1 Message Date
Amir Sadoughi a11c1dbab6 Added IndexLSH to the demo (#4009)
Summary:
Demonstrate IndexLSH does not need training or codebook serialization

Pull Request resolved: https://github.com/facebookresearch/faiss/pull/4009

Reviewed By: junjieqi

Differential Revision: D65274645

Pulled By: asadoughi

fbshipit-source-id: c9af463757edbd07cc07b1cf607b88373fa334c4
2024-11-04 10:21:44 -08:00
Amir Sadoughi acaa01f32d Moved add_sa_codes, sa_code_size to Index, IndexBinary base classes (#3989)
Summary:
Pull Request resolved: https://github.com/facebookresearch/faiss/pull/3989

Moved add_sa_codes, sa_code_size to Index, IndexBinary base classes from IndexIVF to support adding coded vectors with ids using IDMap2,PQ

For an alternative approach, see previous attempt with merge_ids and merge_codes: D64941798

Reviewed By: mnorris11

Differential Revision: D64972587

fbshipit-source-id: 71622fc35a378d9892569a56442a872f0c9c9e83
2024-10-28 19:56:00 -07:00
Amir Sadoughi 1e7ef59194 demo: IndexPQ: separate codes from codebook (#3987)
Summary:
Pull Request resolved: https://github.com/facebookresearch/faiss/pull/3987

Created a new notebook demonstrating how to separate serializing and deserializing the PQ codebook (via faiss.write_index for IndexPQ) independently of the vector codes. For example, in the case where you have a few vector embeddings per user and want to shard the flat index by user you can re-use the same PQ method for all users but store each user's codes independently.

Reviewed By: junjieqi

Differential Revision: D64844978

fbshipit-source-id: ad6434101fbb3ef84999527a577ecb9b503e556c
2024-10-24 05:42:41 -07:00