mirror of
https://github.com/explosion/spaCy.git
synced 2024-11-13 05:07:03 +03:00
Fix json dump for Python3
This commit is contained in:
parent
040751ad17
commit
4d2a659c52
|
@ -195,7 +195,7 @@ class Language(object):
|
||||||
if directory.exists():
|
if directory.exists():
|
||||||
shutil.rmtree(str(directory))
|
shutil.rmtree(str(directory))
|
||||||
directory.mkdir()
|
directory.mkdir()
|
||||||
with (directory / 'config.json').open('wb') as file_:
|
with (directory / 'config.json').open('w') as file_:
|
||||||
data = json_dumps(config)
|
data = json_dumps(config)
|
||||||
file_.write(data)
|
file_.write(data)
|
||||||
if not (path / 'vocab').exists():
|
if not (path / 'vocab').exists():
|
||||||
|
|
Loading…
Reference in New Issue
Block a user