Fix refreshing Morphology class

This commit is contained in:
Matthew Honnibal 2018-02-26 09:35:34 +01:00
parent 7f832f1b88
commit 0fb153cf05

View File

@ -521,7 +521,7 @@ class Tagger(Pipe):
if values is None: if values is None:
values = {POS: "X"} values = {POS: "X"}
tag_map[label] = values tag_map[label] = values
morph_feats = Morphology._morph2features morph_feats = self.vocab.morphology._morph2features
self.vocab.morphology = Morphology( self.vocab.morphology = Morphology(
self.vocab.strings, tag_map=tag_map, self.vocab.strings, tag_map=tag_map,
lemmatizer=self.vocab.morphology.lemmatizer, lemmatizer=self.vocab.morphology.lemmatizer,