mirror of
https://github.com/explosion/spaCy.git
synced 2024-12-24 17:06:29 +03:00
Fix lightning tour example (closes #889)
This commit is contained in:
parent
e7ae3b7cc2
commit
c6c3162c50
|
@ -137,7 +137,7 @@ p
|
|||
return word.ent_type != 0
|
||||
|
||||
def count_parent_verb_by_person(docs):
|
||||
counts = defaultdict(defaultdict(int))
|
||||
counts = defaultdict(lambda: defaultdict(int))
|
||||
for doc in docs:
|
||||
for ent in doc.ents:
|
||||
if ent.label_ == 'PERSON' and ent.root.head.pos == VERB:
|
||||
|
|
Loading…
Reference in New Issue
Block a user