mstatt commited on
Commit
7ed0665
·
verified ·
1 Parent(s): 465e6d4

Upload ViTForImageClassification

Browse files
Files changed (3) hide show
  1. README.md +4 -10
  2. config.json +123 -403
  3. model.safetensors +2 -2
README.md CHANGED
@@ -1,7 +1,7 @@
1
  ---
2
- license: mit
3
  language:
4
  - en
 
5
  ---
6
  # Logo Recognition Model: a mix of UAE companies and global enterprises
7
 
@@ -60,14 +60,8 @@ The base model used is the Vision Transformer `vit-base-patch16-224-in21k`, whic
60
  The model was trained on a curated dataset of UAE company logos as well as others of international companies. The dataset consists of thousands of images across various brands to ensure robustness and accuracy.
61
 
62
  ### Performance
63
- ***** eval metrics *****
64
- - epoch = 20.0
65
- - eval_accuracy = 0.9761
66
- - eval_loss = 0.1193
67
- - eval_runtime = 0:00:20.51
68
- - eval_samples_per_second = 268.951
69
- - eval_steps_per_second = 8.432
70
-
71
  ## How to Use
72
  To use the model for inference, you can load it using the `transformers` library from Hugging Face:
73
 
@@ -160,7 +154,7 @@ print(model.config.id2label[predicted_label])
160
 
161
 
162
  ### Limitations and Biases
163
- - The model is specifically trained on UAE company logos and a few from Outside the UAE, it may not perform well on logos from numerous other large or small companies.
164
  - The model's performance is contingent upon the quality and diversity of the training dataset.
165
  - Potential biases in the training data can lead to biases in model predictions.
166
 
 
1
  ---
 
2
  language:
3
  - en
4
+ license: mit
5
  ---
6
  # Logo Recognition Model: a mix of UAE companies and global enterprises
7
 
 
60
  The model was trained on a curated dataset of UAE company logos as well as others of international companies. The dataset consists of thousands of images across various brands to ensure robustness and accuracy.
61
 
62
  ### Performance
63
+ The model achieved high accuracy on a held-out validation set, indicating strong performance in classifying UAE company logos. Detailed performance metrics (accuracy, precision, recall, F1-score) can be provided upon request.
64
+
 
 
 
 
 
 
65
  ## How to Use
66
  To use the model for inference, you can load it using the `transformers` library from Hugging Face:
67
 
 
154
 
155
 
156
  ### Limitations and Biases
157
+ - The model is specifically trained on UAE company logos and may not perform well on logos from companies outside the UAE.
158
  - The model's performance is contingent upon the quality and diversity of the training dataset.
159
  - Potential biases in the training data can lead to biases in model predictions.
160
 
config.json CHANGED
@@ -1,5 +1,5 @@
1
  {
2
- "_name_or_path": "Falconsai/brand_identification",
3
  "architectures": [
4
  "ViTForImageClassification"
5
  ],
@@ -9,415 +9,135 @@
9
  "hidden_dropout_prob": 0.0,
10
  "hidden_size": 768,
11
  "id2label": {
12
- "0": "acer",
13
- "1": "acerr",
14
  "2": "adidas",
15
- "3": "aerial7",
16
- "4": "agfa",
17
- "5": "ainol",
18
- "6": "aiptek",
19
- "7": "akai",
20
- "8": "alienware",
21
- "9": "amd",
22
- "10": "amkette",
23
- "11": "amoi",
24
- "12": "amstrad",
25
- "13": "andrea_electronics",
26
- "14": "apple",
27
- "15": "applek",
28
- "16": "arm",
29
- "17": "asl",
30
- "18": "astro",
31
- "19": "asus",
32
- "20": "asusu",
33
- "21": "avaya",
34
- "22": "aya",
35
- "23": "bang_&_olufsen",
36
- "24": "bayern",
37
- "25": "bazooka",
38
- "26": "bbk",
39
- "27": "bcp",
40
- "28": "beacon",
41
- "29": "beats_by_dre",
42
- "30": "blackberry",
43
- "31": "blue_star",
44
- "32": "bose",
45
- "33": "boses",
46
- "34": "breaker",
47
- "35": "btc",
48
- "36": "calistoga",
49
- "37": "calumet",
50
- "38": "casio",
51
- "39": "cce",
52
- "40": "cisco_systems",
53
- "41": "clarion",
54
- "42": "coke",
55
- "43": "compact",
56
- "44": "connector",
57
- "45": "contax",
58
- "46": "contec",
59
- "47": "contour",
60
- "48": "cooke",
61
- "49": "currys",
62
- "50": "cybertron",
63
- "51": "d-link",
64
- "52": "daewoo_electronics",
65
- "53": "dawa",
66
- "54": "dayton",
67
- "55": "dell",
68
- "56": "delonghi",
69
- "57": "denver",
70
- "58": "devolo",
71
- "59": "digital",
72
- "60": "dimension",
73
- "61": "ecs",
74
- "62": "el_dorado",
75
- "63": "emachines",
76
- "64": "emirates_airlines",
77
- "65": "epson",
78
- "66": "fram",
79
- "67": "fujifilm",
80
- "68": "fujitsu",
81
- "69": "gateway",
82
- "70": "genius",
83
- "71": "goldstar",
84
- "72": "google",
85
- "73": "gopro",
86
- "74": "gorenje",
87
- "75": "grundig",
88
- "76": "haier",
89
- "77": "havells",
90
- "78": "hcl",
91
- "79": "hec",
92
- "80": "hewlett-packard",
93
- "81": "high_point",
94
- "82": "hisense",
95
- "83": "hitachi",
96
- "84": "honeywell",
97
- "85": "hp",
98
- "86": "htc",
99
- "87": "huawei",
100
- "88": "hughes_&_kettner",
101
- "89": "hypson",
102
- "90": "ibm",
103
- "91": "ifr",
104
- "92": "iiyama",
105
- "93": "ilford_photo",
106
- "94": "intel",
107
- "95": "iqinvision",
108
- "96": "jenoptik",
109
- "97": "jl_audio",
110
- "98": "kapsch",
111
- "99": "kef",
112
- "100": "kenko",
113
- "101": "kicker",
114
- "102": "kingston",
115
- "103": "kodak",
116
- "104": "konica_minolta",
117
- "105": "leadtek",
118
- "106": "leica",
119
- "107": "lenovo",
120
- "108": "leupold",
121
- "109": "lg",
122
- "110": "lifesize",
123
- "111": "lite-on",
124
- "112": "livescribe",
125
- "113": "logitech",
126
- "114": "louis_vuitton",
127
- "115": "luxgen",
128
- "116": "magnafon",
129
- "117": "mamiya",
130
- "118": "man_o'_war",
131
- "119": "marshall",
132
- "120": "mcdonalds",
133
- "121": "mediatek",
134
- "122": "medion",
135
- "123": "meopta",
136
- "124": "mercedes",
137
- "125": "merrell",
138
- "126": "metz",
139
- "127": "microsoft",
140
- "128": "minolta",
141
- "129": "mobotix",
142
- "130": "mophie",
143
- "131": "motorola",
144
- "132": "msi",
145
- "133": "mud_&_bugs",
146
- "134": "multitech",
147
- "135": "national",
148
- "136": "nike",
149
- "137": "nikon",
150
- "138": "nvidia",
151
- "139": "olympus",
152
- "140": "oppo",
153
- "141": "orbit",
154
- "142": "panasonic",
155
- "143": "pantech",
156
- "144": "pathe",
157
- "145": "pentium",
158
- "146": "phase_one",
159
- "147": "philco",
160
- "148": "philips",
161
- "149": "pioneer",
162
- "150": "planar",
163
- "151": "polaroid",
164
- "152": "premier",
165
- "153": "prima",
166
- "154": "proline",
167
- "155": "punch",
168
- "156": "rbm",
169
- "157": "rca",
170
- "158": "ricoh",
171
- "159": "sagemcom",
172
- "160": "sakura",
173
- "161": "sampo",
174
- "162": "samsung",
175
- "163": "san",
176
- "164": "sansui",
177
- "165": "santa_rosa",
178
- "166": "sanyo",
179
- "167": "sea_&_sea",
180
- "168": "seg",
181
- "169": "seitz",
182
- "170": "sharp",
183
- "171": "sharp_corporation",
184
- "172": "sibelius",
185
- "173": "sinar",
186
- "174": "sinclair",
187
- "175": "sony",
188
- "176": "sony_ericsson",
189
- "177": "spc",
190
- "178": "speck",
191
- "179": "start",
192
- "180": "suzuki",
193
- "181": "sva",
194
- "182": "tab",
195
- "183": "tcl",
196
- "184": "technics",
197
- "185": "teleavia",
198
- "186": "telefunken",
199
- "187": "teletech",
200
- "188": "thomson",
201
- "189": "tma",
202
- "190": "tmb",
203
- "191": "toshiba",
204
- "192": "transcend",
205
- "193": "trust",
206
- "194": "tunes",
207
- "195": "ubuntu",
208
- "196": "universum",
209
- "197": "vestel",
210
- "198": "vim",
211
- "199": "vit",
212
- "200": "vive",
213
- "201": "walton"
214
  },
215
  "image_size": 224,
216
  "initializer_range": 0.02,
217
  "intermediate_size": 3072,
218
  "label2id": {
219
- "acer": "0",
220
- "acerr": "1",
221
  "adidas": "2",
222
- "aerial7": "3",
223
- "agfa": "4",
224
- "ainol": "5",
225
- "aiptek": "6",
226
- "akai": "7",
227
- "alienware": "8",
228
- "amd": "9",
229
- "amkette": "10",
230
- "amoi": "11",
231
- "amstrad": "12",
232
- "andrea_electronics": "13",
233
- "apple": "14",
234
- "applek": "15",
235
- "arm": "16",
236
- "asl": "17",
237
- "astro": "18",
238
- "asus": "19",
239
- "asusu": "20",
240
- "avaya": "21",
241
- "aya": "22",
242
- "bang_&_olufsen": "23",
243
- "bayern": "24",
244
- "bazooka": "25",
245
- "bbk": "26",
246
- "bcp": "27",
247
- "beacon": "28",
248
- "beats_by_dre": "29",
249
- "blackberry": "30",
250
- "blue_star": "31",
251
- "bose": "32",
252
- "boses": "33",
253
- "breaker": "34",
254
- "btc": "35",
255
- "calistoga": "36",
256
- "calumet": "37",
257
- "casio": "38",
258
- "cce": "39",
259
- "cisco_systems": "40",
260
- "clarion": "41",
261
- "coke": "42",
262
- "compact": "43",
263
- "connector": "44",
264
- "contax": "45",
265
- "contec": "46",
266
- "contour": "47",
267
- "cooke": "48",
268
- "currys": "49",
269
- "cybertron": "50",
270
- "d-link": "51",
271
- "daewoo_electronics": "52",
272
- "dawa": "53",
273
- "dayton": "54",
274
- "dell": "55",
275
- "delonghi": "56",
276
- "denver": "57",
277
- "devolo": "58",
278
- "digital": "59",
279
- "dimension": "60",
280
- "ecs": "61",
281
- "el_dorado": "62",
282
- "emachines": "63",
283
- "emirates_airlines": "64",
284
- "epson": "65",
285
- "fram": "66",
286
- "fujifilm": "67",
287
- "fujitsu": "68",
288
- "gateway": "69",
289
- "genius": "70",
290
- "goldstar": "71",
291
- "google": "72",
292
- "gopro": "73",
293
- "gorenje": "74",
294
- "grundig": "75",
295
- "haier": "76",
296
- "havells": "77",
297
- "hcl": "78",
298
- "hec": "79",
299
- "hewlett-packard": "80",
300
- "high_point": "81",
301
- "hisense": "82",
302
- "hitachi": "83",
303
- "honeywell": "84",
304
- "hp": "85",
305
- "htc": "86",
306
- "huawei": "87",
307
- "hughes_&_kettner": "88",
308
- "hypson": "89",
309
- "ibm": "90",
310
- "ifr": "91",
311
- "iiyama": "92",
312
- "ilford_photo": "93",
313
- "intel": "94",
314
- "iqinvision": "95",
315
- "jenoptik": "96",
316
- "jl_audio": "97",
317
- "kapsch": "98",
318
- "kef": "99",
319
- "kenko": "100",
320
- "kicker": "101",
321
- "kingston": "102",
322
- "kodak": "103",
323
- "konica_minolta": "104",
324
- "leadtek": "105",
325
- "leica": "106",
326
- "lenovo": "107",
327
- "leupold": "108",
328
- "lg": "109",
329
- "lifesize": "110",
330
- "lite-on": "111",
331
- "livescribe": "112",
332
- "logitech": "113",
333
- "louis_vuitton": "114",
334
- "luxgen": "115",
335
- "magnafon": "116",
336
- "mamiya": "117",
337
- "man_o'_war": "118",
338
- "marshall": "119",
339
- "mcdonalds": "120",
340
- "mediatek": "121",
341
- "medion": "122",
342
- "meopta": "123",
343
- "mercedes": "124",
344
- "merrell": "125",
345
- "metz": "126",
346
- "microsoft": "127",
347
- "minolta": "128",
348
- "mobotix": "129",
349
- "mophie": "130",
350
- "motorola": "131",
351
- "msi": "132",
352
- "mud_&_bugs": "133",
353
- "multitech": "134",
354
- "national": "135",
355
- "nike": "136",
356
- "nikon": "137",
357
- "nvidia": "138",
358
- "olympus": "139",
359
- "oppo": "140",
360
- "orbit": "141",
361
- "panasonic": "142",
362
- "pantech": "143",
363
- "pathe": "144",
364
- "pentium": "145",
365
- "phase_one": "146",
366
- "philco": "147",
367
- "philips": "148",
368
- "pioneer": "149",
369
- "planar": "150",
370
- "polaroid": "151",
371
- "premier": "152",
372
- "prima": "153",
373
- "proline": "154",
374
- "punch": "155",
375
- "rbm": "156",
376
- "rca": "157",
377
- "ricoh": "158",
378
- "sagemcom": "159",
379
- "sakura": "160",
380
- "sampo": "161",
381
- "samsung": "162",
382
- "san": "163",
383
- "sansui": "164",
384
- "santa_rosa": "165",
385
- "sanyo": "166",
386
- "sea_&_sea": "167",
387
- "seg": "168",
388
- "seitz": "169",
389
- "sharp": "170",
390
- "sharp_corporation": "171",
391
- "sibelius": "172",
392
- "sinar": "173",
393
- "sinclair": "174",
394
- "sony": "175",
395
- "sony_ericsson": "176",
396
- "spc": "177",
397
- "speck": "178",
398
- "start": "179",
399
- "suzuki": "180",
400
- "sva": "181",
401
- "tab": "182",
402
- "tcl": "183",
403
- "technics": "184",
404
- "teleavia": "185",
405
- "telefunken": "186",
406
- "teletech": "187",
407
- "thomson": "188",
408
- "tma": "189",
409
- "tmb": "190",
410
- "toshiba": "191",
411
- "transcend": "192",
412
- "trust": "193",
413
- "tunes": "194",
414
- "ubuntu": "195",
415
- "universum": "196",
416
- "vestel": "197",
417
- "vim": "198",
418
- "vit": "199",
419
- "vive": "200",
420
- "walton": "201"
421
  },
422
  "layer_norm_eps": 1e-12,
423
  "model_type": "vit",
 
1
  {
2
+ "_name_or_path": "./model/vit_model/",
3
  "architectures": [
4
  "ViTForImageClassification"
5
  ],
 
9
  "hidden_dropout_prob": 0.0,
10
  "hidden_size": 768,
11
  "id2label": {
12
+ "0": "abu_dhabi_islamic_bank",
13
+ "1": "acer",
14
  "2": "adidas",
15
+ "3": "adnoc",
16
+ "4": "aldar",
17
+ "5": "alienware",
18
+ "6": "amazon",
19
+ "7": "amd",
20
+ "8": "apple",
21
+ "9": "asus",
22
+ "10": "beats_by_dre",
23
+ "11": "blackberry",
24
+ "12": "bose",
25
+ "13": "careem",
26
+ "14": "cisco_systems",
27
+ "15": "coke",
28
+ "16": "d-link",
29
+ "17": "dell",
30
+ "18": "delonghi",
31
+ "19": "dp_world",
32
+ "20": "du",
33
+ "21": "e&",
34
+ "22": "emaar",
35
+ "23": "emirates",
36
+ "24": "emirates_nbd",
37
+ "25": "etisalat",
38
+ "26": "falcons.ai",
39
+ "27": "first_abu_dhabi_bank",
40
+ "28": "fujitsu",
41
+ "29": "google",
42
+ "30": "gopro",
43
+ "31": "hec",
44
+ "32": "hewlett_packard",
45
+ "33": "hilti",
46
+ "34": "hisense",
47
+ "35": "huawei",
48
+ "36": "ibm",
49
+ "37": "khaleej_times",
50
+ "38": "l'or\u00e9al",
51
+ "39": "lenovo",
52
+ "40": "lg",
53
+ "41": "linkedin",
54
+ "42": "louis_vuitton",
55
+ "43": "majid_al_futtaim",
56
+ "44": "mashreq",
57
+ "45": "maybelline",
58
+ "46": "mcdonalds",
59
+ "47": "mercedes",
60
+ "48": "meta",
61
+ "49": "microsoft",
62
+ "50": "msi",
63
+ "51": "nike",
64
+ "52": "nvidia",
65
+ "53": "openai",
66
+ "54": "puma",
67
+ "55": "rakez",
68
+ "56": "samsung",
69
+ "57": "snapdragon",
70
+ "58": "tesla",
71
+ "59": "ubuntu",
72
+ "60": "virgin",
73
+ "61": "zwag"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
74
  },
75
  "image_size": 224,
76
  "initializer_range": 0.02,
77
  "intermediate_size": 3072,
78
  "label2id": {
79
+ "abu_dhabi_islamic_bank": "0",
80
+ "acer": "1",
81
  "adidas": "2",
82
+ "adnoc": "3",
83
+ "aldar": "4",
84
+ "alienware": "5",
85
+ "amazon": "6",
86
+ "amd": "7",
87
+ "apple": "8",
88
+ "asus": "9",
89
+ "beats_by_dre": "10",
90
+ "blackberry": "11",
91
+ "bose": "12",
92
+ "careem": "13",
93
+ "cisco_systems": "14",
94
+ "coke": "15",
95
+ "d-link": "16",
96
+ "dell": "17",
97
+ "delonghi": "18",
98
+ "dp_world": "19",
99
+ "du": "20",
100
+ "e&": "21",
101
+ "emaar": "22",
102
+ "emirates": "23",
103
+ "emirates_nbd": "24",
104
+ "etisalat": "25",
105
+ "falcons.ai": "26",
106
+ "first_abu_dhabi_bank": "27",
107
+ "fujitsu": "28",
108
+ "google": "29",
109
+ "gopro": "30",
110
+ "hec": "31",
111
+ "hewlett_packard": "32",
112
+ "hilti": "33",
113
+ "hisense": "34",
114
+ "huawei": "35",
115
+ "ibm": "36",
116
+ "khaleej_times": "37",
117
+ "l'or\u00e9al": "38",
118
+ "lenovo": "39",
119
+ "lg": "40",
120
+ "linkedin": "41",
121
+ "louis_vuitton": "42",
122
+ "majid_al_futtaim": "43",
123
+ "mashreq": "44",
124
+ "maybelline": "45",
125
+ "mcdonalds": "46",
126
+ "mercedes": "47",
127
+ "meta": "48",
128
+ "microsoft": "49",
129
+ "msi": "50",
130
+ "nike": "51",
131
+ "nvidia": "52",
132
+ "openai": "53",
133
+ "puma": "54",
134
+ "rakez": "55",
135
+ "samsung": "56",
136
+ "snapdragon": "57",
137
+ "tesla": "58",
138
+ "ubuntu": "59",
139
+ "virgin": "60",
140
+ "zwag": "61"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
141
  },
142
  "layer_norm_eps": 1e-12,
143
  "model_type": "vit",
model.safetensors CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:7b5ee0a18e998068c3d460e7d60d3df325a26c30677f6769a8c6c491a1341511
3
- size 343839184
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ba0f32b0045483281c4de1682737579359be7eb4664f0829eb1540cb61451bc9
3
+ size 343408544