sweetzinc commited on
Commit
4362372
1 Parent(s): f40fd78

End of training

Browse files
README.md ADDED
@@ -0,0 +1,78 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ base_model: microsoft/swin-tiny-patch4-window7-224
4
+ tags:
5
+ - generated_from_trainer
6
+ datasets:
7
+ - imagefolder
8
+ metrics:
9
+ - accuracy
10
+ model-index:
11
+ - name: swin-tiny-patch4-window7-224-finetuned-eurosat
12
+ results:
13
+ - task:
14
+ name: Image Classification
15
+ type: image-classification
16
+ dataset:
17
+ name: imagefolder
18
+ type: imagefolder
19
+ config: default
20
+ split: train
21
+ args: default
22
+ metrics:
23
+ - name: Accuracy
24
+ type: accuracy
25
+ value: 0.9640740740740741
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
+ # swin-tiny-patch4-window7-224-finetuned-eurosat
32
+
33
+ This model is a fine-tuned version of [microsoft/swin-tiny-patch4-window7-224](https://huggingface.co/microsoft/swin-tiny-patch4-window7-224) on the imagefolder dataset.
34
+ It achieves the following results on the evaluation set:
35
+ - Loss: 0.1113
36
+ - Accuracy: 0.9641
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: 32
57
+ - eval_batch_size: 32
58
+ - seed: 42
59
+ - gradient_accumulation_steps: 4
60
+ - total_train_batch_size: 128
61
+ - optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
62
+ - lr_scheduler_type: linear
63
+ - lr_scheduler_warmup_ratio: 0.1
64
+ - num_epochs: 1
65
+
66
+ ### Training results
67
+
68
+ | Training Loss | Epoch | Step | Validation Loss | Accuracy |
69
+ |:-------------:|:-----:|:----:|:---------------:|:--------:|
70
+ | 0.1937 | 1.0 | 190 | 0.1113 | 0.9641 |
71
+
72
+
73
+ ### Framework versions
74
+
75
+ - Transformers 4.34.0
76
+ - Pytorch 2.1.0+cpu
77
+ - Datasets 2.14.5
78
+ - Tokenizers 0.14.1
all_results.json ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "epoch": 1.0,
3
+ "eval_accuracy": 0.9640740740740741,
4
+ "eval_loss": 0.11127929389476776,
5
+ "eval_runtime": 158.3111,
6
+ "eval_samples_per_second": 17.055,
7
+ "eval_steps_per_second": 0.537,
8
+ "total_flos": 6.041355501920256e+17,
9
+ "train_loss": 0.5059562551347833,
10
+ "train_runtime": 4360.0692,
11
+ "train_samples_per_second": 5.573,
12
+ "train_steps_per_second": 0.044
13
+ }
config.json ADDED
@@ -0,0 +1,77 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "microsoft/swin-tiny-patch4-window7-224",
3
+ "architectures": [
4
+ "SwinForImageClassification"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.0,
7
+ "depths": [
8
+ 2,
9
+ 2,
10
+ 6,
11
+ 2
12
+ ],
13
+ "drop_path_rate": 0.1,
14
+ "embed_dim": 96,
15
+ "encoder_stride": 32,
16
+ "hidden_act": "gelu",
17
+ "hidden_dropout_prob": 0.0,
18
+ "hidden_size": 768,
19
+ "id2label": {
20
+ "0": "AnnualCrop",
21
+ "1": "Forest",
22
+ "2": "HerbaceousVegetation",
23
+ "3": "Highway",
24
+ "4": "Industrial",
25
+ "5": "Pasture",
26
+ "6": "PermanentCrop",
27
+ "7": "Residential",
28
+ "8": "River",
29
+ "9": "SeaLake"
30
+ },
31
+ "image_size": 224,
32
+ "initializer_range": 0.02,
33
+ "label2id": {
34
+ "AnnualCrop": 0,
35
+ "Forest": 1,
36
+ "HerbaceousVegetation": 2,
37
+ "Highway": 3,
38
+ "Industrial": 4,
39
+ "Pasture": 5,
40
+ "PermanentCrop": 6,
41
+ "Residential": 7,
42
+ "River": 8,
43
+ "SeaLake": 9
44
+ },
45
+ "layer_norm_eps": 1e-05,
46
+ "mlp_ratio": 4.0,
47
+ "model_type": "swin",
48
+ "num_channels": 3,
49
+ "num_heads": [
50
+ 3,
51
+ 6,
52
+ 12,
53
+ 24
54
+ ],
55
+ "num_layers": 4,
56
+ "out_features": [
57
+ "stage4"
58
+ ],
59
+ "out_indices": [
60
+ 4
61
+ ],
62
+ "patch_size": 4,
63
+ "path_norm": true,
64
+ "problem_type": "single_label_classification",
65
+ "qkv_bias": true,
66
+ "stage_names": [
67
+ "stem",
68
+ "stage1",
69
+ "stage2",
70
+ "stage3",
71
+ "stage4"
72
+ ],
73
+ "torch_dtype": "float32",
74
+ "transformers_version": "4.34.0",
75
+ "use_absolute_embeddings": false,
76
+ "window_size": 7
77
+ }
eval_results.json ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "epoch": 1.0,
3
+ "eval_accuracy": 0.9640740740740741,
4
+ "eval_loss": 0.11127929389476776,
5
+ "eval_runtime": 158.3111,
6
+ "eval_samples_per_second": 17.055,
7
+ "eval_steps_per_second": 0.537
8
+ }
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.485,
7
+ 0.456,
8
+ 0.406
9
+ ],
10
+ "image_processor_type": "ViTImageProcessor",
11
+ "image_std": [
12
+ 0.229,
13
+ 0.224,
14
+ 0.225
15
+ ],
16
+ "resample": 3,
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:7bd5831d9a69fc5143f6a71d0eb6fdb3cf6e2b0917168d138b58cd0a07433350
3
+ size 110416622
train_results.json ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "epoch": 1.0,
3
+ "total_flos": 6.041355501920256e+17,
4
+ "train_loss": 0.5059562551347833,
5
+ "train_runtime": 4360.0692,
6
+ "train_samples_per_second": 5.573,
7
+ "train_steps_per_second": 0.044
8
+ }
trainer_state.json ADDED
@@ -0,0 +1,151 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "best_metric": 0.9640740740740741,
3
+ "best_model_checkpoint": "swin-tiny-patch4-window7-224-finetuned-eurosat\\checkpoint-190",
4
+ "epoch": 1.0,
5
+ "eval_steps": 500,
6
+ "global_step": 190,
7
+ "is_hyper_param_search": false,
8
+ "is_local_process_zero": true,
9
+ "is_world_process_zero": true,
10
+ "log_history": [
11
+ {
12
+ "epoch": 0.05,
13
+ "learning_rate": 2.6315789473684212e-05,
14
+ "loss": 2.2236,
15
+ "step": 10
16
+ },
17
+ {
18
+ "epoch": 0.11,
19
+ "learning_rate": 4.970760233918128e-05,
20
+ "loss": 1.64,
21
+ "step": 20
22
+ },
23
+ {
24
+ "epoch": 0.16,
25
+ "learning_rate": 4.678362573099415e-05,
26
+ "loss": 0.8419,
27
+ "step": 30
28
+ },
29
+ {
30
+ "epoch": 0.21,
31
+ "learning_rate": 4.3859649122807014e-05,
32
+ "loss": 0.5429,
33
+ "step": 40
34
+ },
35
+ {
36
+ "epoch": 0.26,
37
+ "learning_rate": 4.093567251461988e-05,
38
+ "loss": 0.4881,
39
+ "step": 50
40
+ },
41
+ {
42
+ "epoch": 0.32,
43
+ "learning_rate": 3.8011695906432746e-05,
44
+ "loss": 0.3791,
45
+ "step": 60
46
+ },
47
+ {
48
+ "epoch": 0.37,
49
+ "learning_rate": 3.508771929824561e-05,
50
+ "loss": 0.3957,
51
+ "step": 70
52
+ },
53
+ {
54
+ "epoch": 0.42,
55
+ "learning_rate": 3.216374269005848e-05,
56
+ "loss": 0.2958,
57
+ "step": 80
58
+ },
59
+ {
60
+ "epoch": 0.47,
61
+ "learning_rate": 2.9239766081871346e-05,
62
+ "loss": 0.3197,
63
+ "step": 90
64
+ },
65
+ {
66
+ "epoch": 0.53,
67
+ "learning_rate": 2.6315789473684212e-05,
68
+ "loss": 0.2751,
69
+ "step": 100
70
+ },
71
+ {
72
+ "epoch": 0.58,
73
+ "learning_rate": 2.3391812865497074e-05,
74
+ "loss": 0.2478,
75
+ "step": 110
76
+ },
77
+ {
78
+ "epoch": 0.63,
79
+ "learning_rate": 2.046783625730994e-05,
80
+ "loss": 0.3039,
81
+ "step": 120
82
+ },
83
+ {
84
+ "epoch": 0.68,
85
+ "learning_rate": 1.7543859649122806e-05,
86
+ "loss": 0.2681,
87
+ "step": 130
88
+ },
89
+ {
90
+ "epoch": 0.74,
91
+ "learning_rate": 1.4619883040935673e-05,
92
+ "loss": 0.2758,
93
+ "step": 140
94
+ },
95
+ {
96
+ "epoch": 0.79,
97
+ "learning_rate": 1.1695906432748537e-05,
98
+ "loss": 0.2627,
99
+ "step": 150
100
+ },
101
+ {
102
+ "epoch": 0.84,
103
+ "learning_rate": 8.771929824561403e-06,
104
+ "loss": 0.2245,
105
+ "step": 160
106
+ },
107
+ {
108
+ "epoch": 0.89,
109
+ "learning_rate": 5.8479532163742686e-06,
110
+ "loss": 0.2252,
111
+ "step": 170
112
+ },
113
+ {
114
+ "epoch": 0.95,
115
+ "learning_rate": 2.9239766081871343e-06,
116
+ "loss": 0.2097,
117
+ "step": 180
118
+ },
119
+ {
120
+ "epoch": 1.0,
121
+ "learning_rate": 0.0,
122
+ "loss": 0.1937,
123
+ "step": 190
124
+ },
125
+ {
126
+ "epoch": 1.0,
127
+ "eval_accuracy": 0.9640740740740741,
128
+ "eval_loss": 0.11127929389476776,
129
+ "eval_runtime": 185.9907,
130
+ "eval_samples_per_second": 14.517,
131
+ "eval_steps_per_second": 0.457,
132
+ "step": 190
133
+ },
134
+ {
135
+ "epoch": 1.0,
136
+ "step": 190,
137
+ "total_flos": 6.041355501920256e+17,
138
+ "train_loss": 0.5059562551347833,
139
+ "train_runtime": 4360.0692,
140
+ "train_samples_per_second": 5.573,
141
+ "train_steps_per_second": 0.044
142
+ }
143
+ ],
144
+ "logging_steps": 10,
145
+ "max_steps": 190,
146
+ "num_train_epochs": 1,
147
+ "save_steps": 500,
148
+ "total_flos": 6.041355501920256e+17,
149
+ "trial_name": null,
150
+ "trial_params": null
151
+ }
training_args.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:7f781fc2b8cc7e2e6dde2f87ffb7555a2159dfa13c62dced65f31ce228080ffa
3
+ size 4536