Datasets:

Multilinguality:
multilingual
Size Categories:
100K<n<1M
Annotations Creators:
expert-generated
ArXiv:
License:
system HF staff commited on
Commit
2ad9180
1 Parent(s): a9e75f9

Update files from the datasets library (from 1.13.3)

Browse files

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

Files changed (2) hide show
  1. README.md +8 -2
  2. covost2.py +2 -0
README.md CHANGED
@@ -35,10 +35,11 @@ size_categories:
35
  source_datasets:
36
  - extended|other-common-voice
37
  task_categories:
38
- - other
39
  task_ids:
40
- - other-other-speech-translation
41
  paperswithcode_id: null
 
42
  ---
43
 
44
  # Dataset Card for covost2
@@ -98,6 +99,9 @@ A typical data point comprises the path to the audio file, usually called `file`
98
  ```
99
  {'client_id': 'd277a1f3904ae00b09b73122b87674e7c2c78e08120721f37b5577013ead08d1ea0c053ca5b5c2fb948df2c81f27179aef2c741057a17249205d251a8fe0e658',
100
  'file': '/home/suraj/projects/fairseq_s2t/covst/dataset/en/clips/common_voice_en_18540003.mp3',
 
 
 
101
  'id': 'common_voice_en_18540003',
102
  'sentence': 'When water is scarce, avoid wasting it.',
103
  'translation': 'Wenn Wasser knapp ist, verschwenden Sie es nicht.'}
@@ -107,6 +111,8 @@ A typical data point comprises the path to the audio file, usually called `file`
107
 
108
  - file: A path to the downloaded audio file in .mp3 format.
109
 
 
 
110
  - sentence: The transcription of the audio file in source language.
111
 
112
  - translation: The transcription of the audio file in the target language.
 
35
  source_datasets:
36
  - extended|other-common-voice
37
  task_categories:
38
+ - speech-processing
39
  task_ids:
40
+ - automatic-speech-recognition
41
  paperswithcode_id: null
42
+ pretty_name: CoVoST 2
43
  ---
44
 
45
  # Dataset Card for covost2
 
99
  ```
100
  {'client_id': 'd277a1f3904ae00b09b73122b87674e7c2c78e08120721f37b5577013ead08d1ea0c053ca5b5c2fb948df2c81f27179aef2c741057a17249205d251a8fe0e658',
101
  'file': '/home/suraj/projects/fairseq_s2t/covst/dataset/en/clips/common_voice_en_18540003.mp3',
102
+ 'audio': {'path': '/home/suraj/projects/fairseq_s2t/covst/dataset/en/clips/common_voice_en_18540003.mp3',
103
+ 'array': array([-0.00048828, -0.00018311, -0.00137329, ..., 0.00079346, 0.00091553, 0.00085449], dtype=float32),
104
+ 'sampling_rate': 48000},
105
  'id': 'common_voice_en_18540003',
106
  'sentence': 'When water is scarce, avoid wasting it.',
107
  'translation': 'Wenn Wasser knapp ist, verschwenden Sie es nicht.'}
 
111
 
112
  - file: A path to the downloaded audio file in .mp3 format.
113
 
114
+ - audio: A dictionary containing the path to the downloaded audio file, the decoded audio array, and the sampling rate. Note that when accessing the audio column: `dataset[0]["audio"]` the audio file is automatically decoded and resampled to `dataset.features["audio"].sampling_rate`. Decoding and resampling of a large number of audio files might take a significant amount of time. Thus it is important to first query the sample index before the `"audio"` column, *i.e.* `dataset[0]["audio"]` should **always** be preferred over `dataset["audio"][0]`.
115
+
116
  - sentence: The transcription of the audio file in source language.
117
 
118
  - translation: The transcription of the audio file in the target language.
covost2.py CHANGED
@@ -99,6 +99,7 @@ class Covost2(datasets.GeneratorBasedBuilder):
99
  features=datasets.Features(
100
  client_id=datasets.Value("string"),
101
  file=datasets.Value("string"),
 
102
  sentence=datasets.Value("string"),
103
  translation=datasets.Value("string"),
104
  id=datasets.Value("string"),
@@ -181,6 +182,7 @@ class Covost2(datasets.GeneratorBasedBuilder):
181
  "sentence": row["sentence"],
182
  "translation": row["translation"],
183
  "file": os.path.join(source_path, "clips", row["path"]),
 
184
  }
185
 
186
  def _load_df_from_tsv(self, path):
 
99
  features=datasets.Features(
100
  client_id=datasets.Value("string"),
101
  file=datasets.Value("string"),
102
+ audio=datasets.features.Audio(sampling_rate=16_000),
103
  sentence=datasets.Value("string"),
104
  translation=datasets.Value("string"),
105
  id=datasets.Value("string"),
 
182
  "sentence": row["sentence"],
183
  "translation": row["translation"],
184
  "file": os.path.join(source_path, "clips", row["path"]),
185
+ "audio": os.path.join(source_path, "clips", row["path"]),
186
  }
187
 
188
  def _load_df_from_tsv(self, path):