bjelkenhed
commited on
Commit
·
4924311
1
Parent(s):
a8b178b
change to HF download links
Browse files- babelbox_voice.py +9 -3
babelbox_voice.py
CHANGED
@@ -23,6 +23,11 @@ _CITATION = """\
|
|
23 |
}
|
24 |
"""
|
25 |
|
|
|
|
|
|
|
|
|
|
|
26 |
class BabelboxVoiceConfig(datasets.BuilderConfig):
|
27 |
"""BuilderConfig for BabelboxVoice."""
|
28 |
|
@@ -83,10 +88,10 @@ class BabelboxVoice(datasets.GeneratorBasedBuilder):
|
|
83 |
|
84 |
def _split_generators(self, dl_manager: datasets.DownloadManager) -> List[datasets.SplitGenerator]:
|
85 |
|
86 |
-
archive_dir="/home/jovyan/shared-data/data/nst/archive"
|
87 |
-
archive_files = sorted(glob.glob(archive_dir + '/**.tar.gz'), reverse=False)
|
88 |
|
89 |
-
archive_paths = dl_manager.download(
|
90 |
|
91 |
local_extracted_archive_paths = dl_manager.extract(archive_paths) if not dl_manager.is_streaming else {}
|
92 |
|
@@ -117,6 +122,7 @@ class BabelboxVoice(datasets.GeneratorBasedBuilder):
|
|
117 |
|
118 |
for i, audio_archive in enumerate(archives):
|
119 |
for path, file in audio_archive:
|
|
|
120 |
if local_extracted_archive_paths == False:
|
121 |
path = os.path.join(local_extracted_archive_paths[i], path)
|
122 |
result = dict()
|
|
|
23 |
}
|
24 |
"""
|
25 |
|
26 |
+
_DL_URLS = [
|
27 |
+
"https://huggingface.co/datasets/babelbox/babelbox_voice/resolve/main/archive/nst/nst-data-001.tar.gz",
|
28 |
+
"https://huggingface.co/datasets/babelbox/babelbox_voice/resolve/main/archive/nst/nst-data-002.tar.gz"
|
29 |
+
]
|
30 |
+
|
31 |
class BabelboxVoiceConfig(datasets.BuilderConfig):
|
32 |
"""BuilderConfig for BabelboxVoice."""
|
33 |
|
|
|
88 |
|
89 |
def _split_generators(self, dl_manager: datasets.DownloadManager) -> List[datasets.SplitGenerator]:
|
90 |
|
91 |
+
#archive_dir="/home/jovyan/shared-data/data/nst/archive"
|
92 |
+
#archive_files = sorted(glob.glob(archive_dir + '/**.tar.gz'), reverse=False)
|
93 |
|
94 |
+
archive_paths = dl_manager.download(_DL_URLS)
|
95 |
|
96 |
local_extracted_archive_paths = dl_manager.extract(archive_paths) if not dl_manager.is_streaming else {}
|
97 |
|
|
|
122 |
|
123 |
for i, audio_archive in enumerate(archives):
|
124 |
for path, file in audio_archive:
|
125 |
+
print(path)
|
126 |
if local_extracted_archive_paths == False:
|
127 |
path = os.path.join(local_extracted_archive_paths[i], path)
|
128 |
result = dict()
|