rom1504 / clip-retrieval

Easily compute clip embeddings and build a clip retrieval system with them
https://rom1504.github.io/clip-retrieval/
MIT License
2.42k stars 213 forks source link

How to use downloaded KNN indices? #210

Closed abelghazinyan closed 1 year ago

abelghazinyan commented 1 year ago

Hey I want to download and locally use KNN indices for searching by queries. I want to use this

How to do that? And also how to have custom num limit. As I want to run it locally, I don't mind having to wait for long to retrieve let's say closest 100k queries.

How is that possible? Thanks for this amazing work!

rom1504 commented 1 year ago

Hi, you can simply download it and give it to clip-retrieval back

abelghazinyan commented 1 year ago

I don't see how to initialise it, can you help me

rom1504 commented 1 year ago

Follow this https://github.com/rom1504/clip-retrieval#clip-back

The output folder is the folder you download from hf

rom1504 commented 1 year ago

see https://github.com/rom1504/clip-retrieval/blob/main/docs/laion5B_back.md