Instructions to use google/vit-base-patch16-224 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use google/vit-base-patch16-224 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="google/vit-base-patch16-224") 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("google/vit-base-patch16-224") model = AutoModelForImageClassification.from_pretrained("google/vit-base-patch16-224") - Inference
- Notebooks
- Google Colab
- Kaggle
Finetuning
#16
by saneowl - opened
Hi,
Is it possible to finetune this model on another collection of images? If so, could anyone provide the code to do it?
Hi @oscarwang2 , Yes it is possible to fine-tune the Vision Transformer model on your custom dataset of Images with labels. Here is one such tutorial by huggingface https://huggingface.co/blog/fine-tune-vit