mirror of https://github.com/explosion/spaCy.git
* Add deprecation warning for unused load_vectors argument.
This commit is contained in:
parent
0b527fbdc8
commit
d9f1fc2112
|
@ -1,4 +1,5 @@
|
||||||
from os import path
|
from os import path
|
||||||
|
from warnings import warn
|
||||||
|
|
||||||
try:
|
try:
|
||||||
import ujson as json
|
import ujson as json
|
||||||
|
@ -184,7 +185,10 @@ class Language(object):
|
||||||
return None
|
return None
|
||||||
|
|
||||||
def __init__(self, data_dir=None, vocab=None, tokenizer=None, tagger=None,
|
def __init__(self, data_dir=None, vocab=None, tokenizer=None, tagger=None,
|
||||||
parser=None, entity=None, matcher=None, serializer=None):
|
parser=None, entity=None, matcher=None, serializer=None,
|
||||||
|
load_vectors=True):
|
||||||
|
if load_vectors is not True:
|
||||||
|
warn("load_vectors is deprecated", DeprecationWarning)
|
||||||
if data_dir is None:
|
if data_dir is None:
|
||||||
data_dir = self.default_data_dir()
|
data_dir = self.default_data_dir()
|
||||||
if vocab is None:
|
if vocab is None:
|
||||||
|
|
Loading…
Reference in New Issue