Datasets:
Convert dataset to Parquet
#1
by
carlosdanielhernandezmena
- opened
README.md
CHANGED
@@ -1,28 +1,59 @@
|
|
1 |
---
|
2 |
annotations_creators:
|
3 |
- expert-generated
|
4 |
-
language:
|
5 |
-
- es
|
6 |
language_creators:
|
7 |
- other
|
|
|
|
|
8 |
license:
|
9 |
- cc-by-sa-4.0
|
10 |
multilinguality:
|
11 |
- monolingual
|
12 |
-
pretty_name: 'CIEMPIESS FEM CORPUS: Audio and Transcripts of Female Speakers in Spanish.'
|
13 |
size_categories:
|
14 |
- 10K<n<100K
|
15 |
source_datasets:
|
16 |
- original
|
|
|
|
|
|
|
|
|
17 |
tags:
|
18 |
- ciempiess
|
19 |
- spanish
|
20 |
- mexican spanish
|
21 |
- ciempiess project
|
22 |
- ciempiess-unam project
|
23 |
-
|
24 |
-
|
25 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
26 |
---
|
27 |
|
28 |
# Dataset Card for ciempiess_fem
|
|
|
1 |
---
|
2 |
annotations_creators:
|
3 |
- expert-generated
|
|
|
|
|
4 |
language_creators:
|
5 |
- other
|
6 |
+
language:
|
7 |
+
- es
|
8 |
license:
|
9 |
- cc-by-sa-4.0
|
10 |
multilinguality:
|
11 |
- monolingual
|
|
|
12 |
size_categories:
|
13 |
- 10K<n<100K
|
14 |
source_datasets:
|
15 |
- original
|
16 |
+
task_categories:
|
17 |
+
- automatic-speech-recognition
|
18 |
+
task_ids: []
|
19 |
+
pretty_name: 'CIEMPIESS FEM CORPUS: Audio and Transcripts of Female Speakers in Spanish.'
|
20 |
tags:
|
21 |
- ciempiess
|
22 |
- spanish
|
23 |
- mexican spanish
|
24 |
- ciempiess project
|
25 |
- ciempiess-unam project
|
26 |
+
dataset_info:
|
27 |
+
config_name: ciempiess_fem
|
28 |
+
features:
|
29 |
+
- name: audio_id
|
30 |
+
dtype: string
|
31 |
+
- name: audio
|
32 |
+
dtype:
|
33 |
+
audio:
|
34 |
+
sampling_rate: 16000
|
35 |
+
- name: speaker_id
|
36 |
+
dtype: string
|
37 |
+
- name: gender
|
38 |
+
dtype: string
|
39 |
+
- name: duration
|
40 |
+
dtype: float32
|
41 |
+
- name: country
|
42 |
+
dtype: string
|
43 |
+
- name: normalized_text
|
44 |
+
dtype: string
|
45 |
+
splits:
|
46 |
+
- name: train
|
47 |
+
num_bytes: 781435185.285
|
48 |
+
num_examples: 6505
|
49 |
+
download_size: 958145084
|
50 |
+
dataset_size: 781435185.285
|
51 |
+
configs:
|
52 |
+
- config_name: ciempiess_fem
|
53 |
+
data_files:
|
54 |
+
- split: train
|
55 |
+
path: ciempiess_fem/train-*
|
56 |
+
default: true
|
57 |
---
|
58 |
|
59 |
# Dataset Card for ciempiess_fem
|
ciempiess_fem.py
DELETED
@@ -1,124 +0,0 @@
|
|
1 |
-
from collections import defaultdict
|
2 |
-
import os
|
3 |
-
import json
|
4 |
-
import csv
|
5 |
-
|
6 |
-
import datasets
|
7 |
-
|
8 |
-
_NAME="ciempiess_fem"
|
9 |
-
_VERSION="1.0.0"
|
10 |
-
_AUDIO_EXTENSIONS=".flac"
|
11 |
-
|
12 |
-
_DESCRIPTION = """
|
13 |
-
The CIEMPIESS FEM Corpus was created by recordings and human transcripts of 21 different women. 16 of these women are mexican. The other ones come from Latin American countries.
|
14 |
-
"""
|
15 |
-
|
16 |
-
_CITATION = """
|
17 |
-
@misc{carlosmenaciempiessfem2019,
|
18 |
-
title={CIEMPIESS FEM CORPUS: Audio and Transcripts of Female Speakers in Spanish.},
|
19 |
-
ldc_catalog_no={LDC2019S07},
|
20 |
-
DOI={https://doi.org/10.35111/xdx5-n815},
|
21 |
-
author={Hernandez Mena, Carlos Daniel},
|
22 |
-
journal={Linguistic Data Consortium, Philadelphia},
|
23 |
-
year={2019},
|
24 |
-
url={https://catalog.ldc.upenn.edu/LDC2019S07},
|
25 |
-
}
|
26 |
-
"""
|
27 |
-
|
28 |
-
_HOMEPAGE = "https://catalog.ldc.upenn.edu/LDC2019S07"
|
29 |
-
|
30 |
-
_LICENSE = "CC-BY-SA-4.0, See https://creativecommons.org/licenses/by-sa/4.0/"
|
31 |
-
|
32 |
-
_BASE_DATA_DIR = "corpus/"
|
33 |
-
_METADATA_TRAIN = os.path.join(_BASE_DATA_DIR,"files", "metadata_train.tsv")
|
34 |
-
|
35 |
-
_TARS_TRAIN = os.path.join(_BASE_DATA_DIR,"files", "tars_train.paths")
|
36 |
-
|
37 |
-
class CiempiessFemConfig(datasets.BuilderConfig):
|
38 |
-
"""BuilderConfig for CIEMPIESS FEM Corpus"""
|
39 |
-
|
40 |
-
def __init__(self, name, **kwargs):
|
41 |
-
name=_NAME
|
42 |
-
super().__init__(name=name, **kwargs)
|
43 |
-
|
44 |
-
class CiempiessFem(datasets.GeneratorBasedBuilder):
|
45 |
-
"""CIEMPIESS Fem Corpus"""
|
46 |
-
|
47 |
-
VERSION = datasets.Version(_VERSION)
|
48 |
-
BUILDER_CONFIGS = [
|
49 |
-
CiempiessFemConfig(
|
50 |
-
name=_NAME,
|
51 |
-
version=datasets.Version(_VERSION),
|
52 |
-
)
|
53 |
-
]
|
54 |
-
|
55 |
-
def _info(self):
|
56 |
-
features = datasets.Features(
|
57 |
-
{
|
58 |
-
"audio_id": datasets.Value("string"),
|
59 |
-
"audio": datasets.Audio(sampling_rate=16000),
|
60 |
-
"speaker_id": datasets.Value("string"),
|
61 |
-
"gender": datasets.Value("string"),
|
62 |
-
"duration": datasets.Value("float32"),
|
63 |
-
"country": datasets.Value("string"),
|
64 |
-
"normalized_text": datasets.Value("string"),
|
65 |
-
}
|
66 |
-
)
|
67 |
-
return datasets.DatasetInfo(
|
68 |
-
description=_DESCRIPTION,
|
69 |
-
features=features,
|
70 |
-
homepage=_HOMEPAGE,
|
71 |
-
license=_LICENSE,
|
72 |
-
citation=_CITATION,
|
73 |
-
)
|
74 |
-
|
75 |
-
def _split_generators(self, dl_manager):
|
76 |
-
|
77 |
-
metadata_train=dl_manager.download_and_extract(_METADATA_TRAIN)
|
78 |
-
|
79 |
-
tars_train=dl_manager.download_and_extract(_TARS_TRAIN)
|
80 |
-
|
81 |
-
hash_tar_files=defaultdict(dict)
|
82 |
-
|
83 |
-
with open(tars_train,'r') as f:
|
84 |
-
hash_tar_files['train']=[path.replace('\n','') for path in f]
|
85 |
-
|
86 |
-
hash_meta_paths={"train":metadata_train}
|
87 |
-
audio_paths = dl_manager.download(hash_tar_files)
|
88 |
-
|
89 |
-
splits=["train"]
|
90 |
-
local_extracted_audio_paths = (
|
91 |
-
dl_manager.extract(audio_paths) if not dl_manager.is_streaming else
|
92 |
-
{
|
93 |
-
split:[None] * len(audio_paths[split]) for split in splits
|
94 |
-
}
|
95 |
-
)
|
96 |
-
|
97 |
-
return [
|
98 |
-
datasets.SplitGenerator(
|
99 |
-
name=datasets.Split.TRAIN,
|
100 |
-
gen_kwargs={
|
101 |
-
"audio_archives": [dl_manager.iter_archive(archive) for archive in audio_paths["train"]],
|
102 |
-
"local_extracted_archives_paths": local_extracted_audio_paths["train"],
|
103 |
-
"metadata_paths": hash_meta_paths["train"],
|
104 |
-
}
|
105 |
-
),
|
106 |
-
]
|
107 |
-
|
108 |
-
def _generate_examples(self, audio_archives, local_extracted_archives_paths, metadata_paths):
|
109 |
-
|
110 |
-
features = ["speaker_id","gender","duration","country","normalized_text"]
|
111 |
-
|
112 |
-
with open(metadata_paths) as f:
|
113 |
-
metadata = {x["audio_id"]: x for x in csv.DictReader(f, delimiter="\t")}
|
114 |
-
|
115 |
-
for audio_archive, local_extracted_archive_path in zip(audio_archives, local_extracted_archives_paths):
|
116 |
-
for audio_filename, audio_file in audio_archive:
|
117 |
-
audio_id = audio_filename.split(os.sep)[-1].split(_AUDIO_EXTENSIONS)[0]
|
118 |
-
path = os.path.join(local_extracted_archive_path, audio_filename) if local_extracted_archive_path else audio_filename
|
119 |
-
|
120 |
-
yield audio_id, {
|
121 |
-
"audio_id": audio_id,
|
122 |
-
**{feature: metadata[audio_id][feature] for feature in features},
|
123 |
-
"audio": {"path": path, "bytes": audio_file.read()},
|
124 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
corpus/speech/train.tar.gz → ciempiess_fem/train-00000-of-00002.parquet
RENAMED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
-
size
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:3c5583983650b4b9a4546d664bc2fdd5609fcb6b72cb254e16b1c9cc32925216
|
3 |
+
size 464051187
|
ciempiess_fem/train-00001-of-00002.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:877411e4499c212c1364491430b0f6ead821dd69378615521338eb3de949cca0
|
3 |
+
size 494093897
|
corpus/files/metadata_train.tsv
DELETED
The diff for this file is too large to render.
See raw diff
|
|
corpus/files/tars_train.paths
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
corpus/speech/train.tar.gz
|
|
|
|