system HF staff commited on
Commit
1033f60
0 Parent(s):

Update files from the datasets library (from 1.18.0)

Browse files

Release notes: https://github.com/huggingface/datasets/releases/tag/1.18.0

Files changed (5) hide show
  1. .gitattributes +27 -0
  2. README.md +183 -0
  3. dataset_infos.json +1 -0
  4. dummy/main/0.9.2/dummy_data.zip +3 -0
  5. vctk.py +133 -0
.gitattributes ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.bin filter=lfs diff=lfs merge=lfs -text
4
+ *.bin.* filter=lfs diff=lfs merge=lfs -text
5
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
6
+ *.ftz filter=lfs diff=lfs merge=lfs -text
7
+ *.gz filter=lfs diff=lfs merge=lfs -text
8
+ *.h5 filter=lfs diff=lfs merge=lfs -text
9
+ *.joblib filter=lfs diff=lfs merge=lfs -text
10
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
11
+ *.model filter=lfs diff=lfs merge=lfs -text
12
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
13
+ *.onnx filter=lfs diff=lfs merge=lfs -text
14
+ *.ot filter=lfs diff=lfs merge=lfs -text
15
+ *.parquet filter=lfs diff=lfs merge=lfs -text
16
+ *.pb filter=lfs diff=lfs merge=lfs -text
17
+ *.pt filter=lfs diff=lfs merge=lfs -text
18
+ *.pth filter=lfs diff=lfs merge=lfs -text
19
+ *.rar filter=lfs diff=lfs merge=lfs -text
20
+ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
21
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
22
+ *.tflite filter=lfs diff=lfs merge=lfs -text
23
+ *.tgz filter=lfs diff=lfs merge=lfs -text
24
+ *.xz filter=lfs diff=lfs merge=lfs -text
25
+ *.zip filter=lfs diff=lfs merge=lfs -text
26
+ *.zstandard filter=lfs diff=lfs merge=lfs -text
27
+ *tfevents* filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,183 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ annotations_creators:
3
+ - expert-generated
4
+ language_creators:
5
+ - crowdsourced
6
+ languages:
7
+ - en
8
+ licenses:
9
+ - cc-by-4-0
10
+ multilinguality:
11
+ - monolingual
12
+ pretty_name: VCTK
13
+ size_categories:
14
+ - 10K<n<100K
15
+ source_datasets:
16
+ - original
17
+ task_categories:
18
+ - speech-processing
19
+ task_ids:
20
+ - automatic-speech-recognition
21
+ paperswithcode_id: vctk
22
+ ---
23
+
24
+ # Dataset Card for VCTK
25
+
26
+ ## Table of Contents
27
+ - [Dataset Description](#dataset-description)
28
+ - [Dataset Summary](#dataset-summary)
29
+ - [Supported Tasks and Leaderboards](#supported-tasks-and-leaderboards)
30
+ - [Languages](#languages)
31
+ - [Dataset Structure](#dataset-structure)
32
+ - [Data Instances](#data-instances)
33
+ - [Data Fields](#data-fields)
34
+ - [Data Splits](#data-splits)
35
+ - [Dataset Creation](#dataset-creation)
36
+ - [Curation Rationale](#curation-rationale)
37
+ - [Source Data](#source-data)
38
+ - [Annotations](#annotations)
39
+ - [Personal and Sensitive Information](#personal-and-sensitive-information)
40
+ - [Considerations for Using the Data](#considerations-for-using-the-data)
41
+ - [Social Impact of Dataset](#social-impact-of-dataset)
42
+ - [Discussion of Biases](#discussion-of-biases)
43
+ - [Other Known Limitations](#other-known-limitations)
44
+ - [Additional Information](#additional-information)
45
+ - [Dataset Curators](#dataset-curators)
46
+ - [Licensing Information](#licensing-information)
47
+ - [Citation Information](#citation-information)
48
+ - [Contributions](#contributions)
49
+
50
+ ## Dataset Description
51
+
52
+ - **Homepage:** [Edinburg DataShare](https://doi.org/10.7488/ds/2645)
53
+ - **Repository:**
54
+ - **Paper:**
55
+ - **Leaderboard:**
56
+ - **Point of Contact:**
57
+
58
+ ### Dataset Summary
59
+
60
+ This CSTR VCTK Corpus includes speech data uttered by 110 English speakers with various accents. Each speaker reads out about 400 sentences, which were selected from a newspaper, the rainbow passage and an elicitation paragraph used for the speech accent archive.
61
+
62
+ ### Supported Tasks and Leaderboards
63
+
64
+ [More Information Needed]
65
+
66
+ ### Languages
67
+
68
+ [More Information Needed]
69
+
70
+ ## Dataset Structure
71
+
72
+ ### Data Instances
73
+
74
+ A data point comprises the path to the audio file, called `file` and its transcription, called `text`.
75
+
76
+ ```
77
+ {
78
+ 'speaker_id': 'p225',
79
+ 'text_id': '001',
80
+ 'text': 'Please call Stella.',
81
+ 'age': '23',
82
+ 'gender': 'F',
83
+ 'accent': 'English',
84
+ 'region': 'Southern England',
85
+ 'file': '/datasets/downloads/extracted/8ed7dad05dfffdb552a3699777442af8e8ed11e656feb277f35bf9aea448f49e/wav48_silence_trimmed/p225/p225_001_mic1.flac',
86
+ 'audio':
87
+ {
88
+ 'path': '/datasets/downloads/extracted/8ed7dad05dfffdb552a3699777442af8e8ed11e656feb277f35bf9aea448f49e/wav48_silence_trimmed/p225/p225_001_mic1.flac',
89
+ 'array': array([0.00485229, 0.00689697, 0.00619507, ..., 0.00811768, 0.00836182, 0.00854492], dtype=float32),
90
+ 'sampling_rate': 48000
91
+ },
92
+ 'comment': ''
93
+ }
94
+ ```
95
+
96
+ Each audio file is a single-channel FLAC with a sample rate of 48000 Hz.
97
+
98
+ ### Data Fields
99
+
100
+ Each row consists of the following fields:
101
+
102
+ - `speaker_id`: Speaker ID
103
+ - `audio`: Audio recording
104
+ - `file`: Path to audio file
105
+ - `text`: Text transcription of corresponding audio
106
+ - `text_id`: Text ID
107
+ - `age`: Speaker's age
108
+ - `gender`: Speaker's gender
109
+ - `accent`: Speaker's accent
110
+ - `region`: Speaker's region, if annotation exists
111
+ - `comment`: Miscellaneous comments, if any
112
+
113
+ ### Data Splits
114
+
115
+ The dataset has no predefined splits.
116
+
117
+ ## Dataset Creation
118
+
119
+ ### Curation Rationale
120
+
121
+ [More Information Needed]
122
+
123
+ ### Source Data
124
+
125
+ #### Initial Data Collection and Normalization
126
+
127
+ [More Information Needed]
128
+
129
+ #### Who are the source language producers?
130
+
131
+ [More Information Needed]
132
+
133
+ ### Annotations
134
+
135
+ #### Annotation process
136
+
137
+ [More Information Needed]
138
+
139
+ #### Who are the annotators?
140
+
141
+ [More Information Needed]
142
+
143
+ ### Personal and Sensitive Information
144
+
145
+ The dataset consists of people who have donated their voice online. You agree to not attempt to determine the identity of speakers in this dataset.
146
+
147
+ ## Considerations for Using the Data
148
+
149
+ ### Social Impact of Dataset
150
+
151
+ [More Information Needed]
152
+
153
+ ### Discussion of Biases
154
+
155
+ [More Information Needed]
156
+
157
+ ### Other Known Limitations
158
+
159
+ [More Information Needed]
160
+
161
+ ## Additional Information
162
+
163
+ ### Dataset Curators
164
+
165
+ [More Information Needed]
166
+
167
+ ### Licensing Information
168
+
169
+ Public Domain, Creative Commons Attribution 4.0 International Public License ([CC-BY-4.0](https://creativecommons.org/licenses/by/4.0/legalcode))
170
+
171
+ ### Citation Information
172
+
173
+ ```bibtex
174
+ @inproceedings{Veaux2017CSTRVC,
175
+ title = {CSTR VCTK Corpus: English Multi-speaker Corpus for CSTR Voice Cloning Toolkit},
176
+ author = {Christophe Veaux and Junichi Yamagishi and Kirsten MacDonald},
177
+ year = 2017
178
+ }
179
+ ```
180
+
181
+ ### Contributions
182
+
183
+ Thanks to [@jaketae](https://github.com/jaketae) for adding this dataset.
dataset_infos.json ADDED
@@ -0,0 +1 @@
 
1
+ {"main": {"description": "", "citation": "@inproceedings{Veaux2017CSTRVC,\n\ttitle = {CSTR VCTK Corpus: English Multi-speaker Corpus for CSTR Voice Cloning Toolkit},\n\tauthor = {Christophe Veaux and Junichi Yamagishi and Kirsten MacDonald},\n\tyear = 2017\n}\n", "homepage": "https://datashare.ed.ac.uk/handle/10283/3443", "license": "", "features": {"speaker_id": {"dtype": "string", "id": null, "_type": "Value"}, "audio": {"sampling_rate": 48000, "mono": true, "_storage_dtype": "string", "id": null, "_type": "Audio"}, "file": {"dtype": "string", "id": null, "_type": "Value"}, "text": {"dtype": "string", "id": null, "_type": "Value"}, "text_id": {"dtype": "string", "id": null, "_type": "Value"}, "age": {"dtype": "string", "id": null, "_type": "Value"}, "gender": {"dtype": "string", "id": null, "_type": "Value"}, "accent": {"dtype": "string", "id": null, "_type": "Value"}, "region": {"dtype": "string", "id": null, "_type": "Value"}, "comment": {"dtype": "string", "id": null, "_type": "Value"}}, "post_processed": null, "supervised_keys": {"input": "file", "output": "text"}, "task_templates": [{"task": "automatic-speech-recognition", "audio_file_path_column": "file", "transcription_column": "text"}], "builder_name": "vctk", "config_name": "main", "version": {"version_str": "0.9.2", "description": null, "major": 0, "minor": 9, "patch": 2}, "splits": {"train": {"name": "train", "num_bytes": 40103111, "num_examples": 88156, "dataset_name": "vctk"}}, "download_checksums": {"https://datashare.is.ed.ac.uk/bitstream/handle/10283/3443/VCTK-Corpus-0.92.zip": {"num_bytes": 11747302977, "checksum": "f96258be9fdc2cbff6559541aae7ea4f59df3fcaf5cf963aae5ca647357e359c"}}, "download_size": 11747302977, "post_processing_size": null, "dataset_size": 40103111, "size_in_bytes": 11787406088}}
dummy/main/0.9.2/dummy_data.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:6a881a2741e280eeb7e6b8ff16208b4621050985d6d0b877aa3942354c149a80
3
+ size 801021
vctk.py ADDED
@@ -0,0 +1,133 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # coding=utf-8
2
+ # Copyright 2021 The TensorFlow Datasets Authors and the HuggingFace Datasets Authors.
3
+ #
4
+ # Licensed under the Apache License, Version 2.0 (the "License");
5
+ # you may not use this file except in compliance with the License.
6
+ # You may obtain a copy of the License at
7
+ #
8
+ # http://www.apache.org/licenses/LICENSE-2.0
9
+ #
10
+ # Unless required by applicable law or agreed to in writing, software
11
+ # distributed under the License is distributed on an "AS IS" BASIS,
12
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ # See the License for the specific language governing permissions and
14
+ # limitations under the License.
15
+
16
+ # Lint as: python3
17
+ """VCTK dataset."""
18
+
19
+
20
+ import os
21
+ import re
22
+
23
+ import datasets
24
+ from datasets.tasks import AutomaticSpeechRecognition
25
+
26
+
27
+ _CITATION = """\
28
+ @inproceedings{Veaux2017CSTRVC,
29
+ title = {CSTR VCTK Corpus: English Multi-speaker Corpus for CSTR Voice Cloning Toolkit},
30
+ author = {Christophe Veaux and Junichi Yamagishi and Kirsten MacDonald},
31
+ year = 2017
32
+ }
33
+ """
34
+
35
+ _DESCRIPTION = """\
36
+ The CSTR VCTK Corpus includes speech data uttered by 110 English speakers with various accents.
37
+ """
38
+
39
+ _URL = "https://datashare.ed.ac.uk/handle/10283/3443"
40
+ _DL_URL = "https://datashare.is.ed.ac.uk/bitstream/handle/10283/3443/VCTK-Corpus-0.92.zip"
41
+
42
+
43
+ class VCTK(datasets.GeneratorBasedBuilder):
44
+ """VCTK dataset."""
45
+
46
+ VERSION = datasets.Version("0.9.2")
47
+
48
+ BUILDER_CONFIGS = [
49
+ datasets.BuilderConfig(name="main", version=VERSION, description="VCTK dataset"),
50
+ ]
51
+
52
+ def _info(self):
53
+ return datasets.DatasetInfo(
54
+ description=_DESCRIPTION,
55
+ features=datasets.Features(
56
+ {
57
+ "speaker_id": datasets.Value("string"),
58
+ "audio": datasets.features.Audio(sampling_rate=48_000),
59
+ "file": datasets.Value("string"),
60
+ "text": datasets.Value("string"),
61
+ "text_id": datasets.Value("string"),
62
+ "age": datasets.Value("string"),
63
+ "gender": datasets.Value("string"),
64
+ "accent": datasets.Value("string"),
65
+ "region": datasets.Value("string"),
66
+ "comment": datasets.Value("string"),
67
+ }
68
+ ),
69
+ supervised_keys=("file", "text"),
70
+ homepage=_URL,
71
+ citation=_CITATION,
72
+ task_templates=[AutomaticSpeechRecognition(audio_file_path_column="file", transcription_column="text")],
73
+ )
74
+
75
+ def _split_generators(self, dl_manager):
76
+ root_path = dl_manager.download_and_extract(_DL_URL)
77
+
78
+ return [
79
+ datasets.SplitGenerator(name=datasets.Split.TRAIN, gen_kwargs={"root_path": root_path}),
80
+ ]
81
+
82
+ def _generate_examples(self, root_path):
83
+ """Generate examples from the VCTK corpus root path."""
84
+
85
+ meta_path = os.path.join(root_path, "speaker-info.txt")
86
+ txt_root = os.path.join(root_path, "txt")
87
+ wav_root = os.path.join(root_path, "wav48_silence_trimmed")
88
+ # NOTE: "comment" is handled separately in logic below
89
+ fields = ["speaker_id", "age", "gender", "accent", "region"]
90
+
91
+ key = 0
92
+ with open(meta_path, encoding="utf-8") as meta_file:
93
+ _ = next(iter(meta_file))
94
+ for line in meta_file:
95
+ data = {}
96
+ line = line.strip()
97
+ search = re.search(r"\(.*\)", line)
98
+ if search is None:
99
+ data["comment"] = ""
100
+ else:
101
+ start, _ = search.span()
102
+ data["comment"] = line[start:]
103
+ line = line[:start]
104
+ values = line.split()
105
+ for i, field in enumerate(fields):
106
+ if field == "region":
107
+ data[field] = " ".join(values[i:])
108
+ else:
109
+ data[field] = values[i] if i < len(values) else ""
110
+ speaker_id = data["speaker_id"]
111
+ speaker_txt_path = os.path.join(txt_root, speaker_id)
112
+ speaker_wav_path = os.path.join(wav_root, speaker_id)
113
+ # NOTE: p315 does not have text
114
+ if not os.path.exists(speaker_txt_path):
115
+ continue
116
+ for txt_file in sorted(os.listdir(speaker_txt_path)):
117
+ filename, _ = os.path.splitext(txt_file)
118
+ _, text_id = filename.split("_")
119
+ for i in [1, 2]:
120
+ wav_file = os.path.join(speaker_wav_path, f"{filename}_mic{i}.flac")
121
+ # NOTE: p280 does not have mic2 files
122
+ if not os.path.exists(wav_file):
123
+ continue
124
+ with open(os.path.join(speaker_txt_path, txt_file), encoding="utf-8") as text_file:
125
+ text = text_file.readline().strip()
126
+ more_data = {
127
+ "file": wav_file,
128
+ "audio": wav_file,
129
+ "text": text,
130
+ "text_id": text_id,
131
+ }
132
+ yield key, {**data, **more_data}
133
+ key += 1