MoGHenry commited on
Commit
488c9ed
·
verified ·
1 Parent(s): b1b832a

End of training

Browse files
Files changed (5) hide show
  1. README.md +95 -0
  2. config.json +49 -0
  3. model.safetensors +3 -0
  4. preprocessor_config.json +22 -0
  5. training_args.bin +3 -0
README.md ADDED
@@ -0,0 +1,95 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ library_name: transformers
3
+ license: apache-2.0
4
+ base_model: microsoft/resnet-50
5
+ tags:
6
+ - generated_from_trainer
7
+ datasets:
8
+ - imagefolder
9
+ metrics:
10
+ - accuracy
11
+ model-index:
12
+ - name: cat_dog_classifier_with_small_datasest
13
+ results:
14
+ - task:
15
+ name: Image Classification
16
+ type: image-classification
17
+ dataset:
18
+ name: imagefolder
19
+ type: imagefolder
20
+ config: default
21
+ split: train
22
+ args: default
23
+ metrics:
24
+ - name: Accuracy
25
+ type: accuracy
26
+ value: 0.8571428571428571
27
+ ---
28
+
29
+ <!-- This model card has been generated automatically according to the information the Trainer had access to. You
30
+ should probably proofread and complete it, then remove this comment. -->
31
+
32
+ # cat_dog_classifier_with_small_datasest
33
+
34
+ This model is a fine-tuned version of [microsoft/resnet-50](https://huggingface.co/microsoft/resnet-50) on the imagefolder dataset.
35
+ It achieves the following results on the evaluation set:
36
+ - Loss: 0.5540
37
+ - Accuracy: 0.8571
38
+
39
+ ## Model description
40
+
41
+ More information needed
42
+
43
+ ## Intended uses & limitations
44
+
45
+ More information needed
46
+
47
+ ## Training and evaluation data
48
+
49
+ More information needed
50
+
51
+ ## Training procedure
52
+
53
+ ### Training hyperparameters
54
+
55
+ The following hyperparameters were used during training:
56
+ - learning_rate: 5e-05
57
+ - train_batch_size: 4
58
+ - eval_batch_size: 8
59
+ - seed: 42
60
+ - optimizer: Use adamw_torch with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
61
+ - lr_scheduler_type: linear
62
+ - num_epochs: 20
63
+
64
+ ### Training results
65
+
66
+ | Training Loss | Epoch | Step | Validation Loss | Accuracy |
67
+ |:-------------:|:-----:|:----:|:---------------:|:--------:|
68
+ | No log | 1.0 | 140 | 0.5149 | 0.8143 |
69
+ | No log | 2.0 | 280 | 0.2519 | 0.9214 |
70
+ | No log | 3.0 | 420 | 0.3596 | 0.85 |
71
+ | 0.3145 | 4.0 | 560 | 0.2661 | 0.9214 |
72
+ | 0.3145 | 5.0 | 700 | 0.2600 | 0.8929 |
73
+ | 0.3145 | 6.0 | 840 | 0.1840 | 0.9286 |
74
+ | 0.3145 | 7.0 | 980 | 0.3145 | 0.9071 |
75
+ | 0.27 | 8.0 | 1120 | 0.2121 | 0.9214 |
76
+ | 0.27 | 9.0 | 1260 | 0.3926 | 0.8571 |
77
+ | 0.27 | 10.0 | 1400 | 0.3488 | 0.8786 |
78
+ | 0.2426 | 11.0 | 1540 | 0.2437 | 0.9071 |
79
+ | 0.2426 | 12.0 | 1680 | 0.2497 | 0.9 |
80
+ | 0.2426 | 13.0 | 1820 | 0.1663 | 0.9214 |
81
+ | 0.2426 | 14.0 | 1960 | 0.2132 | 0.9357 |
82
+ | 0.2556 | 15.0 | 2100 | 0.3464 | 0.8714 |
83
+ | 0.2556 | 16.0 | 2240 | 0.3063 | 0.9071 |
84
+ | 0.2556 | 17.0 | 2380 | 0.2992 | 0.9071 |
85
+ | 0.261 | 18.0 | 2520 | 0.3765 | 0.8857 |
86
+ | 0.261 | 19.0 | 2660 | 0.1396 | 0.9286 |
87
+ | 0.261 | 20.0 | 2800 | 0.5540 | 0.8571 |
88
+
89
+
90
+ ### Framework versions
91
+
92
+ - Transformers 4.47.1
93
+ - Pytorch 2.4.1+cu121
94
+ - Datasets 3.2.0
95
+ - Tokenizers 0.21.0
config.json ADDED
@@ -0,0 +1,49 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "microsoft/resnet-50",
3
+ "architectures": [
4
+ "ResNetForImageClassification"
5
+ ],
6
+ "depths": [
7
+ 3,
8
+ 4,
9
+ 6,
10
+ 3
11
+ ],
12
+ "downsample_in_bottleneck": false,
13
+ "downsample_in_first_stage": false,
14
+ "embedding_size": 64,
15
+ "hidden_act": "relu",
16
+ "hidden_sizes": [
17
+ 256,
18
+ 512,
19
+ 1024,
20
+ 2048
21
+ ],
22
+ "id2label": {
23
+ "0": "cats",
24
+ "1": "dogs"
25
+ },
26
+ "label2id": {
27
+ "cats": "0",
28
+ "dogs": "1"
29
+ },
30
+ "layer_type": "bottleneck",
31
+ "model_type": "resnet",
32
+ "num_channels": 3,
33
+ "out_features": [
34
+ "stage4"
35
+ ],
36
+ "out_indices": [
37
+ 4
38
+ ],
39
+ "problem_type": "single_label_classification",
40
+ "stage_names": [
41
+ "stem",
42
+ "stage1",
43
+ "stage2",
44
+ "stage3",
45
+ "stage4"
46
+ ],
47
+ "torch_dtype": "float32",
48
+ "transformers_version": "4.47.1"
49
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5062c7e929c839913be7cc1450108ba30e529ee5437b6f5fd9f1174e10bf9120
3
+ size 94302952
preprocessor_config.json ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "crop_pct": 0.875,
3
+ "do_normalize": true,
4
+ "do_rescale": true,
5
+ "do_resize": true,
6
+ "image_mean": [
7
+ 0.485,
8
+ 0.456,
9
+ 0.406
10
+ ],
11
+ "image_processor_type": "ConvNextImageProcessor",
12
+ "image_std": [
13
+ 0.229,
14
+ 0.224,
15
+ 0.225
16
+ ],
17
+ "resample": 3,
18
+ "rescale_factor": 0.00392156862745098,
19
+ "size": {
20
+ "shortest_edge": 224
21
+ }
22
+ }
training_args.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a48a20a9ee2b11e112d3b92bc427414ead8aa76250505a74c21dde3a255fbb9e
3
+ size 5368