mirror of
https://github.com/explosion/spaCy.git
synced 2024-11-14 05:37:03 +03:00
Fixing encoding issue
UTF-8
This commit is contained in:
parent
b8d07f35dd
commit
e4a1726f77
|
@ -19,7 +19,7 @@ class Lemmatizer(object):
|
||||||
index[pos] = read_index(path.join(data_dir, 'wordnet', 'index.%s' % pos))
|
index[pos] = read_index(path.join(data_dir, 'wordnet', 'index.%s' % pos))
|
||||||
exc[pos] = read_exc(path.join(data_dir, 'wordnet', '%s.exc' % pos))
|
exc[pos] = read_exc(path.join(data_dir, 'wordnet', '%s.exc' % pos))
|
||||||
if path.exists(path.join(data_dir, 'vocab', 'lemma_rules.json')):
|
if path.exists(path.join(data_dir, 'vocab', 'lemma_rules.json')):
|
||||||
rules = json.load(open(path.join(data_dir, 'vocab', 'lemma_rules.json')))
|
rules = json.load(open(path.join(data_dir, 'vocab', 'lemma_rules.json')), encoding="UTF-8")
|
||||||
else:
|
else:
|
||||||
rules = {}
|
rules = {}
|
||||||
return cls(index, exc, rules)
|
return cls(index, exc, rules)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user