Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions torchaudio/datasets/commonvoice.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,15 @@ def __init__(self,
"romansh sursilvan": "rm-sursilv"
}

if download:
raise RuntimeError(
"Common Voice dataset requires user agreement on the usage term, "
"and torchaudio no longer provides the download feature. "
"Please download the dataset manually and extract it in the root directory, "
"then provide the target language to `url` argument.")
if url not in languages:
raise ValueError(f"`url` must be one of available languages: {languages.keys()}")

if url in languages:
ext_archive = ".tar.gz"
language = languages[url]
Expand Down