forked from KEMT/zpwiki
Nahrát soubory do „pages/students/2016/jakub_maruniak/dp2021/annotation“
This commit is contained in:
parent
db47f300c8
commit
037c3bfaa5
@ -0,0 +1,14 @@
|
||||
# load data
|
||||
filename = 'ner/annotations.jsonl'
|
||||
file = open(filename, 'rt', encoding='utf-8')
|
||||
text = file.read()
|
||||
|
||||
# count entity PER
|
||||
countPER = text.count('PER')
|
||||
countLOC = text.count('LOC')
|
||||
countORG = text.count('ORG')
|
||||
countMISC = text.count('MISC')
|
||||
print('Počet anotovaných entít typu PER:', countPER,'\n',
|
||||
'Počet anotovaných entít typu LOC:', countLOC,'\n',
|
||||
'Počet anotovaných entít typu ORG:', countORG,'\n',
|
||||
'Počet anotovaných entít typu MISC:', countMISC,'\n')
|
Loading…
Reference in New Issue
Block a user