mirror of https://github.com/explosion/spaCy.git
* Fix parser, which was importing the wrong model
This commit is contained in:
parent
33bf76db63
commit
9a21127bf7
|
@ -1,4 +1,4 @@
|
||||||
from .._ml cimport Model, HastyModel
|
from .._ml cimport Model
|
||||||
|
|
||||||
from .arc_eager cimport TransitionSystem
|
from .arc_eager cimport TransitionSystem
|
||||||
|
|
||||||
|
|
|
@ -63,7 +63,7 @@ cdef class GreedyParser:
|
||||||
self.cfg = Config.read(model_dir, 'config')
|
self.cfg = Config.read(model_dir, 'config')
|
||||||
self.moves = TransitionSystem(self.cfg.left_labels, self.cfg.right_labels)
|
self.moves = TransitionSystem(self.cfg.left_labels, self.cfg.right_labels)
|
||||||
hasty_templ, full_templ = get_templates(self.cfg.features)
|
hasty_templ, full_templ = get_templates(self.cfg.features)
|
||||||
self.model = HastyModel(self.moves.n_moves, hasty_templ, full_templ,
|
self.model = Model(self.moves.n_moves, hasty_templ, full_templ,
|
||||||
model_dir)
|
model_dir)
|
||||||
|
|
||||||
cpdef int parse(self, Tokens tokens) except -1:
|
cpdef int parse(self, Tokens tokens) except -1:
|
||||||
|
|
Loading…
Reference in New Issue