Update audioset.py
Browse files- audioset.py +2 -2
audioset.py
CHANGED
@@ -14,7 +14,7 @@ from pathlib import Path
|
|
14 |
from huggingface_hub import hf_hub_download
|
15 |
|
16 |
|
17 |
-
SAMPLE_RATE =
|
18 |
|
19 |
_HOMEPAGE = "https://huggingface.co/datasets/confit/audioset"
|
20 |
|
@@ -117,7 +117,7 @@ class AudioSet(datasets.GeneratorBasedBuilder):
|
|
117 |
_walker = fast_scandir(archive_path, extensions, recursive=True)
|
118 |
|
119 |
for guid, audio_path in enumerate(_walker):
|
120 |
-
|
121 |
yield guid, {
|
122 |
"id": str(guid),
|
123 |
"file": audio_path,
|
|
|
14 |
from huggingface_hub import hf_hub_download
|
15 |
|
16 |
|
17 |
+
SAMPLE_RATE = 32_000
|
18 |
|
19 |
_HOMEPAGE = "https://huggingface.co/datasets/confit/audioset"
|
20 |
|
|
|
117 |
_walker = fast_scandir(archive_path, extensions, recursive=True)
|
118 |
|
119 |
for guid, audio_path in enumerate(_walker):
|
120 |
+
assert isinstance(audio_path, str), f'{audio_path} is not string'
|
121 |
yield guid, {
|
122 |
"id": str(guid),
|
123 |
"file": audio_path,
|