Conditional ViT - B/16 - Categories
Introduced in LRVSF-Fashion: Extending Visual Search with Referring Instructions, Lepage et al. 2023
Data | Code | Models | Spaces |
---|---|---|---|
Full Dataset | Training Code | Categorical Model | LRVS-F Leaderboard |
Test set | Benchmark Code | Textual Model | Demo |
General Infos
Model finetuned from CLIP ViT-B/16 on LRVSF at 224x224. The conditioning categories are the following :
- Bags
- Feet
- Hands
- Head
- Lower Body
- Neck
- Outwear
- Upper Body
- Waist
- Whole Body
Research use only.
How to Use
from PIL import Image
import requests
from transformers import AutoProcessor, AutoModel
import torch
model = AutoModel.from_pretrained("Slep/CondViT-B16-cat")
processor = AutoProcessor.from_pretrained("Slep/CondViT-B16-cat")
url = "https://huggingface.co/datasets/Slep/LAION-RVS-Fashion/resolve/main/assets/108856.0.jpg"
img = Image.open(requests.get(url, stream=True).raw)
cat = "Bags"
inputs = processor(images=[img], categories=[cat])
raw_embedding = model(**inputs)
normalized_embedding = torch.nn.functional.normalize(raw_embedding, dim=-1)
- Downloads last month
- 94
Inference API (serverless) does not yet support model repos that contain custom code.
Dataset used to train Slep/CondViT-B16-cat
Space using Slep/CondViT-B16-cat 1
Evaluation results
- R@1 +10K Dist. on LAION - Referred Visual Search - Fashiontest set LRVSF Leaderboard93.44 ± 0.83
- R@5 +10K Dist. on LAION - Referred Visual Search - Fashiontest set LRVSF Leaderboard98.07 ± 0.37
- R@10 +10K Dist. on LAION - Referred Visual Search - Fashiontest set LRVSF Leaderboard98.69 ± 0.38
- R@20 +10K Dist. on LAION - Referred Visual Search - Fashiontest set LRVSF Leaderboard98.98 ± 0.34
- R@50 +10K Dist. on LAION - Referred Visual Search - Fashiontest set LRVSF Leaderboard99.55 ± 0.18
- R@1 +100K Dist. on LAION - Referred Visual Search - Fashiontest set LRVSF Leaderboard85.90 ± 1.37
- R@5 +100K Dist. on LAION - Referred Visual Search - Fashiontest set LRVSF Leaderboard94.22 ± 0.87
- R@10 +100K Dist. on LAION - Referred Visual Search - Fashiontest set LRVSF Leaderboard96.04 ± 0.68
- R@20 +100K Dist. on LAION - Referred Visual Search - Fashiontest set LRVSF Leaderboard97.18 ± 0.56
- R@50 +100K Dist. on LAION - Referred Visual Search - Fashiontest set LRVSF Leaderboard98.28 ± 0.34