Vadim Alperovich
commited on
Commit
•
bb2464c
1
Parent(s):
9188868
Update QC.py
Browse files
QC.py
CHANGED
@@ -19,48 +19,56 @@ _TRAIN_DOWNLOAD_URL = "https://huggingface.co/datasets/vmalperovich/QC/raw/main/
|
|
19 |
_TEST_DOWNLOAD_URL = "https://huggingface.co/datasets/vmalperovich/QC/raw/main/test.csv"
|
20 |
|
21 |
|
22 |
-
CATEGORY_MAPPING = {'
|
23 |
-
'
|
24 |
-
'
|
25 |
-
'
|
26 |
-
'
|
27 |
'HUM_gr': 5,
|
28 |
-
'
|
29 |
-
'
|
30 |
-
'
|
31 |
-
'
|
32 |
-
'
|
33 |
-
'
|
34 |
-
'
|
35 |
-
'
|
36 |
-
'
|
37 |
-
'
|
38 |
-
'
|
39 |
-
'
|
40 |
-
'
|
41 |
-
'
|
42 |
-
'
|
43 |
-
'
|
44 |
-
'
|
45 |
-
'
|
46 |
-
'
|
47 |
-
'
|
48 |
-
'
|
49 |
-
'
|
50 |
-
'
|
51 |
-
'
|
52 |
-
'
|
53 |
-
'
|
54 |
-
'
|
55 |
-
'
|
56 |
-
'
|
57 |
'ENTY_instru': 35,
|
58 |
'ABBR_abb': 36,
|
59 |
-
'
|
60 |
-
'
|
61 |
-
'
|
62 |
-
'
|
63 |
-
'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
64 |
|
65 |
class AGNews(datasets.GeneratorBasedBuilder):
|
66 |
"""AG News topic classification dataset."""
|
|
|
19 |
_TEST_DOWNLOAD_URL = "https://huggingface.co/datasets/vmalperovich/QC/raw/main/test.csv"
|
20 |
|
21 |
|
22 |
+
CATEGORY_MAPPING = {'ENTY_cremat': 0,
|
23 |
+
'DESC_manner': 1,
|
24 |
+
'ENTY_animal': 2,
|
25 |
+
'ABBR_exp': 3,
|
26 |
+
'HUM_ind': 4,
|
27 |
'HUM_gr': 5,
|
28 |
+
'HUM_title': 6,
|
29 |
+
'DESC_def': 7,
|
30 |
+
'NUM_date': 8,
|
31 |
+
'DESC_reason': 9,
|
32 |
+
'ENTY_event': 10,
|
33 |
+
'LOC_state': 11,
|
34 |
+
'DESC_desc': 12,
|
35 |
+
'NUM_count': 13,
|
36 |
+
'ENTY_other': 14,
|
37 |
+
'ENTY_letter': 15,
|
38 |
+
'LOC_other': 16,
|
39 |
+
'ENTY_religion': 17,
|
40 |
+
'ENTY_food': 18,
|
41 |
+
'LOC_country': 19,
|
42 |
+
'ENTY_color': 20,
|
43 |
+
'ENTY_termeq': 21,
|
44 |
+
'LOC_city': 22,
|
45 |
+
'ENTY_body': 23,
|
46 |
+
'ENTY_dismed': 24,
|
47 |
+
'LOC_mount': 25,
|
48 |
+
'NUM_money': 26,
|
49 |
+
'ENTY_product': 27,
|
50 |
+
'NUM_period': 28,
|
51 |
+
'ENTY_substance': 29,
|
52 |
+
'ENTY_sport': 30,
|
53 |
+
'ENTY_plant': 31,
|
54 |
+
'ENTY_techmeth': 32,
|
55 |
+
'NUM_volsize': 33,
|
56 |
+
'HUM_desc': 34,
|
57 |
'ENTY_instru': 35,
|
58 |
'ABBR_abb': 36,
|
59 |
+
'NUM_other': 37,
|
60 |
+
'NUM_speed': 38,
|
61 |
+
'ENTY_word': 39,
|
62 |
+
'ENTY_lang': 40,
|
63 |
+
'NUM_perc': 41,
|
64 |
+
'NUM_code': 42,
|
65 |
+
'NUM_dist': 43,
|
66 |
+
'NUM_temp': 44,
|
67 |
+
'ENTY_symbol': 45,
|
68 |
+
'NUM_ord': 46,
|
69 |
+
'ENTY_veh': 47,
|
70 |
+
'NUM_weight': 48,
|
71 |
+
'ENTY_currency': 49}
|
72 |
|
73 |
class AGNews(datasets.GeneratorBasedBuilder):
|
74 |
"""AG News topic classification dataset."""
|