afern24 commited on
Commit
4df33d5
1 Parent(s): ffc2525

End of training

Browse files
Files changed (5) hide show
  1. README.md +84 -0
  2. config.json +34 -0
  3. preprocessor_config.json +22 -0
  4. pytorch_model.bin +3 -0
  5. training_args.bin +3 -0
README.md ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ base_model: google/vit-base-patch16-224-in21k
4
+ tags:
5
+ - generated_from_trainer
6
+ datasets:
7
+ - beans
8
+ metrics:
9
+ - accuracy
10
+ model-index:
11
+ - name: vit-finetuned-beans
12
+ results:
13
+ - task:
14
+ name: Image Classification
15
+ type: image-classification
16
+ dataset:
17
+ name: beans
18
+ type: beans
19
+ config: default
20
+ split: train
21
+ args: default
22
+ metrics:
23
+ - name: Accuracy
24
+ type: accuracy
25
+ value: 0.9711538461538461
26
+ ---
27
+
28
+ <!-- This model card has been generated automatically according to the information the Trainer had access to. You
29
+ should probably proofread and complete it, then remove this comment. -->
30
+
31
+ # vit-finetuned-beans
32
+
33
+ This model is a fine-tuned version of [google/vit-base-patch16-224-in21k](https://huggingface.co/google/vit-base-patch16-224-in21k) on the beans dataset.
34
+ It achieves the following results on the evaluation set:
35
+ - Loss: 0.1157
36
+ - Accuracy: 0.9712
37
+
38
+ ## Model description
39
+
40
+ More information needed
41
+
42
+ ## Intended uses & limitations
43
+
44
+ More information needed
45
+
46
+ ## Training and evaluation data
47
+
48
+ More information needed
49
+
50
+ ## Training procedure
51
+
52
+ ### Training hyperparameters
53
+
54
+ The following hyperparameters were used during training:
55
+ - learning_rate: 5e-05
56
+ - train_batch_size: 8
57
+ - eval_batch_size: 8
58
+ - seed: 42
59
+ - optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
60
+ - lr_scheduler_type: linear
61
+ - num_epochs: 10
62
+
63
+ ### Training results
64
+
65
+ | Training Loss | Epoch | Step | Validation Loss | Accuracy |
66
+ |:-------------:|:-----:|:----:|:---------------:|:--------:|
67
+ | 0.193 | 1.0 | 117 | 0.1099 | 0.9808 |
68
+ | 0.0462 | 2.0 | 234 | 0.0857 | 0.9808 |
69
+ | 0.0171 | 3.0 | 351 | 0.1237 | 0.9712 |
70
+ | 0.0123 | 4.0 | 468 | 0.1088 | 0.9712 |
71
+ | 0.0095 | 5.0 | 585 | 0.1135 | 0.9712 |
72
+ | 0.0081 | 6.0 | 702 | 0.1162 | 0.9712 |
73
+ | 0.0073 | 7.0 | 819 | 0.1158 | 0.9712 |
74
+ | 0.0066 | 8.0 | 936 | 0.1152 | 0.9712 |
75
+ | 0.0061 | 9.0 | 1053 | 0.1160 | 0.9712 |
76
+ | 0.0061 | 10.0 | 1170 | 0.1157 | 0.9712 |
77
+
78
+
79
+ ### Framework versions
80
+
81
+ - Transformers 4.33.2
82
+ - Pytorch 2.0.1+cu118
83
+ - Datasets 2.14.5
84
+ - Tokenizers 0.13.3
config.json ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "google/vit-base-patch16-224-in21k",
3
+ "architectures": [
4
+ "ViTForImageClassification"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.0,
7
+ "encoder_stride": 16,
8
+ "hidden_act": "gelu",
9
+ "hidden_dropout_prob": 0.0,
10
+ "hidden_size": 768,
11
+ "id2label": {
12
+ "0": "angular_leaf_spot",
13
+ "1": "bean_rust",
14
+ "2": "healthy"
15
+ },
16
+ "image_size": 224,
17
+ "initializer_range": 0.02,
18
+ "intermediate_size": 3072,
19
+ "label2id": {
20
+ "angular_leaf_spot": "0",
21
+ "bean_rust": "1",
22
+ "healthy": "2"
23
+ },
24
+ "layer_norm_eps": 1e-12,
25
+ "model_type": "vit",
26
+ "num_attention_heads": 12,
27
+ "num_channels": 3,
28
+ "num_hidden_layers": 12,
29
+ "patch_size": 16,
30
+ "problem_type": "single_label_classification",
31
+ "qkv_bias": true,
32
+ "torch_dtype": "float32",
33
+ "transformers_version": "4.33.2"
34
+ }
preprocessor_config.json ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "do_normalize": true,
3
+ "do_rescale": true,
4
+ "do_resize": true,
5
+ "image_mean": [
6
+ 0.5,
7
+ 0.5,
8
+ 0.5
9
+ ],
10
+ "image_processor_type": "ViTImageProcessor",
11
+ "image_std": [
12
+ 0.5,
13
+ 0.5,
14
+ 0.5
15
+ ],
16
+ "resample": 2,
17
+ "rescale_factor": 0.00392156862745098,
18
+ "size": {
19
+ "height": 224,
20
+ "width": 224
21
+ }
22
+ }
pytorch_model.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1092baaec4e0cff89b2cd153ac85a541d24496493e540161cbbb3020f97525cf
3
+ size 343271789
training_args.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a765710863fd6d31e4da6d95fb5c7fd99d2737cb6db1afbfaced51580c8cefba
3
+ size 4027