Image Classification
Transformers
Safetensors
swin
vision
swin-transformer
rice-disease
Generated from Trainer
Eval Results (legacy)
Instructions to use nqvii/swin-tiny-rice-disease with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use nqvii/swin-tiny-rice-disease with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="nqvii/swin-tiny-rice-disease") 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("nqvii/swin-tiny-rice-disease") model = AutoModelForImageClassification.from_pretrained("nqvii/swin-tiny-rice-disease", device_map="auto") - Notebooks
- Google Colab
- Kaggle
swin-tiny-rice-disease
This model is a fine-tuned version of microsoft/swin-tiny-patch4-window7-224 on the rice_disease_701515 dataset. It achieves the following results on the evaluation set:
- Accuracy: 0.8771
- F1 Score: 0.8783
- Loss: 0.8022
- Recall: 0.8774
Model description
More information needed
Intended uses & limitations
More information needed
Training and evaluation data
More information needed
Training procedure
Training hyperparameters
The following hyperparameters were used during training:
- learning_rate: 2e-05
- train_batch_size: 32
- eval_batch_size: 32
- seed: 42
- optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
- lr_scheduler_type: cosine
- lr_scheduler_warmup_steps: 0.1
- num_epochs: 35
Training results
| Training Loss | Epoch | Step | Accuracy | F1 Score | Validation Loss | Recall |
|---|---|---|---|---|---|---|
| 2.6015 | 1.0 | 31 | 0.4019 | 0.3953 | 2.5301 | 0.3990 |
| 2.0857 | 2.0 | 62 | 0.6383 | 0.6408 | 1.8060 | 0.6379 |
| 1.5981 | 3.0 | 93 | 0.7234 | 0.7269 | 1.4075 | 0.7226 |
| 1.4038 | 4.0 | 124 | 0.8014 | 0.8005 | 1.0924 | 0.8016 |
| 1.3016 | 5.0 | 155 | 0.7730 | 0.7755 | 1.0891 | 0.7740 |
| 1.1921 | 6.0 | 186 | 0.7801 | 0.7821 | 1.1443 | 0.7797 |
| 1.0699 | 7.0 | 217 | 0.8345 | 0.8345 | 0.8551 | 0.8350 |
| 1.0590 | 8.0 | 248 | 0.8298 | 0.8300 | 0.9121 | 0.8296 |
| 0.9309 | 9.0 | 279 | 0.8558 | 0.8541 | 0.8474 | 0.8558 |
| 1.1103 | 10.0 | 310 | 0.8369 | 0.8364 | 0.8958 | 0.8366 |
| 0.8052 | 11.0 | 341 | 0.8723 | 0.8714 | 0.8341 | 0.8731 |
| 0.8316 | 12.0 | 372 | 0.8605 | 0.8595 | 0.8205 | 0.8611 |
| 0.7925 | 13.0 | 403 | 0.8652 | 0.8642 | 0.8144 | 0.8653 |
| 0.7598 | 14.0 | 434 | 0.8842 | 0.8840 | 0.7775 | 0.8840 |
| 0.7854 | 15.0 | 465 | 0.8936 | 0.8941 | 0.6830 | 0.8938 |
| 0.6274 | 16.0 | 496 | 0.8842 | 0.8845 | 0.7228 | 0.8838 |
| 0.7235 | 17.0 | 527 | 0.8794 | 0.8785 | 0.8013 | 0.8793 |
| 0.6191 | 18.0 | 558 | 0.8652 | 0.8657 | 0.8238 | 0.8657 |
| 0.6272 | 19.0 | 589 | 0.8794 | 0.8799 | 0.7262 | 0.8798 |
| 0.5298 | 20.0 | 620 | 0.8652 | 0.8647 | 0.8447 | 0.8653 |
| 0.5665 | 21.0 | 651 | 0.8747 | 0.8741 | 0.8196 | 0.8750 |
| 0.5508 | 22.0 | 682 | 0.8842 | 0.8834 | 0.7673 | 0.8848 |
| 0.5440 | 23.0 | 713 | 0.8629 | 0.8638 | 0.8191 | 0.8635 |
| 0.6131 | 24.0 | 744 | 0.8676 | 0.8672 | 0.8758 | 0.8674 |
| 0.4691 | 25.0 | 775 | 0.8652 | 0.8659 | 0.8382 | 0.8659 |
| 0.4537 | 26.0 | 806 | 0.8700 | 0.8715 | 0.8270 | 0.8704 |
| 0.6059 | 27.0 | 837 | 0.8771 | 0.8783 | 0.8022 | 0.8774 |
Framework versions
- Transformers 5.0.0
- Pytorch 2.10.0+cu128
- Datasets 5.0.0
- Tokenizers 0.22.2
- Downloads last month
- 16,223
Model tree for nqvii/swin-tiny-rice-disease
Base model
microsoft/swin-tiny-patch4-window7-224Evaluation results
- Accuracy on rice_disease_701515validation set self-reported0.877
- Recall on rice_disease_701515validation set self-reported0.877