Instructions to use sgraham/met_model with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use sgraham/met_model with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("zero-shot-image-classification", model="sgraham/met_model") pipe( "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png", candidate_labels=["animals", "humans", "landscape"], )# pip install -U transformers accelerate # Load model directly from transformers import AutoProcessor, AutoModelForZeroShotImageClassification processor = AutoProcessor.from_pretrained("sgraham/met_model") model = AutoModelForZeroShotImageClassification.from_pretrained("sgraham/met_model", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Commit History
-
met images 30 epochs
{'loss': 0.4739, 'learning_rate': 2.0286396181384247e-05, 'epoch': 17.86} {'train_runtime': 4074.7723, 'train_samples_per_second': 10.19, 'train_steps_per_second': 0.206, 'train_loss': 0.3362658455258324, 'epoch': 30.0} 100% 840/840 [1:07:54<00:00, 4.85s/it] ***** train metrics ***** epoch = 30.0 train_loss = 0.3363 train_runtime = 1:07:54.77 train_samples_per_second = 10.19 train_steps_per_second = 0.206c95fe37 -
trained on 1371 images from the Met for 10 epochs
***** train metrics ***** epoch = 10.0 train_loss = 0.8552 train_runtime = 1:11:30.94 train_samples_per_second = 3.225 train_steps_per_second = 0.0332e27bbb