
<!-- 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-base-oxford-iiit-pets

This model is a fine-tuned version of [google/vit-base-patch16-224](https://huggingface.co/google/vit-base-patch16-224) on the pcuenq/oxford-pets dataset.
It achieves the following results on the evaluation set:
- Loss: 0.1782
- Accuracy: 0.9513

## 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: 0.0003
- train_batch_size: 16
- eval_batch_size: 8
- seed: 42
- optimizer: Use OptimizerNames.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: 5

### Training results

| Training Loss | Epoch | Step | Validation Loss | Accuracy |
|:-------------:|:-----:|:----:|:---------------:|:--------:|
| 0.3652        | 1.0   | 370  | 0.2811          | 0.9269   |
| 0.2181        | 2.0   | 740  | 0.2083          | 0.9378   |
| 0.1688        | 3.0   | 1110 | 0.1952          | 0.9364   |
| 0.1353        | 4.0   | 1480 | 0.1847          | 0.9405   |
| 0.1506        | 5.0   | 1850 | 0.1849          | 0.9350   |


### Framework versions

- Transformers 4.50.0
- Pytorch 2.6.0+cu124
- Datasets 3.4.1
- Tokenizers 0.21.1


### Zero-Shot Evaluation

- Model used: ⁠ openai/clip-vit-large-patch14 ⁠
- Dataset: Oxford-IIIT-Pets (⁠ pcuenq/oxford-pets ⁠)
- ⁠Accuracy: 0.8785
- ⁠Precision: 0.8761
- ⁠Recall: 0.8785

The zero-shot evaluation was done using Hugging Face Transformers and the CLIP model on the Oxford-Pet dataset.

19 29 0 11 1 86 90 28 23 31 39 96 82 17 71 8 97 80 74 59 70 87 84 64 52 42 47 65 21 22 81 24 78 45 49 56 76 89 73 14 9 6 20 98 36 55 72 43 51 35 83 33 27 53 92 50 15 18 46 75 38 66 77 69 95 99 93 4 61 94 68 34 32 88 67 30 62 63 40 26 48 79 85 54 44 7 12 2 41 37 13 25 10 57 5 60 91 3 58 16