Instructions to use nqvii/vit_fold_1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use nqvii/vit_fold_1 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="nqvii/vit_fold_1") 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/vit_fold_1") model = AutoModelForImageClassification.from_pretrained("nqvii/vit_fold_1", device_map="auto") - Notebooks
- Google Colab
- Kaggle
End of training Fold 1
Browse files- README.md +121 -0
- model.safetensors +1 -1
README.md
ADDED
|
@@ -0,0 +1,121 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
library_name: transformers
|
| 3 |
+
license: apache-2.0
|
| 4 |
+
base_model: google/vit-base-patch16-224
|
| 5 |
+
tags:
|
| 6 |
+
- generated_from_trainer
|
| 7 |
+
datasets:
|
| 8 |
+
- imagefolder
|
| 9 |
+
metrics:
|
| 10 |
+
- accuracy
|
| 11 |
+
- recall
|
| 12 |
+
model-index:
|
| 13 |
+
- name: vit_fold_1
|
| 14 |
+
results:
|
| 15 |
+
- task:
|
| 16 |
+
name: Image Classification
|
| 17 |
+
type: image-classification
|
| 18 |
+
dataset:
|
| 19 |
+
name: imagefolder
|
| 20 |
+
type: imagefolder
|
| 21 |
+
config: default
|
| 22 |
+
split: None
|
| 23 |
+
args: default
|
| 24 |
+
metrics:
|
| 25 |
+
- name: Accuracy
|
| 26 |
+
type: accuracy
|
| 27 |
+
value: 0.9689655172413794
|
| 28 |
+
- name: Recall
|
| 29 |
+
type: recall
|
| 30 |
+
value: 0.9693627450980392
|
| 31 |
+
---
|
| 32 |
+
|
| 33 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
| 34 |
+
should probably proofread and complete it, then remove this comment. -->
|
| 35 |
+
|
| 36 |
+
# vit_fold_1
|
| 37 |
+
|
| 38 |
+
This model is a fine-tuned version of [google/vit-base-patch16-224](https://huggingface.co/google/vit-base-patch16-224) on the imagefolder dataset.
|
| 39 |
+
It achieves the following results on the evaluation set:
|
| 40 |
+
- Loss: 1.0952
|
| 41 |
+
- Accuracy: 0.9690
|
| 42 |
+
- F1 Score: 0.9709
|
| 43 |
+
- Recall: 0.9694
|
| 44 |
+
|
| 45 |
+
## Model description
|
| 46 |
+
|
| 47 |
+
More information needed
|
| 48 |
+
|
| 49 |
+
## Intended uses & limitations
|
| 50 |
+
|
| 51 |
+
More information needed
|
| 52 |
+
|
| 53 |
+
## Training and evaluation data
|
| 54 |
+
|
| 55 |
+
More information needed
|
| 56 |
+
|
| 57 |
+
## Training procedure
|
| 58 |
+
|
| 59 |
+
### Training hyperparameters
|
| 60 |
+
|
| 61 |
+
The following hyperparameters were used during training:
|
| 62 |
+
- learning_rate: 1e-05
|
| 63 |
+
- train_batch_size: 64
|
| 64 |
+
- eval_batch_size: 64
|
| 65 |
+
- seed: 42
|
| 66 |
+
- optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
|
| 67 |
+
- lr_scheduler_type: cosine
|
| 68 |
+
- lr_scheduler_warmup_steps: 150
|
| 69 |
+
- num_epochs: 100
|
| 70 |
+
- label_smoothing_factor: 0.15
|
| 71 |
+
|
| 72 |
+
### Training results
|
| 73 |
+
|
| 74 |
+
| Training Loss | Epoch | Step | Validation Loss | Accuracy | F1 Score | Recall |
|
| 75 |
+
|:-------------:|:-----:|:----:|:---------------:|:--------:|:--------:|:------:|
|
| 76 |
+
| 2.9282 | 1.0 | 19 | 2.7689 | 0.3310 | 0.2729 | 0.2884 |
|
| 77 |
+
| 2.7470 | 2.0 | 38 | 2.5989 | 0.4448 | 0.3540 | 0.3755 |
|
| 78 |
+
| 2.4449 | 3.0 | 57 | 2.3265 | 0.5931 | 0.5856 | 0.5613 |
|
| 79 |
+
| 2.0224 | 4.0 | 76 | 2.0013 | 0.7379 | 0.7505 | 0.7314 |
|
| 80 |
+
| 1.6546 | 5.0 | 95 | 1.6556 | 0.8276 | 0.8368 | 0.8288 |
|
| 81 |
+
| 1.3650 | 6.0 | 114 | 1.3947 | 0.9 | 0.9044 | 0.9030 |
|
| 82 |
+
| 1.1791 | 7.0 | 133 | 1.2692 | 0.9207 | 0.9228 | 0.9237 |
|
| 83 |
+
| 1.1519 | 8.0 | 152 | 1.2026 | 0.9414 | 0.9428 | 0.9398 |
|
| 84 |
+
| 1.1252 | 9.0 | 171 | 1.1660 | 0.9448 | 0.9465 | 0.9448 |
|
| 85 |
+
| 1.0789 | 10.0 | 190 | 1.1463 | 0.9483 | 0.9501 | 0.9497 |
|
| 86 |
+
| 1.0771 | 11.0 | 209 | 1.1329 | 0.9517 | 0.9533 | 0.9509 |
|
| 87 |
+
| 1.0519 | 12.0 | 228 | 1.1264 | 0.9552 | 0.9569 | 0.9533 |
|
| 88 |
+
| 1.0340 | 13.0 | 247 | 1.1138 | 0.9586 | 0.9610 | 0.9619 |
|
| 89 |
+
| 1.0224 | 14.0 | 266 | 1.1073 | 0.9655 | 0.9666 | 0.9644 |
|
| 90 |
+
| 0.9936 | 15.0 | 285 | 1.1274 | 0.9586 | 0.9593 | 0.9558 |
|
| 91 |
+
| 0.9975 | 16.0 | 304 | 1.1038 | 0.9655 | 0.9666 | 0.9644 |
|
| 92 |
+
| 0.9908 | 17.0 | 323 | 1.1107 | 0.9621 | 0.9631 | 0.9595 |
|
| 93 |
+
| 0.9870 | 18.0 | 342 | 1.1084 | 0.9655 | 0.9663 | 0.9631 |
|
| 94 |
+
| 0.9862 | 19.0 | 361 | 1.1079 | 0.9655 | 0.9663 | 0.9631 |
|
| 95 |
+
| 0.9739 | 20.0 | 380 | 1.0912 | 0.9655 | 0.9666 | 0.9644 |
|
| 96 |
+
| 0.9810 | 21.0 | 399 | 1.0898 | 0.9690 | 0.9698 | 0.9680 |
|
| 97 |
+
| 0.9865 | 22.0 | 418 | 1.0878 | 0.9655 | 0.9668 | 0.9656 |
|
| 98 |
+
| 0.9694 | 23.0 | 437 | 1.0842 | 0.9655 | 0.9668 | 0.9656 |
|
| 99 |
+
| 0.9649 | 24.0 | 456 | 1.0958 | 0.9655 | 0.9666 | 0.9644 |
|
| 100 |
+
| 0.9710 | 25.0 | 475 | 1.0934 | 0.9690 | 0.9698 | 0.9680 |
|
| 101 |
+
| 0.9672 | 26.0 | 494 | 1.0923 | 0.9655 | 0.9666 | 0.9644 |
|
| 102 |
+
| 0.9653 | 27.0 | 513 | 1.0932 | 0.9690 | 0.9698 | 0.9680 |
|
| 103 |
+
| 0.9622 | 28.0 | 532 | 1.0820 | 0.9655 | 0.9669 | 0.9668 |
|
| 104 |
+
| 0.9677 | 29.0 | 551 | 1.0928 | 0.9655 | 0.9666 | 0.9644 |
|
| 105 |
+
| 0.9639 | 30.0 | 570 | 1.0834 | 0.9655 | 0.9666 | 0.9644 |
|
| 106 |
+
| 0.9671 | 31.0 | 589 | 1.0952 | 0.9690 | 0.9709 | 0.9694 |
|
| 107 |
+
| 0.9635 | 32.0 | 608 | 1.0909 | 0.9655 | 0.9682 | 0.9694 |
|
| 108 |
+
| 0.9710 | 33.0 | 627 | 1.0919 | 0.9690 | 0.9709 | 0.9694 |
|
| 109 |
+
| 0.9614 | 34.0 | 646 | 1.0951 | 0.9655 | 0.9682 | 0.9694 |
|
| 110 |
+
| 0.9637 | 35.0 | 665 | 1.0940 | 0.9690 | 0.9709 | 0.9694 |
|
| 111 |
+
| 0.9618 | 36.0 | 684 | 1.0847 | 0.9690 | 0.9700 | 0.9693 |
|
| 112 |
+
| 0.9578 | 37.0 | 703 | 1.0871 | 0.9655 | 0.9668 | 0.9656 |
|
| 113 |
+
| 0.9646 | 38.0 | 722 | 1.0910 | 0.9655 | 0.9671 | 0.9680 |
|
| 114 |
+
|
| 115 |
+
|
| 116 |
+
### Framework versions
|
| 117 |
+
|
| 118 |
+
- Transformers 5.0.0
|
| 119 |
+
- Pytorch 2.10.0+cu128
|
| 120 |
+
- Datasets 5.0.0
|
| 121 |
+
- Tokenizers 0.22.2
|
model.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 343230128
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ba525488e22687cc26756c7f9192c187fc416f24c53bfd2e7d349315b7a804a4
|
| 3 |
size 343230128
|