This commit is contained in:
Raphael Mitsch 2023-04-24 21:25:48 +02:00
parent 638103eb1b
commit 2c80db9371

View File

@ -443,7 +443,9 @@ class EntityLinker(TrainablePipe):
(
SpanGroup(
doc,
spans=[ent for ent in doc.ents if ent.label_ not in self.labels_discard],
spans=[
ent for ent in doc.ents if ent.label_ not in self.labels_discard
],
)
for doc in docs
if len(doc) and len(doc.ents)