Merge pull request #1428 from roanuz/develop

Fix trailing whitespace and Language.from_disk overwrites
This commit is contained in:
Ines Montani 2017-10-17 16:29:15 +02:00 committed by GitHub
commit afa67de7ee
2 changed files with 64 additions and 64 deletions

View File

@ -594,7 +594,7 @@ class Language(object):
deserializers = OrderedDict((
('vocab', lambda p: self.vocab.from_disk(p)),
('tokenizer', lambda p: self.tokenizer.from_disk(p, vocab=False)),
('meta.json', lambda p: p.open('w').write(json_dumps(self.meta)))
('meta.json', lambda p: self.meta.update(ujson.load(p.open('r'))))
))
for name, proc in self.pipeline:
if name in disable: