KELONMYOSA
commited on
Commit
•
83bcf6c
1
Parent(s):
078cc46
added url
Browse files
dusha.py
CHANGED
@@ -12,8 +12,8 @@ The corpus contains approximately 350 hours of data. Four basic emotions that us
|
|
12 |
|
13 |
_HOMEPAGE = "https://github.com/salute-developers/golos/tree/master/dusha#dusha-dataset"
|
14 |
|
15 |
-
|
16 |
-
|
17 |
|
18 |
|
19 |
class Dusha(datasets.GeneratorBasedBuilder):
|
@@ -34,12 +34,13 @@ class Dusha(datasets.GeneratorBasedBuilder):
|
|
34 |
)
|
35 |
|
36 |
def _split_generators(self, dl_manager):
|
37 |
-
|
|
|
38 |
return [datasets.SplitGenerator(
|
39 |
name=datasets.Split.ALL,
|
40 |
gen_kwargs={
|
41 |
-
"audio_files":
|
42 |
-
"metadata":
|
43 |
)]
|
44 |
|
45 |
def _generate_examples(self, audio_files: Union[str, os.PathLike], metadata: str):
|
|
|
12 |
|
13 |
_HOMEPAGE = "https://github.com/salute-developers/golos/tree/master/dusha#dusha-dataset"
|
14 |
|
15 |
+
_DATA_URL = "https://huggingface.co/datasets/KELONMYOSA/dusha_emotion_audio/resolve/main/data.zip"
|
16 |
+
_METADATA_URL = "https://huggingface.co/datasets/KELONMYOSA/dusha_emotion_audio/resolve/main/metadata.csv"
|
17 |
|
18 |
|
19 |
class Dusha(datasets.GeneratorBasedBuilder):
|
|
|
34 |
)
|
35 |
|
36 |
def _split_generators(self, dl_manager):
|
37 |
+
metadata = dl_manager.download(_METADATA_URL)
|
38 |
+
archive = dl_manager.download(_DATA_URL)
|
39 |
return [datasets.SplitGenerator(
|
40 |
name=datasets.Split.ALL,
|
41 |
gen_kwargs={
|
42 |
+
"audio_files": metadata,
|
43 |
+
"metadata": dl_manager.iter_archive(archive)},
|
44 |
)]
|
45 |
|
46 |
def _generate_examples(self, audio_files: Union[str, os.PathLike], metadata: str):
|