Instructions to use nqvii/deit_fold_2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use nqvii/deit_fold_2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="nqvii/deit_fold_2") 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/deit_fold_2") model = AutoModelForImageClassification.from_pretrained("nqvii/deit_fold_2", device_map="auto") - Notebooks
- Google Colab
- Kaggle
End of training Fold 2
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: facebook/deit-small-patch16-224
|
| 5 |
+
tags:
|
| 6 |
+
- generated_from_trainer
|
| 7 |
+
datasets:
|
| 8 |
+
- imagefolder
|
| 9 |
+
metrics:
|
| 10 |
+
- accuracy
|
| 11 |
+
- recall
|
| 12 |
+
model-index:
|
| 13 |
+
- name: deit_fold_2
|
| 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.9586206896551724
|
| 28 |
+
- name: Recall
|
| 29 |
+
type: recall
|
| 30 |
+
value: 0.9621148459383753
|
| 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 |
+
# deit_fold_2
|
| 37 |
+
|
| 38 |
+
This model is a fine-tuned version of [facebook/deit-small-patch16-224](https://huggingface.co/facebook/deit-small-patch16-224) on the imagefolder dataset.
|
| 39 |
+
It achieves the following results on the evaluation set:
|
| 40 |
+
- Loss: 1.1405
|
| 41 |
+
- Accuracy: 0.9586
|
| 42 |
+
- F1 Score: 0.9620
|
| 43 |
+
- Recall: 0.9621
|
| 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.8182 | 1.0 | 19 | 2.7982 | 0.2966 | 0.2243 | 0.2444 |
|
| 77 |
+
| 2.7152 | 2.0 | 38 | 2.6468 | 0.3793 | 0.2689 | 0.3032 |
|
| 78 |
+
| 2.5094 | 3.0 | 57 | 2.4150 | 0.5241 | 0.4335 | 0.4481 |
|
| 79 |
+
| 2.1993 | 4.0 | 76 | 2.0760 | 0.7172 | 0.7150 | 0.6964 |
|
| 80 |
+
| 1.7513 | 5.0 | 95 | 1.7070 | 0.8069 | 0.8177 | 0.8141 |
|
| 81 |
+
| 1.4469 | 6.0 | 114 | 1.4631 | 0.8586 | 0.8728 | 0.8742 |
|
| 82 |
+
| 1.2482 | 7.0 | 133 | 1.3515 | 0.8759 | 0.8882 | 0.8890 |
|
| 83 |
+
| 1.2058 | 8.0 | 152 | 1.3018 | 0.8897 | 0.8990 | 0.8998 |
|
| 84 |
+
| 1.1470 | 9.0 | 171 | 1.2735 | 0.9069 | 0.9141 | 0.9169 |
|
| 85 |
+
| 1.0887 | 10.0 | 190 | 1.2533 | 0.9207 | 0.9291 | 0.9306 |
|
| 86 |
+
| 1.0903 | 11.0 | 209 | 1.2413 | 0.9103 | 0.9182 | 0.9159 |
|
| 87 |
+
| 1.0576 | 12.0 | 228 | 1.2260 | 0.9207 | 0.9286 | 0.9317 |
|
| 88 |
+
| 1.0231 | 13.0 | 247 | 1.2594 | 0.9207 | 0.9278 | 0.9303 |
|
| 89 |
+
| 1.0264 | 14.0 | 266 | 1.2164 | 0.9276 | 0.9339 | 0.9305 |
|
| 90 |
+
| 1.0175 | 15.0 | 285 | 1.2294 | 0.9241 | 0.9301 | 0.9267 |
|
| 91 |
+
| 1.0135 | 16.0 | 304 | 1.2143 | 0.9345 | 0.9406 | 0.9402 |
|
| 92 |
+
| 1.0178 | 17.0 | 323 | 1.2314 | 0.9276 | 0.9351 | 0.9380 |
|
| 93 |
+
| 0.9823 | 18.0 | 342 | 1.2160 | 0.9310 | 0.9373 | 0.9365 |
|
| 94 |
+
| 0.9965 | 19.0 | 361 | 1.2154 | 0.9172 | 0.9232 | 0.9206 |
|
| 95 |
+
| 0.9854 | 20.0 | 380 | 1.1846 | 0.9345 | 0.9411 | 0.9415 |
|
| 96 |
+
| 0.9807 | 21.0 | 399 | 1.2096 | 0.9345 | 0.9414 | 0.9414 |
|
| 97 |
+
| 0.9860 | 22.0 | 418 | 1.1996 | 0.9276 | 0.9338 | 0.9316 |
|
| 98 |
+
| 0.9796 | 23.0 | 437 | 1.1967 | 0.9310 | 0.9365 | 0.9317 |
|
| 99 |
+
| 0.9826 | 24.0 | 456 | 1.2180 | 0.9172 | 0.9239 | 0.9183 |
|
| 100 |
+
| 0.9809 | 25.0 | 475 | 1.2030 | 0.9345 | 0.9405 | 0.9378 |
|
| 101 |
+
| 0.9803 | 26.0 | 494 | 1.1866 | 0.9345 | 0.9403 | 0.9389 |
|
| 102 |
+
| 0.9748 | 27.0 | 513 | 1.1626 | 0.9448 | 0.9497 | 0.9487 |
|
| 103 |
+
| 0.9659 | 28.0 | 532 | 1.1405 | 0.9586 | 0.9620 | 0.9621 |
|
| 104 |
+
| 0.9718 | 29.0 | 551 | 1.1410 | 0.9483 | 0.9525 | 0.9525 |
|
| 105 |
+
| 0.9668 | 30.0 | 570 | 1.1485 | 0.9552 | 0.9589 | 0.9584 |
|
| 106 |
+
| 0.9715 | 31.0 | 589 | 1.1423 | 0.9448 | 0.9499 | 0.9502 |
|
| 107 |
+
| 0.9729 | 32.0 | 608 | 1.1560 | 0.9483 | 0.9535 | 0.9550 |
|
| 108 |
+
| 0.9766 | 33.0 | 627 | 1.1721 | 0.9483 | 0.9541 | 0.9561 |
|
| 109 |
+
| 0.9687 | 34.0 | 646 | 1.1706 | 0.9448 | 0.9509 | 0.9524 |
|
| 110 |
+
| 0.9769 | 35.0 | 665 | 1.1539 | 0.9345 | 0.9410 | 0.9403 |
|
| 111 |
+
| 0.9609 | 36.0 | 684 | 1.1552 | 0.9483 | 0.9539 | 0.9549 |
|
| 112 |
+
| 0.9587 | 37.0 | 703 | 1.1565 | 0.9517 | 0.9569 | 0.9597 |
|
| 113 |
+
| 0.9673 | 38.0 | 722 | 1.1675 | 0.9483 | 0.9537 | 0.9562 |
|
| 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 86691704
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ac564e3712696430426411e8bf66b651126a7ee5b20120425140e36966356b58
|
| 3 |
size 86691704
|