AI-Lab-Makerere/beans
Viewer • Updated • 1.3k • 9.44k • 46
How to use juniorjukeko/img_class_beans with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("image-classification", model="juniorjukeko/img_class_beans")
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("juniorjukeko/img_class_beans")
model = AutoModelForImageClassification.from_pretrained("juniorjukeko/img_class_beans")# Load model directly
from transformers import AutoImageProcessor, AutoModelForImageClassification
processor = AutoImageProcessor.from_pretrained("juniorjukeko/img_class_beans")
model = AutoModelForImageClassification.from_pretrained("juniorjukeko/img_class_beans")This model is a fine-tuned version of juniorjukeko/img_class_beans on the beans 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.1122 | 0.98 | 12 | 0.1660 | 0.9575 |
| 0.1356 | 1.96 | 24 | 0.1977 | 0.9421 |
| 0.0889 | 2.94 | 36 | 0.1504 | 0.9421 |
| 0.0793 | 4.0 | 49 | 0.1477 | 0.9575 |
| 0.0578 | 4.98 | 61 | 0.1320 | 0.9653 |
| 0.0514 | 5.96 | 73 | 0.1163 | 0.9730 |
| 0.0592 | 6.94 | 85 | 0.1363 | 0.9653 |
| 0.0532 | 8.0 | 98 | 0.1837 | 0.9382 |
| 0.0555 | 8.98 | 110 | 0.1400 | 0.9614 |
| 0.0723 | 9.8 | 120 | 0.1220 | 0.9730 |
Unable to build the model tree, the base model loops to the model itself. Learn more.
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="juniorjukeko/img_class_beans") pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png")