Readit News logoReadit News
Posted by u/verse 2 years ago
Show HN: I made a Pinterest clone using SigLIP image embeddingsmood-amber.vercel.app...
Click an image to get similar images.

I crawled Tumblr and used SigLIP to get vector embeddings for many images.

When you click an image, it finds the most similar vector embeddings in the database, and returns the corresponding images.

yorwba · 2 years ago
Sometimes there are duplicate results, e.g. https://mood-amber.vercel.app/images/0b733fc2-7093-4443-8872... has two copies of https://mood-amber.vercel.app/images/f920a599-bbd7-4805-3317... right next to each other. (The link UUID is the same, so I assume this is an issue with the search algorithm, not simply duplicate data that got scraped.)
verse · 2 years ago
ah! thank you for pointing this out. will fix
lulzx · 2 years ago
wucaworld · 2 years ago
Very cool! How did you get the collage layout? I noticed images in each column don’t have the same size. I assume images get Centre cropped?
jkcxn · 2 years ago
It’s called a masonry grid. Images retain their aspect ratio so they don’t need to be cropped. You can kind of simulate it with css but there’s proposals to add a proper masonry layout to css
verse · 2 years ago
yeah. I actually wrote the logic for the layout myself (wasn't really happy with the available libraries). may open source this if people are interested!
omeze · 2 years ago
Cool! I haven’t tried SigLIP out yet but it seems to be the new hotness over CLIP… I just dont have a good project idea yet
Tiberium · 2 years ago
Is there a repo, especially for training? I'd like to see how SigLIP performs on a dataset of only anime images.
jarebear6expepj · 2 years ago
The the vision training models are available here: https://github.com/google-research/big_vision/tree/main which I am assuming, based on the research paper is what was used for the project.
gammalost · 2 years ago
There are some interesting images there. Why are you not including the source of the images?
GamerAlias · 2 years ago
Good stuff! Do you have any intuitive sense of whether SigLIP is particularly stronger than CLIP here? Also vector DB over Faiss index?
verse · 2 years ago
I haven't done much testing or anything, but it seems to me that siglip "understands" what it's looking at more than CLIP

also no, I just put everything on Supabase and added pgvector. super easy:

https://supabase.com/docs/guides/database/extensions/pgvecto...

ReD_CoDE · 2 years ago
qdrant doesn't support vector DB over Faiss index?

Also, pgvector or qdrant? which is better?

squam · 2 years ago
Cool project! Thanks for sharing