facebookresearch / faiss

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

RuntimeError: Error in faiss::Index* faiss::read_index(faiss::IOReader*, int) at /project/faiss/faiss/impl/index_read.cpp:1053: Index type 0x73726576 ("vers") not recognized #3888

Closed raju-kulkarni closed 1 month ago

raju-kulkarni commented 1 month ago

Summary

I am reading the faiss index inside the docker but getting above error. I checked the faiss-cpu version where it is created but still having the same problem. when I created a docker locally it is working well but in my platform it is giving error.

Platform

OS: Ubuntu 20.04

Faiss version: faiss-cpu==1.8.0.post1

Installed from: pip

Running on:

Interface:

Reproduction instructions

It is not running to my specific platform.   |   | 2024-09-25 16:59:48.508 | File "/usr/local/lib/python3.10/site-packages/faiss/swigfaiss_avx2.py", line 10538, in read_index |     |   | 2024-09-25 16:59:48.508 | index = faiss.read_index('./image_vector_db/index.bin')

asadoughi commented 1 month ago

Hi @raju-kulkarni - Installing faiss via pip is not supported by this repository. Please try installing faiss from conda: https://github.com/facebookresearch/faiss/blob/main/INSTALL.md#installing-faiss-via-conda

Tickdack commented 1 month ago

It means your index file is broken, when faiss process read the index file, it discern the tag doesn't contain in code, make sure train your index with your faiss in docker, but not use other odd files

raju-kulkarni commented 1 month ago

@Tickdack I am able to run this on linux machine, even I am to run the same index with docker also locally it is running but when I put this into my server it is having that index read problem. is index read function require internet access.

github-actions[bot] commented 1 month ago

This issue is stale because it has been open for 7 days with no activity.

github-actions[bot] commented 1 month ago

This issue was closed because it has been inactive for 7 days since being marked as stale.