Update model after optimising it instead of waiting
@@ -391,6 +391,7 @@ class Language(object):
for name, proc in pipes:
if not hasattr(proc, 'update'):
continue
+ grads = {}
proc.update(docs, golds, drop=drop, sgd=get_grads, losses=losses)
for key, (W, dW) in grads.items():
sgd(W, dW, key=key)
