mirror of
https://github.com/explosion/spaCy.git
synced 2025-01-13 02:36:32 +03:00
Fix problems caused by merge conflict
This commit is contained in:
parent
947dba7141
commit
d17e7dca9e
|
@ -313,7 +313,7 @@ class Scorer(object):
|
||||||
cand_deps_per_dep[token.dep_.lower()].add(
|
cand_deps_per_dep[token.dep_.lower()].add(
|
||||||
(gold_i, gold_head, token.dep_.lower())
|
(gold_i, gold_head, token.dep_.lower())
|
||||||
)
|
)
|
||||||
if "-" not in [token[-1] for token in gold.orig_annot]:
|
if "-" not in [token[-1] for token in orig.entities]:
|
||||||
# Find all NER labels in gold and doc
|
# Find all NER labels in gold and doc
|
||||||
ent_labels = set([x[0] for x in gold_ents] + [k.label_ for k in doc.ents])
|
ent_labels = set([x[0] for x in gold_ents] + [k.label_ for k in doc.ents])
|
||||||
# Set up all labels for per type scoring and prepare gold per type
|
# Set up all labels for per type scoring and prepare gold per type
|
||||||
|
|
|
@ -116,10 +116,10 @@ cdef class Tokenizer:
|
||||||
def __set__(self, rules):
|
def __set__(self, rules):
|
||||||
self._rules = {}
|
self._rules = {}
|
||||||
self._reset_cache([key for key in self._cache])
|
self._reset_cache([key for key in self._cache])
|
||||||
self._reset_specials()
|
self._flush_specials()
|
||||||
self._cache = PreshMap()
|
self._cache = PreshMap()
|
||||||
self._specials = PreshMap()
|
self._specials = PreshMap()
|
||||||
self._load_special_tokenization(rules)
|
self._load_special_cases(rules)
|
||||||
|
|
||||||
def __reduce__(self):
|
def __reduce__(self):
|
||||||
args = (self.vocab,
|
args = (self.vocab,
|
||||||
|
|
Loading…
Reference in New Issue
Block a user