
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
should probably proofread and complete it, then remove this comment. -->

# vit-4-veggies-2

This model is a fine-tuned version of [google/vit-base-patch16-224-in21k](https://huggingface.co/google/vit-base-patch16-224-in21k) on an unknown dataset.
It achieves the following results on the evaluation set:
- Loss: 0.0636
- Accuracy: 0.9870
- Precision: 0.9875
- Recall: 0.9870
- F1: 0.9870
- Confusion Matrix: [[62, 0, 4, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 410, 0, 0, 0, 0, 0, 0, 0], [0, 0, 3, 356, 0, 0, 0, 0, 0, 0], [0, 0, 0, 1, 123, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 9, 0, 1, 0, 0], [0, 0, 0, 0, 0, 0, 13, 1, 0, 1], [0, 0, 0, 0, 0, 1, 1, 11, 0, 1], [0, 0, 0, 0, 0, 2, 0, 0, 7, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 19]]
- Cohen Kappa: 0.9830
- Matthews Corrcoef: 0.9831

## 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: 5e-05
- train_batch_size: 32
- eval_batch_size: 16
- seed: 42
- optimizer: Use adamw_torch with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
- lr_scheduler_type: linear
- num_epochs: 8
- mixed_precision_training: Native AMP

### Training results

| Training Loss | Epoch  | Step | Validation Loss | Accuracy | Precision | Recall | F1     | Confusion Matrix                                                                                                                                                                                                                                                                                                                             | Cohen Kappa | Matthews Corrcoef |
|:-------------:|:------:|:----:|:---------------:|:--------:|:---------:|:------:|:------:|:--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------:|:-----------:|:-----------------:|
| 0.2225        | 0.6211 | 100  | 0.2418          | 0.9510   | 0.9485    | 0.9510 | 0.9472 | [[59, 0, 7, 0, 0, 0, 0, 0, 0, 0], [0, 276, 3, 0, 0, 0, 0, 0, 0, 0], [1, 0, 399, 8, 2, 0, 0, 0, 0, 0], [0, 0, 8, 345, 6, 0, 0, 0, 0, 0], [0, 0, 0, 0, 124, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 1, 6, 0, 3], [0, 0, 0, 0, 0, 0, 13, 0, 0, 2], [0, 0, 0, 0, 0, 0, 0, 3, 0, 11], [2, 0, 0, 0, 0, 0, 0, 2, 3, 2], [0, 0, 0, 0, 0, 0, 0, 0, 0, 20]] | 0.9362      | 0.9364            |
| 0.106         | 1.2422 | 200  | 0.1557          | 0.9694   | 0.9684    | 0.9694 | 0.9675 | [[60, 0, 6, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [2, 0, 406, 2, 0, 0, 0, 0, 0, 0], [0, 0, 7, 351, 1, 0, 0, 0, 0, 0], [0, 0, 1, 1, 122, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 1, 0, 6, 1, 2], [0, 0, 0, 0, 0, 0, 14, 0, 0, 1], [0, 0, 0, 0, 0, 0, 0, 8, 2, 4], [1, 0, 0, 0, 0, 1, 0, 1, 6, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 19]]  | 0.9601      | 0.9602            |
| 0.1198        | 1.8634 | 300  | 0.1496          | 0.9640   | 0.9679    | 0.9640 | 0.9624 | [[60, 0, 6, 0, 0, 0, 0, 0, 0, 0], [0, 266, 13, 0, 0, 0, 0, 0, 0, 0], [0, 0, 406, 4, 0, 0, 0, 0, 0, 0], [0, 0, 7, 352, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 124, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 1, 0, 8, 0, 1], [0, 0, 0, 0, 0, 0, 14, 0, 0, 1], [0, 0, 0, 0, 0, 0, 1, 9, 0, 4], [0, 0, 0, 0, 0, 0, 0, 1, 8, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 19]] | 0.9530      | 0.9533            |
| 0.0901        | 2.4845 | 400  | 0.1208          | 0.9686   | 0.9709    | 0.9686 | 0.9665 | [[63, 0, 3, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [8, 1, 401, 0, 0, 0, 0, 0, 0, 0], [0, 0, 11, 348, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 121, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 1, 1, 6, 0, 2], [0, 0, 0, 0, 0, 0, 14, 0, 0, 1], [0, 0, 0, 0, 0, 0, 1, 9, 0, 4], [0, 0, 0, 0, 0, 0, 0, 0, 9, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 20]] | 0.9591      | 0.9592            |
| 0.0133        | 3.1056 | 500  | 0.0862          | 0.9801   | 0.9820    | 0.9801 | 0.9797 | [[61, 0, 5, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [0, 1, 408, 1, 0, 0, 0, 0, 0, 0], [0, 0, 4, 355, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 121, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 4, 0, 6, 0, 0], [0, 0, 0, 0, 0, 0, 14, 0, 0, 1], [0, 0, 0, 0, 0, 0, 1, 11, 0, 2], [0, 0, 0, 0, 0, 0, 0, 1, 8, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 19]] | 0.9740      | 0.9741            |
| 0.0078        | 3.7267 | 600  | 0.0498          | 0.9908   | 0.9915    | 0.9908 | 0.9906 | [[63, 0, 3, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 410, 0, 0, 0, 0, 0, 0, 0], [0, 0, 3, 356, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 124, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 6, 0, 4, 0, 0], [0, 0, 0, 0, 0, 0, 14, 0, 0, 1], [0, 0, 0, 0, 0, 0, 1, 13, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 9, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 20]] | 0.9880      | 0.9881            |
| 0.0045        | 4.3478 | 700  | 0.0532          | 0.9877   | 0.9879    | 0.9877 | 0.9877 | [[62, 0, 4, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 409, 1, 0, 0, 0, 0, 0, 0], [0, 0, 2, 357, 0, 0, 0, 0, 0, 0], [0, 0, 0, 2, 122, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 9, 0, 1, 0, 0], [0, 0, 0, 0, 0, 0, 14, 0, 0, 1], [0, 0, 0, 0, 0, 1, 1, 11, 0, 1], [0, 0, 0, 0, 0, 1, 0, 0, 8, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 19]] | 0.9840      | 0.9840            |
| 0.0039        | 4.9689 | 800  | 0.0547          | 0.9877   | 0.9885    | 0.9877 | 0.9878 | [[63, 0, 3, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 410, 0, 0, 0, 0, 0, 0, 0], [0, 0, 3, 356, 0, 0, 0, 0, 0, 0], [0, 0, 0, 1, 123, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 9, 0, 1, 0, 0], [0, 0, 0, 0, 0, 0, 13, 0, 0, 2], [0, 0, 0, 0, 0, 1, 0, 11, 0, 2], [0, 0, 0, 0, 0, 2, 0, 0, 7, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 19]] | 0.9840      | 0.9841            |
| 0.0032        | 5.5901 | 900  | 0.0767          | 0.9862   | 0.9868    | 0.9862 | 0.9862 | [[61, 0, 5, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 408, 2, 0, 0, 0, 0, 0, 0], [0, 0, 2, 357, 0, 0, 0, 0, 0, 0], [0, 0, 0, 1, 123, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 9, 0, 1, 0, 0], [0, 0, 0, 0, 0, 0, 13, 1, 0, 1], [0, 0, 0, 0, 0, 1, 1, 12, 0, 0], [0, 0, 0, 0, 0, 2, 0, 0, 7, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 19]] | 0.9820      | 0.9821            |
| 0.0021        | 6.2112 | 1000 | 0.0678          | 0.9862   | 0.9867    | 0.9862 | 0.9862 | [[62, 0, 4, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 409, 1, 0, 0, 0, 0, 0, 0], [0, 0, 3, 356, 0, 0, 0, 0, 0, 0], [0, 0, 0, 1, 123, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 9, 0, 1, 0, 0], [0, 0, 0, 0, 0, 0, 13, 1, 0, 1], [0, 0, 0, 0, 0, 1, 1, 11, 0, 1], [0, 0, 0, 0, 0, 2, 0, 0, 7, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 19]] | 0.9820      | 0.9821            |
| 0.0017        | 6.8323 | 1100 | 0.0617          | 0.9877   | 0.9882    | 0.9877 | 0.9877 | [[62, 0, 4, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 410, 0, 0, 0, 0, 0, 0, 0], [0, 0, 2, 357, 0, 0, 0, 0, 0, 0], [0, 0, 0, 1, 123, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 9, 0, 1, 0, 0], [0, 0, 0, 0, 0, 0, 13, 1, 0, 1], [0, 0, 0, 0, 0, 1, 1, 11, 0, 1], [0, 0, 0, 0, 0, 2, 0, 0, 7, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 19]] | 0.9840      | 0.9841            |
| 0.0012        | 7.4534 | 1200 | 0.0636          | 0.9870   | 0.9875    | 0.9870 | 0.9870 | [[62, 0, 4, 0, 0, 0, 0, 0, 0, 0], [0, 279, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 410, 0, 0, 0, 0, 0, 0, 0], [0, 0, 3, 356, 0, 0, 0, 0, 0, 0], [0, 0, 0, 1, 123, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 9, 0, 1, 0, 0], [0, 0, 0, 0, 0, 0, 13, 1, 0, 1], [0, 0, 0, 0, 0, 1, 1, 11, 0, 1], [0, 0, 0, 0, 0, 2, 0, 0, 7, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 19]] | 0.9830      | 0.9831            |


### Framework versions

- Transformers 4.47.0
- Pytorch 2.5.1+cu121
- Datasets 3.3.1
- Tokenizers 0.21.0

damaged dried old ripe unripe diseased flower ripe rotten unripe