tobiolatunji
commited on
fix absent splits
Browse files- afrispeech-200.py +2 -1
afrispeech-200.py
CHANGED
@@ -188,7 +188,7 @@ class AfriSpeech(datasets.GeneratorBasedBuilder):
|
|
188 |
continue
|
189 |
for i in range(ACCENT_STATS[accent][split]['shards']):
|
190 |
audio_urls[split].append(_AUDIO_URL.format(accent=accent, split=split, shard_idx=i))
|
191 |
-
|
192 |
audio_urls[split] = [
|
193 |
_AUDIO_URL.format(accent=accent, split=split,
|
194 |
shard_idx=i) for i in range(ACCENT_STATS[accent][split]['shards'])
|
@@ -211,6 +211,7 @@ class AfriSpeech(datasets.GeneratorBasedBuilder):
|
|
211 |
"dev": datasets.Split.VALIDATION,
|
212 |
# "test": datasets.Split.TEST,
|
213 |
}
|
|
|
214 |
for split in splits:
|
215 |
if split in ACCENT_STATS[self.config.name]:
|
216 |
split_generators.append(
|
|
|
188 |
continue
|
189 |
for i in range(ACCENT_STATS[accent][split]['shards']):
|
190 |
audio_urls[split].append(_AUDIO_URL.format(accent=accent, split=split, shard_idx=i))
|
191 |
+
elif split in ACCENT_STATS[accent]:
|
192 |
audio_urls[split] = [
|
193 |
_AUDIO_URL.format(accent=accent, split=split,
|
194 |
shard_idx=i) for i in range(ACCENT_STATS[accent][split]['shards'])
|
|
|
211 |
"dev": datasets.Split.VALIDATION,
|
212 |
# "test": datasets.Split.TEST,
|
213 |
}
|
214 |
+
|
215 |
for split in splits:
|
216 |
if split in ACCENT_STATS[self.config.name]:
|
217 |
split_generators.append(
|