gabrielaltay
commited on
Commit
·
c2f6702
1
Parent(s):
1a0d6b8
Update an_em.py
Browse files
an_em.py
CHANGED
@@ -30,6 +30,7 @@ from .bigbiohub import kb_features
|
|
30 |
from .bigbiohub import BigBioConfig
|
31 |
from .bigbiohub import Tasks
|
32 |
from .bigbiohub import parse_brat_file
|
|
|
33 |
|
34 |
|
35 |
_LANGUAGES = ['English']
|
@@ -219,7 +220,7 @@ class AnEMDataset(datasets.GeneratorBasedBuilder):
|
|
219 |
if (file.suffix != ".txt") or (file.stem not in split_list):
|
220 |
continue
|
221 |
brat_parsed = parse_brat_file(file)
|
222 |
-
bigbio_kb_example =
|
223 |
|
224 |
bigbio_kb_example["id"] = bigbio_kb_example["document_id"]
|
225 |
|
|
|
30 |
from .bigbiohub import BigBioConfig
|
31 |
from .bigbiohub import Tasks
|
32 |
from .bigbiohub import parse_brat_file
|
33 |
+
from .bigbiohub import brat_parse_to_bigbio_kb
|
34 |
|
35 |
|
36 |
_LANGUAGES = ['English']
|
|
|
220 |
if (file.suffix != ".txt") or (file.stem not in split_list):
|
221 |
continue
|
222 |
brat_parsed = parse_brat_file(file)
|
223 |
+
bigbio_kb_example = brat_parse_to_bigbio_kb(brat_parsed)
|
224 |
|
225 |
bigbio_kb_example["id"] = bigbio_kb_example["document_id"]
|
226 |
|