enterprise-explorers/oxford-pets
Viewer • Updated • 7.39k • 1.28k • 19
How to use DGurgurov/clip-vit-base-patch32-oxford-pets with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("image-classification", model="DGurgurov/clip-vit-base-patch32-oxford-pets")
pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png") # Load model directly
from transformers import AutoProcessor, AutoModelForZeroShotImageClassification
processor = AutoProcessor.from_pretrained("DGurgurov/clip-vit-base-patch32-oxford-pets")
model = AutoModelForZeroShotImageClassification.from_pretrained("DGurgurov/clip-vit-base-patch32-oxford-pets", device_map="auto")This model is a fine-tuned version of OpenAI's CLIP model on the Oxford Pets dataset, intended for pets classification.
Trainable params: 151.2773M || All params: 151.2773M || Trainable%: 100.00%
Refer to the original CLIP repository.
[MIT]