princeton-nlp / SimCSE

[EMNLP 2021] SimCSE: Simple Contrastive Learning of Sentence Embeddings https://arxiv.org/abs/2104.08821
MIT License
3.31k stars 502 forks source link

Can I load saved index to GPU? #270

Closed Maydaytyh closed 4 months ago

Maydaytyh commented 6 months ago

Hi, due to the large number of sentences, it's not possible to save them all at once. Therefore, I've split them into 10 smaller files. Is it possible to load the index onto the GPU when loading? Loading into memory might still result in an overflow.

gaotianyu1350 commented 6 months ago

Hi,

Usually if it doesn't fit in CPU memory it won't fit in the GPU memory either. I would suggest exploring some of the index compression options in faiss

github-actions[bot] commented 5 months ago

Stale issue message