Datasets:
README.md
CHANGED
|
@@ -120,6 +120,59 @@ The dataset includes the following splits based on the test type and language.
|
|
| 120 |
| **Tamil__MUSHRA_NMR** | 48500 |
|
| 121 |
|
| 122 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 123 |
|
| 124 |
### Why Use MANGO?
|
| 125 |
- Addresses limitations of traditional **MOS** and **CMOS** tests.
|
|
|
|
| 120 |
| **Tamil__MUSHRA_NMR** | 48500 |
|
| 121 |
|
| 122 |
|
| 123 |
+
### Getting Started
|
| 124 |
+
|
| 125 |
+
```
|
| 126 |
+
import os
|
| 127 |
+
from datasets import load_dataset, Audio
|
| 128 |
+
from huggingface_hub import snapshot_download
|
| 129 |
+
|
| 130 |
+
|
| 131 |
+
def get_audio_paths(example):
|
| 132 |
+
for column in example.keys():
|
| 133 |
+
if "Audio" in column and isinstance(example[column], str):
|
| 134 |
+
example[column] = os.path.join(download_dir, example[column])
|
| 135 |
+
return example
|
| 136 |
+
|
| 137 |
+
|
| 138 |
+
# Download
|
| 139 |
+
repo_id = "svp19/MANGO"
|
| 140 |
+
download_dir = snapshot_download(repo_id=repo_id, repo_type="dataset")
|
| 141 |
+
dataset = load_dataset(download_dir, split='Hindi__MUSHRA')
|
| 142 |
+
dataset = dataset.map(get_audio_paths)
|
| 143 |
+
|
| 144 |
+
# Cast audio columns
|
| 145 |
+
for column in dataset.column_names:
|
| 146 |
+
if 'Audio' in column:
|
| 147 |
+
dataset = dataset.cast_column(column, Audio())
|
| 148 |
+
|
| 149 |
+
# Explore
|
| 150 |
+
print(dataset)
|
| 151 |
+
'''
|
| 152 |
+
Dataset({
|
| 153 |
+
features: ['Rater_ID', 'FS2_Score', 'VITS_Score', 'ST2_Score', 'ANC_Score', 'REF_Score', 'FS2_Audio', 'VITS_Audio', 'ST2_Audio', 'ANC_Audio', 'REF_Audio'],
|
| 154 |
+
num_rows: 11300
|
| 155 |
+
})
|
| 156 |
+
'''
|
| 157 |
+
|
| 158 |
+
# # Print first instance
|
| 159 |
+
print(dataset[0])
|
| 160 |
+
'''
|
| 161 |
+
{'Rater_ID': 389, 'FS2_Score': 16, 'VITS_Score': 76, 'ST2_Score': 28,
|
| 162 |
+
'ANC_Score': 40, 'REF_Score': 100, 'FS2_Audio': {'path': ...
|
| 163 |
+
'''
|
| 164 |
+
|
| 165 |
+
# # Available Splits
|
| 166 |
+
dataset = load_dataset(download_dir, split=None)
|
| 167 |
+
print("Splits:", dataset.keys())
|
| 168 |
+
'''
|
| 169 |
+
Splits: dict_keys(['Tamil__MUSHRA_DG_NMR', 'Hindi__MUSHRA_DG',
|
| 170 |
+
'Hindi__MUSHRA_NMR', 'Hindi__MUSHRA_DG_NMR', 'Tamil__MUSHRA_NMR',
|
| 171 |
+
'Tamil__MUSHRA_DG', 'Tamil__MUSHRA', 'Hindi__MUSHRA'])
|
| 172 |
+
'''
|
| 173 |
+
|
| 174 |
+
```
|
| 175 |
+
|
| 176 |
|
| 177 |
### Why Use MANGO?
|
| 178 |
- Addresses limitations of traditional **MOS** and **CMOS** tests.
|