diff --git a/spacy/cli/train.py b/spacy/cli/train.py index 9b071ed55..7e9ec9ec9 100644 --- a/spacy/cli/train.py +++ b/spacy/cli/train.py @@ -144,6 +144,7 @@ def train( max_steps=T_cfg["max_steps"], eval_frequency=T_cfg["eval_frequency"], raw_text=None, + exclude=frozen_components ) msg.info(f"Training. Initial learn rate: {optimizer.learn_rate}") print_row = setup_printer(T_cfg, nlp) diff --git a/spacy/pipeline/textcat.py b/spacy/pipeline/textcat.py index 639ce5514..bc16e790f 100644 --- a/spacy/pipeline/textcat.py +++ b/spacy/pipeline/textcat.py @@ -355,7 +355,7 @@ class TextCategorizer(Pipe): for cat in y.cats: self.add_label(cat) self.require_labels() - docs = [Doc(Vocab(), words=["hello"])] + docs = [Doc(self.vocab, words=["hello"])] truths, _ = self._examples_to_truth(examples) self.set_output(len(self.labels)) self.model.initialize(X=docs, Y=truths)