lewtun/dog_food
Viewer β’ Updated β’ 3k β’ 69 β’ 5
How to use douwekiela/resnet-18-finetuned-dogfood with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("image-classification", model="douwekiela/resnet-18-finetuned-dogfood")
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("douwekiela/resnet-18-finetuned-dogfood")
model = AutoModelForImageClassification.from_pretrained("douwekiela/resnet-18-finetuned-dogfood", device_map="auto")# Load model directly
from transformers import AutoImageProcessor, AutoModelForImageClassification
processor = AutoImageProcessor.from_pretrained("douwekiela/resnet-18-finetuned-dogfood")
model = AutoModelForImageClassification.from_pretrained("douwekiela/resnet-18-finetuned-dogfood", device_map="auto")This model is a fine-tuned version of microsoft/resnet-18 on the lewtun/dog_food dataset. It achieves the following results on the evaluation set:
More information needed
More information needed
More information needed
The following hyperparameters were used during training:
| Training Loss | Epoch | Step | Validation Loss | Accuracy |
|---|---|---|---|---|
| 0.846 | 1.0 | 16 | 0.2662 | 0.9156 |
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="douwekiela/resnet-18-finetuned-dogfood") pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png")