Clarifying error message

This commit is contained in:
Alex Petenchea 2023-08-22 20:18:30 +03:00 committed by GitHub
parent deb7dfca4b
commit e567fabc62
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -964,7 +964,7 @@ def load_vocab(path: Path, vocabtype: Optional[str]) -> Union[BpeVocab, Sentence
path = path3
else:
raise FileNotFoundError(
f"Could not find tokenizer.model in {path} or its parent; "
f"Could not find {vocab_file} in {path} or its parent; "
"if it's in another directory, pass the directory as --vocab-dir")
print(f"Loading vocab file '{path}', type '{vocabtype}'")