Zero-Shot Image Classification
Transformers
Safetensors
clip
How to use from the
Use from the
Transformers library
# Use a pipeline as a high-level helper
from transformers import pipeline

pipe = pipeline("zero-shot-image-classification", model="cs-giung/clip-vit-base-patch32-laion2b")
pipe(
    "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png",
    candidate_labels=["animals", "humans", "landscape"],
)
# Load model directly
from transformers import AutoProcessor, AutoModelForZeroShotImageClassification

processor = AutoProcessor.from_pretrained("cs-giung/clip-vit-base-patch32-laion2b")
model = AutoModelForZeroShotImageClassification.from_pretrained("cs-giung/clip-vit-base-patch32-laion2b", device_map="auto")
Quick Links

CLIP

Contrastive Language-Image Pretraining (CLIP) model pre-trained on LAION-2B at resolution 224x224. It was introduced in the paper Learning Transferable Visual Models From Natural Language Supervision and further reproduced in the follow-up paper Reproducible scaling laws for contrastive language-image learning. The weights were converted from the laion/CLIP-ViT-B-32-laion2B-s34B-b79K presented in the OpenCLIP LAION-2B collections.

Downloads last month
8
Safetensors
Model size
0.2B params
Tensor type
I64
·
F32
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Collection including cs-giung/clip-vit-base-patch32-laion2b

Papers for cs-giung/clip-vit-base-patch32-laion2b