Make the sacremoses dependency optional (#17049)

* Make sacremoses optional

* Pickle
This commit is contained in:
Lysandre Debut
2022-05-02 13:47:47 -03:00
committed by GitHub
parent bb2e088be7
commit 30ca529902
4 changed files with 63 additions and 12 deletions

View File

@@ -288,6 +288,7 @@ extras["testing"] = (
"nltk",
"GitPython",
"hf-doc-builder",
'sacremoses'
)
+ extras["retrieval"]
+ extras["modelcreation"]
@@ -365,7 +366,6 @@ extras["torchhub"] = deps_list(
"protobuf",
"regex",
"requests",
"sacremoses",
"sentencepiece",
"torch",
"tokenizers",
@@ -383,7 +383,6 @@ install_requires = [
deps["pyyaml"], # used for the model cards metadata
deps["regex"], # for OpenAI GPT
deps["requests"], # for downloading models over HTTPS
deps["sacremoses"], # for XLM
deps["tokenizers"],
deps["tqdm"], # progress bars in model download and training scripts
]