I am building an image search service. I tried to make an index with 12500 dimensions ( naive image bottlenecks ) and 5000 images. It is running on standard vps machine with 2GB of ram. But I am getting the memory error. I know that the number of dimensions is pretty high, but I thought that this will fit into memory easily.
Does everything needs to be in memory or is the index able to use some harddisk space? Are there some optimalizations besice reducing number of dimensions which I can do?
I am using IndexFlatL2(d) quantizes and index faiss.IndexIVFFlat(quantizer, d, nlist, faiss.METRIC_L2)
OS:
Faiss version:
Faiss compilation options:
Running on:
Interface:
Your best bet is probably do reduce dimensions first. Otherwise, you can also use an index with compression (see wiki/Lower-memory-footprint). If none of that works for you, you could indeed use on-disk IVF lists.
Thanks. I will try it.
Most helpful comment
Your best bet is probably do reduce dimensions first. Otherwise, you can also use an index with compression (see wiki/Lower-memory-footprint). If none of that works for you, you could indeed use on-disk IVF lists.