Commit
·
bdce9e1
1
Parent(s):
f88118e
Update librispeech_asr.py
Browse files- librispeech_asr.py +9 -9
librispeech_asr.py
CHANGED
|
@@ -45,13 +45,13 @@ _DL_URL = "http://www.openslr.org/resources/12/"
|
|
| 45 |
|
| 46 |
|
| 47 |
_DL_URLS = {
|
| 48 |
-
"dev.clean":
|
| 49 |
-
"test.clean":
|
| 50 |
-
"train.clean.100":
|
| 51 |
-
"train.clean.360":
|
| 52 |
-
"test.other":
|
| 53 |
-
"dev.other":
|
| 54 |
-
"train.other.500":
|
| 55 |
}
|
| 56 |
|
| 57 |
|
|
@@ -105,7 +105,7 @@ class LibrispeechASR(datasets.GeneratorBasedBuilder):
|
|
| 105 |
)
|
| 106 |
|
| 107 |
def _split_generators(self, dl_manager):
|
| 108 |
-
archive_path = dl_manager.download(_DL_URLS[self.config.name])
|
| 109 |
# (Optional) In non-streaming mode, we can extract the archive locally to have actual local audio files:
|
| 110 |
local_extracted_archive = dl_manager.extract(archive_path) if not dl_manager.is_streaming else {}
|
| 111 |
|
|
@@ -114,7 +114,7 @@ class LibrispeechASR(datasets.GeneratorBasedBuilder):
|
|
| 114 |
name=self.config.name,
|
| 115 |
gen_kwargs={
|
| 116 |
"local_extracted_archive": local_extracted_archive,
|
| 117 |
-
"files": dl_manager.iter_archive(self.config.name),
|
| 118 |
},
|
| 119 |
),
|
| 120 |
]
|
|
|
|
| 45 |
|
| 46 |
|
| 47 |
_DL_URLS = {
|
| 48 |
+
"dev.clean": "dev-clean.tar.gz",
|
| 49 |
+
"test.clean": "test-clean.tar.gz",
|
| 50 |
+
"train.clean.100": "train-clean-100.tar.gz",
|
| 51 |
+
"train.clean.360": "train-clean-360.tar.gz",
|
| 52 |
+
"test.other": "test-other.tar.gz",
|
| 53 |
+
"dev.other": "dev-other.tar.gz",
|
| 54 |
+
"train.other.500": "train-other-500.tar.gz",
|
| 55 |
}
|
| 56 |
|
| 57 |
|
|
|
|
| 105 |
)
|
| 106 |
|
| 107 |
def _split_generators(self, dl_manager):
|
| 108 |
+
archive_path = dl_manager.download(_DL_URL + _DL_URLS[self.config.name])
|
| 109 |
# (Optional) In non-streaming mode, we can extract the archive locally to have actual local audio files:
|
| 110 |
local_extracted_archive = dl_manager.extract(archive_path) if not dl_manager.is_streaming else {}
|
| 111 |
|
|
|
|
| 114 |
name=self.config.name,
|
| 115 |
gen_kwargs={
|
| 116 |
"local_extracted_archive": local_extracted_archive,
|
| 117 |
+
"files": dl_manager.iter_archive(_DL_URLS[self.config.name]),
|
| 118 |
},
|
| 119 |
),
|
| 120 |
]
|