ramybaly commited on
Commit
95e4d02
·
1 Parent(s): 3cb0756

fixed fine-grained tags

Browse files
Files changed (5) hide show
  1. id2fine_tags.json +1 -1
  2. nerd.py +67 -67
  3. test.txt +1 -1
  4. train.txt +1 -1
  5. validation.txt +1 -1
id2fine_tags.json CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:64604b88e4f94fb8d729e428302915704a04b8317c84802ae188ea41a97faaf6
3
  size 1748
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4b9f5cfbad814cb56b92edb8abb7070e83330dd4401becb24908cf4b780cccf0
3
  size 1748
nerd.py CHANGED
@@ -77,72 +77,72 @@ class NERD(datasets.GeneratorBasedBuilder):
77
  datasets.features.ClassLabel(
78
  names=[
79
  'O',
80
- 'I-ART-broadcastprogram',
81
- 'I-ART-film',
82
- 'I-ART-music',
83
- 'I-ART-other',
84
- 'I-ART-painting',
85
- 'I-ART-writtenart',
86
- 'I-BUILDING-airport',
87
- 'I-BUILDING-hospital',
88
- 'I-BUILDING-hotel',
89
- 'I-BUILDING-library',
90
- 'I-BUILDING-other',
91
- 'I-BUILDING-restaurant',
92
- 'I-BUILDING-sportsfacility',
93
- 'I-BUILDING-theater',
94
- 'I-EVENT-attack/battle/war/militaryconflict',
95
- 'I-EVENT-disaster',
96
- 'I-EVENT-election',
97
- 'I-EVENT-other',
98
- 'I-EVENT-protest',
99
- 'I-EVENT-sportsevent',
100
- 'I-LOC-GPE',
101
- 'I-LOC-bodiesofwater',
102
- 'I-LOC-island',
103
- 'I-LOC-mountain',
104
- 'I-LOC-other',
105
- 'I-LOC-park',
106
- 'I-LOC-road/railway/highway/transit',
107
- 'I-ORG-company',
108
- 'I-ORG-education',
109
- 'I-ORG-government/governmentagency',
110
- 'I-ORG-media/newspaper',
111
- 'I-ORG-other',
112
- 'I-ORG-politicalparty',
113
- 'I-ORG-religion',
114
- 'I-ORG-showorganization',
115
- 'I-ORG-sportsleague',
116
- 'I-ORG-sportsteam',
117
- 'I-MISC-astronomything',
118
- 'I-MISC-award',
119
- 'I-MISC-biologything',
120
- 'I-MISC-chemicalthing',
121
- 'I-MISC-currency',
122
- 'I-MISC-disease',
123
- 'I-MISC-educationaldegree',
124
- 'I-MISC-god',
125
- 'I-MISC-language',
126
- 'I-MISC-law',
127
- 'I-MISC-livingthing',
128
- 'I-MISC-medical',
129
- 'I-PER-actor',
130
- 'I-PER-artist/author',
131
- 'I-PER-athlete',
132
- 'I-PER-director',
133
- 'I-PER-other',
134
- 'I-PER-politician',
135
- 'I-PER-scholar',
136
- 'I-PER-soldier',
137
- 'I-PRODUCT-airplane',
138
- 'I-PRODUCT-car',
139
- 'I-PRODUCT-food',
140
- 'I-PRODUCT-game',
141
- 'I-PRODUCT-other',
142
- 'I-PRODUCT-ship',
143
- 'I-PRODUCT-software',
144
- 'I-PRODUCT-train',
145
- 'I-PRODUCT-weapon'
146
  ]
147
  )
148
  ),
@@ -180,7 +180,7 @@ class NERD(datasets.GeneratorBasedBuilder):
180
  ner_tags_fine = []
181
 
182
  for line in lines:
183
- if line.startswith("-DOCSTART-") or line.strip() == "" or line == "\n":
184
  if tokens:
185
  yield guid, {
186
  "id": str(guid),
 
77
  datasets.features.ClassLabel(
78
  names=[
79
  'O',
80
+ 'I-ART_broadcastprogram',
81
+ 'I-ART_film',
82
+ 'I-ART_music',
83
+ 'I-ART_other',
84
+ 'I-ART_painting',
85
+ 'I-ART_writtenart',
86
+ 'I-BUILDING_airport',
87
+ 'I-BUILDING_hospital',
88
+ 'I-BUILDING_hotel',
89
+ 'I-BUILDING_library',
90
+ 'I-BUILDING_other',
91
+ 'I-BUILDING_restaurant',
92
+ 'I-BUILDING_sportsfacility',
93
+ 'I-BUILDING_theater',
94
+ 'I-EVENT_attack/battle/war/militaryconflict',
95
+ 'I-EVENT_disaster',
96
+ 'I-EVENT_election',
97
+ 'I-EVENT_other',
98
+ 'I-EVENT_protest',
99
+ 'I-EVENT_sportsevent',
100
+ 'I-LOC_GPE',
101
+ 'I-LOC_bodiesofwater',
102
+ 'I-LOC_island',
103
+ 'I-LOC_mountain',
104
+ 'I-LOC_other',
105
+ 'I-LOC_park',
106
+ 'I-LOC_road/railway/highway/transit',
107
+ 'I-ORG_company',
108
+ 'I-ORG_education',
109
+ 'I-ORG_government/governmentagency',
110
+ 'I-ORG_media/newspaper',
111
+ 'I-ORG_other',
112
+ 'I-ORG_politicalparty',
113
+ 'I-ORG_religion',
114
+ 'I-ORG_showorganization',
115
+ 'I-ORG_sportsleague',
116
+ 'I-ORG_sportsteam',
117
+ 'I-MISC_astronomything',
118
+ 'I-MISC_award',
119
+ 'I-MISC_biologything',
120
+ 'I-MISC_chemicalthing',
121
+ 'I-MISC_currency',
122
+ 'I-MISC_disease',
123
+ 'I-MISC_educationaldegree',
124
+ 'I-MISC_god',
125
+ 'I-MISC_language',
126
+ 'I-MISC_law',
127
+ 'I-MISC_livingthing',
128
+ 'I-MISC_medical',
129
+ 'I-PER_actor',
130
+ 'I-PER_artist/author',
131
+ 'I-PER_athlete',
132
+ 'I-PER_director',
133
+ 'I-PER_other',
134
+ 'I-PER_politician',
135
+ 'I-PER_scholar',
136
+ 'I-PER_soldier',
137
+ 'I-PRODUCT_airplane',
138
+ 'I-PRODUCT_car',
139
+ 'I-PRODUCT_food',
140
+ 'I-PRODUCT_game',
141
+ 'I-PRODUCT_other',
142
+ 'I-PRODUCT_ship',
143
+ 'I-PRODUCT_software',
144
+ 'I-PRODUCT_train',
145
+ 'I-PRODUCT_weapon'
146
  ]
147
  )
148
  ),
 
180
  ner_tags_fine = []
181
 
182
  for line in lines:
183
+ if line.startswith("-DOCSTART_") or line.strip() == "" or line == "\n":
184
  if tokens:
185
  yield guid, {
186
  "id": str(guid),
test.txt CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:21cf6a9c4fc2e1ac0ba8489c85eaa1d041f8a6361c29e08c49bcd583c511ef2d
3
  size 12476547
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a5b8851b34b6e9b0f588553de16dd1b6ef229478fa53a1bba0011eb074bc2aee
3
  size 12476547
train.txt CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:fc9919a3888e99e2aac82492d5b68e9558ffb50ad3189937f0498014cf489ff3
3
  size 43745611
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:52e642354371a67d4fa515b4a54363d433f1c0b0deb52af3ede52f0a8ec5f4f6
3
  size 43745611
validation.txt CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:b82191955d865685eb24175af4458008d14b6c6c10a1c98ed417a2334885deea
3
  size 6269291
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:56e6d8396492cad0a215bc29c51ee9d6179520ae3eea46a87449242cea900f65
3
  size 6269291