elvispresniy
commited on
Commit
•
13e5233
1
Parent(s):
41e907d
End of training
Browse files- README.md +66 -0
- config.json +228 -0
- model.safetensors +3 -0
- preprocessor_config.json +22 -0
- training_args.bin +3 -0
README.md
ADDED
@@ -0,0 +1,66 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
license: apache-2.0
|
3 |
+
base_model: google/vit-base-patch16-224-in21k
|
4 |
+
tags:
|
5 |
+
- generated_from_trainer
|
6 |
+
metrics:
|
7 |
+
- accuracy
|
8 |
+
model-index:
|
9 |
+
- name: vit-food101
|
10 |
+
results: []
|
11 |
+
---
|
12 |
+
|
13 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
14 |
+
should probably proofread and complete it, then remove this comment. -->
|
15 |
+
|
16 |
+
# vit-food101
|
17 |
+
|
18 |
+
This model is a fine-tuned version of [google/vit-base-patch16-224-in21k](https://huggingface.co/google/vit-base-patch16-224-in21k) on an unknown dataset.
|
19 |
+
It achieves the following results on the evaluation set:
|
20 |
+
- Loss: 0.4925
|
21 |
+
- Accuracy: 0.899
|
22 |
+
|
23 |
+
## Model description
|
24 |
+
|
25 |
+
More information needed
|
26 |
+
|
27 |
+
## Intended uses & limitations
|
28 |
+
|
29 |
+
More information needed
|
30 |
+
|
31 |
+
## Training and evaluation data
|
32 |
+
|
33 |
+
More information needed
|
34 |
+
|
35 |
+
## Training procedure
|
36 |
+
|
37 |
+
### Training hyperparameters
|
38 |
+
|
39 |
+
The following hyperparameters were used during training:
|
40 |
+
- learning_rate: 0.0002
|
41 |
+
- train_batch_size: 64
|
42 |
+
- eval_batch_size: 8
|
43 |
+
- seed: 42
|
44 |
+
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
45 |
+
- lr_scheduler_type: linear
|
46 |
+
- num_epochs: 4
|
47 |
+
- mixed_precision_training: Native AMP
|
48 |
+
|
49 |
+
### Training results
|
50 |
+
|
51 |
+
| Training Loss | Epoch | Step | Validation Loss | Accuracy |
|
52 |
+
|:-------------:|:------:|:----:|:---------------:|:--------:|
|
53 |
+
| 2.682 | 0.6369 | 100 | 2.5501 | 0.802 |
|
54 |
+
| 1.312 | 1.2739 | 200 | 1.3870 | 0.855 |
|
55 |
+
| 0.7605 | 1.9108 | 300 | 0.9167 | 0.862 |
|
56 |
+
| 0.3844 | 2.5478 | 400 | 0.6248 | 0.88 |
|
57 |
+
| 0.1957 | 3.1847 | 500 | 0.5220 | 0.896 |
|
58 |
+
| 0.1756 | 3.8217 | 600 | 0.4925 | 0.899 |
|
59 |
+
|
60 |
+
|
61 |
+
### Framework versions
|
62 |
+
|
63 |
+
- Transformers 4.42.4
|
64 |
+
- Pytorch 2.3.1+cu121
|
65 |
+
- Datasets 2.20.0
|
66 |
+
- Tokenizers 0.19.1
|
config.json
ADDED
@@ -0,0 +1,228 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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": "apple",
|
13 |
+
"1": "aquarium_fish",
|
14 |
+
"10": "bowl",
|
15 |
+
"11": "boy",
|
16 |
+
"12": "bridge",
|
17 |
+
"13": "bus",
|
18 |
+
"14": "butterfly",
|
19 |
+
"15": "camel",
|
20 |
+
"16": "can",
|
21 |
+
"17": "castle",
|
22 |
+
"18": "caterpillar",
|
23 |
+
"19": "cattle",
|
24 |
+
"2": "baby",
|
25 |
+
"20": "chair",
|
26 |
+
"21": "chimpanzee",
|
27 |
+
"22": "clock",
|
28 |
+
"23": "cloud",
|
29 |
+
"24": "cockroach",
|
30 |
+
"25": "couch",
|
31 |
+
"26": "cra",
|
32 |
+
"27": "crocodile",
|
33 |
+
"28": "cup",
|
34 |
+
"29": "dinosaur",
|
35 |
+
"3": "bear",
|
36 |
+
"30": "dolphin",
|
37 |
+
"31": "elephant",
|
38 |
+
"32": "flatfish",
|
39 |
+
"33": "forest",
|
40 |
+
"34": "fox",
|
41 |
+
"35": "girl",
|
42 |
+
"36": "hamster",
|
43 |
+
"37": "house",
|
44 |
+
"38": "kangaroo",
|
45 |
+
"39": "keyboard",
|
46 |
+
"4": "beaver",
|
47 |
+
"40": "lamp",
|
48 |
+
"41": "lawn_mower",
|
49 |
+
"42": "leopard",
|
50 |
+
"43": "lion",
|
51 |
+
"44": "lizard",
|
52 |
+
"45": "lobster",
|
53 |
+
"46": "man",
|
54 |
+
"47": "maple_tree",
|
55 |
+
"48": "motorcycle",
|
56 |
+
"49": "mountain",
|
57 |
+
"5": "bed",
|
58 |
+
"50": "mouse",
|
59 |
+
"51": "mushroom",
|
60 |
+
"52": "oak_tree",
|
61 |
+
"53": "orange",
|
62 |
+
"54": "orchid",
|
63 |
+
"55": "otter",
|
64 |
+
"56": "palm_tree",
|
65 |
+
"57": "pear",
|
66 |
+
"58": "pickup_truck",
|
67 |
+
"59": "pine_tree",
|
68 |
+
"6": "bee",
|
69 |
+
"60": "plain",
|
70 |
+
"61": "plate",
|
71 |
+
"62": "poppy",
|
72 |
+
"63": "porcupine",
|
73 |
+
"64": "possum",
|
74 |
+
"65": "rabbit",
|
75 |
+
"66": "raccoon",
|
76 |
+
"67": "ray",
|
77 |
+
"68": "road",
|
78 |
+
"69": "rocket",
|
79 |
+
"7": "beetle",
|
80 |
+
"70": "rose",
|
81 |
+
"71": "sea",
|
82 |
+
"72": "seal",
|
83 |
+
"73": "shark",
|
84 |
+
"74": "shrew",
|
85 |
+
"75": "skunk",
|
86 |
+
"76": "skyscraper",
|
87 |
+
"77": "snail",
|
88 |
+
"78": "snake",
|
89 |
+
"79": "spider",
|
90 |
+
"8": "bicycle",
|
91 |
+
"80": "squirrel",
|
92 |
+
"81": "streetcar",
|
93 |
+
"82": "sunflower",
|
94 |
+
"83": "sweet_pepper",
|
95 |
+
"84": "table",
|
96 |
+
"85": "tank",
|
97 |
+
"86": "telephone",
|
98 |
+
"87": "television",
|
99 |
+
"88": "tiger",
|
100 |
+
"89": "tractor",
|
101 |
+
"9": "bottle",
|
102 |
+
"90": "train",
|
103 |
+
"91": "trout",
|
104 |
+
"92": "tulip",
|
105 |
+
"93": "turtle",
|
106 |
+
"94": "wardrobe",
|
107 |
+
"95": "whale",
|
108 |
+
"96": "willow_tree",
|
109 |
+
"97": "wolf",
|
110 |
+
"98": "woman",
|
111 |
+
"99": "worm"
|
112 |
+
},
|
113 |
+
"image_size": 224,
|
114 |
+
"initializer_range": 0.02,
|
115 |
+
"intermediate_size": 3072,
|
116 |
+
"label2id": {
|
117 |
+
"apple": "0",
|
118 |
+
"aquarium_fish": "1",
|
119 |
+
"baby": "2",
|
120 |
+
"bear": "3",
|
121 |
+
"beaver": "4",
|
122 |
+
"bed": "5",
|
123 |
+
"bee": "6",
|
124 |
+
"beetle": "7",
|
125 |
+
"bicycle": "8",
|
126 |
+
"bottle": "9",
|
127 |
+
"bowl": "10",
|
128 |
+
"boy": "11",
|
129 |
+
"bridge": "12",
|
130 |
+
"bus": "13",
|
131 |
+
"butterfly": "14",
|
132 |
+
"camel": "15",
|
133 |
+
"can": "16",
|
134 |
+
"castle": "17",
|
135 |
+
"caterpillar": "18",
|
136 |
+
"cattle": "19",
|
137 |
+
"chair": "20",
|
138 |
+
"chimpanzee": "21",
|
139 |
+
"clock": "22",
|
140 |
+
"cloud": "23",
|
141 |
+
"cockroach": "24",
|
142 |
+
"couch": "25",
|
143 |
+
"cra": "26",
|
144 |
+
"crocodile": "27",
|
145 |
+
"cup": "28",
|
146 |
+
"dinosaur": "29",
|
147 |
+
"dolphin": "30",
|
148 |
+
"elephant": "31",
|
149 |
+
"flatfish": "32",
|
150 |
+
"forest": "33",
|
151 |
+
"fox": "34",
|
152 |
+
"girl": "35",
|
153 |
+
"hamster": "36",
|
154 |
+
"house": "37",
|
155 |
+
"kangaroo": "38",
|
156 |
+
"keyboard": "39",
|
157 |
+
"lamp": "40",
|
158 |
+
"lawn_mower": "41",
|
159 |
+
"leopard": "42",
|
160 |
+
"lion": "43",
|
161 |
+
"lizard": "44",
|
162 |
+
"lobster": "45",
|
163 |
+
"man": "46",
|
164 |
+
"maple_tree": "47",
|
165 |
+
"motorcycle": "48",
|
166 |
+
"mountain": "49",
|
167 |
+
"mouse": "50",
|
168 |
+
"mushroom": "51",
|
169 |
+
"oak_tree": "52",
|
170 |
+
"orange": "53",
|
171 |
+
"orchid": "54",
|
172 |
+
"otter": "55",
|
173 |
+
"palm_tree": "56",
|
174 |
+
"pear": "57",
|
175 |
+
"pickup_truck": "58",
|
176 |
+
"pine_tree": "59",
|
177 |
+
"plain": "60",
|
178 |
+
"plate": "61",
|
179 |
+
"poppy": "62",
|
180 |
+
"porcupine": "63",
|
181 |
+
"possum": "64",
|
182 |
+
"rabbit": "65",
|
183 |
+
"raccoon": "66",
|
184 |
+
"ray": "67",
|
185 |
+
"road": "68",
|
186 |
+
"rocket": "69",
|
187 |
+
"rose": "70",
|
188 |
+
"sea": "71",
|
189 |
+
"seal": "72",
|
190 |
+
"shark": "73",
|
191 |
+
"shrew": "74",
|
192 |
+
"skunk": "75",
|
193 |
+
"skyscraper": "76",
|
194 |
+
"snail": "77",
|
195 |
+
"snake": "78",
|
196 |
+
"spider": "79",
|
197 |
+
"squirrel": "80",
|
198 |
+
"streetcar": "81",
|
199 |
+
"sunflower": "82",
|
200 |
+
"sweet_pepper": "83",
|
201 |
+
"table": "84",
|
202 |
+
"tank": "85",
|
203 |
+
"telephone": "86",
|
204 |
+
"television": "87",
|
205 |
+
"tiger": "88",
|
206 |
+
"tractor": "89",
|
207 |
+
"train": "90",
|
208 |
+
"trout": "91",
|
209 |
+
"tulip": "92",
|
210 |
+
"turtle": "93",
|
211 |
+
"wardrobe": "94",
|
212 |
+
"whale": "95",
|
213 |
+
"willow_tree": "96",
|
214 |
+
"wolf": "97",
|
215 |
+
"woman": "98",
|
216 |
+
"worm": "99"
|
217 |
+
},
|
218 |
+
"layer_norm_eps": 1e-12,
|
219 |
+
"model_type": "vit",
|
220 |
+
"num_attention_heads": 12,
|
221 |
+
"num_channels": 3,
|
222 |
+
"num_hidden_layers": 12,
|
223 |
+
"patch_size": 16,
|
224 |
+
"problem_type": "single_label_classification",
|
225 |
+
"qkv_bias": true,
|
226 |
+
"torch_dtype": "float32",
|
227 |
+
"transformers_version": "4.42.4"
|
228 |
+
}
|
model.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:f8247fc1bfd4993c348f650827718bcec383346671b151bfdd0b7dcbfdd53428
|
3 |
+
size 343525432
|
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 |
+
}
|
training_args.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:b9983f71b713b6c70d45d748db25b269da87a2fa566e1b9dc904ab42bd97d2a9
|
3 |
+
size 5112
|