enterprise-explorers/oxford-pets
Viewer • Updated • 7.39k • 1.07k • 19
How to use asusevski/vit-base-patch16-224-oxford-pets with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("image-classification", model="asusevski/vit-base-patch16-224-oxford-pets")
pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png") # Load model directly
from transformers import AutoImageProcessor, AutoModelForImageClassification
processor = AutoImageProcessor.from_pretrained("asusevski/vit-base-patch16-224-oxford-pets")
model = AutoModelForImageClassification.from_pretrained("asusevski/vit-base-patch16-224-oxford-pets")This model is a fine-tuned version of google/vit-base-patch16-224 on the pcuenq/oxford-pets dataset. It achieves the following results on the evaluation set: