An index points to data in a table. In a database, indexes are similar to those in books. I am a little bit confused about the meaning of index in Faiss library and how it's different from the one in the database please if possible?
Asked
Active
Viewed 297 times
1 Answers
1
TL;DR;
FAISS Indexation is done over an encoding of the vectors and it is used for similarity search. Whereas, traditional database indexation is done for exact lookups.
FAISS
Purpose: to efficiently find the most similar high-demension vector from the input vector. Typically for machine learning purposes. A perfect match is not mandatory.
Method:
- Encoding the vectors. Assuming each dimension is stored in a separate field or column, we bring them together into a single field. Even a dimensionality reduction is possible, but that has to be balanced with any loss of information.
- Building the index. This is done over the encoded vector and methods can be similar to traditional db indexation.
- Querying. Traditional db look ups will look for exact matches in the index, but with FAISS, a similarity metric (e.g. cosine similarity) is used to find the best matches.
Bruno Lubascher
- 3,488
- 1
- 11
- 35