From 95fc0176d1fdd2fc636ffc15b6d11fbcabbf0a78 Mon Sep 17 00:00:00 2001 From: Matthew Honnibal Date: Mon, 17 Dec 2018 23:08:31 +0000 Subject: [PATCH] Pass tagger options in begin_training --- spacy/pipeline.pyx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/spacy/pipeline.pyx b/spacy/pipeline.pyx index ad646f25f..81cf1ea69 100644 --- a/spacy/pipeline.pyx +++ b/spacy/pipeline.pyx @@ -711,6 +711,9 @@ class Tagger(Pipe): exc=vocab.morphology.exc) self.cfg['pretrained_vectors'] = kwargs.get('pretrained_vectors') if self.model is True: + for hp in ['token_vector_width', 'conv_depth']: + if hp in kwargs: + self.cfg[hp] = kwargs[hp] self.model = self.Model(self.vocab.morphology.n_tags, **self.cfg) link_vectors_to_models(self.vocab) if sgd is None: