Update README.md
Browse files
README.md
CHANGED
|
@@ -92,11 +92,11 @@ using the VTT timestamps.
|
|
| 92 |
| Field | Type | Description |
|
| 93 |
|--------------|-------------------|---------------------------------------------------------|
|
| 94 |
| `id` | `string` | Unique segment id: `<talk_stem>_<index>` (e.g. `14zpc3Nj_e4_0003`) |
|
| 95 |
-
| `talk_id` | `string` | Source talk file stem |
|
| 96 |
-
| `segment_id` | `int32` | 0-based index of the segment within its talk |
|
| 97 |
| `audio` | `Audio` | Audio float32 waveform of the segment |
|
| 98 |
-
| `duration` | `float32` | Duration of the audio segment **in seconds** |
|
| 99 |
| `transcript` | `string` | Transcription text from the VTT file |
|
|
|
|
|
|
|
|
|
|
| 100 |
| `start` | `float32` | Segment start time within the source talk (seconds) |
|
| 101 |
| `end` | `float32` | Segment end time within the source talk (seconds) |
|
| 102 |
|
|
@@ -120,18 +120,18 @@ ds = load_dataset("deepdml/mtedx", "ar", split="train")
|
|
| 120 |
print(ds[0])
|
| 121 |
# {
|
| 122 |
# 'id': '14zpc3Nj_e4_0001',
|
| 123 |
-
# 'talk_id': '14zpc3Nj_e4',
|
| 124 |
-
# 'segment_id': 1,
|
| 125 |
# 'audio': {'array': array([...], dtype=float32), 'sampling_rate': 16000},
|
| 126 |
-
# 'duration': 4.16,
|
| 127 |
# 'transcript': 'أكل العالم وغص بنخلة',
|
|
|
|
|
|
|
|
|
|
| 128 |
# 'start': 9.332,
|
| 129 |
# 'end': 13.492,
|
| 130 |
# 'language': 'ar'
|
| 131 |
# }
|
| 132 |
|
| 133 |
# Stream a large language without downloading everything
|
| 134 |
-
ds = load_dataset("
|
| 135 |
for sample in ds:
|
| 136 |
audio = sample["audio"]["array"] # numpy float32 array @ 16 kHz
|
| 137 |
text = sample["transcript"]
|
|
@@ -139,7 +139,7 @@ for sample in ds:
|
|
| 139 |
break
|
| 140 |
|
| 141 |
# ASR fine-tuning example (Whisper / wav2vec2)
|
| 142 |
-
ds = load_dataset("
|
| 143 |
ds = ds.select_columns(["audio", "transcript", "duration"])
|
| 144 |
```
|
| 145 |
|
|
|
|
| 92 |
| Field | Type | Description |
|
| 93 |
|--------------|-------------------|---------------------------------------------------------|
|
| 94 |
| `id` | `string` | Unique segment id: `<talk_stem>_<index>` (e.g. `14zpc3Nj_e4_0003`) |
|
|
|
|
|
|
|
| 95 |
| `audio` | `Audio` | Audio float32 waveform of the segment |
|
|
|
|
| 96 |
| `transcript` | `string` | Transcription text from the VTT file |
|
| 97 |
+
| `duration` | `float32` | Duration of the audio segment **in seconds** |
|
| 98 |
+
| `talk_id` | `string` | Source talk file stem |
|
| 99 |
+
| `segment_id` | `int32` | 0-based index of the segment within its talk |
|
| 100 |
| `start` | `float32` | Segment start time within the source talk (seconds) |
|
| 101 |
| `end` | `float32` | Segment end time within the source talk (seconds) |
|
| 102 |
|
|
|
|
| 120 |
print(ds[0])
|
| 121 |
# {
|
| 122 |
# 'id': '14zpc3Nj_e4_0001',
|
|
|
|
|
|
|
| 123 |
# 'audio': {'array': array([...], dtype=float32), 'sampling_rate': 16000},
|
|
|
|
| 124 |
# 'transcript': 'أكل العالم وغص بنخلة',
|
| 125 |
+
# 'duration': 4.16,
|
| 126 |
+
# 'talk_id': '14zpc3Nj_e4',
|
| 127 |
+
# 'segment_id': 1,
|
| 128 |
# 'start': 9.332,
|
| 129 |
# 'end': 13.492,
|
| 130 |
# 'language': 'ar'
|
| 131 |
# }
|
| 132 |
|
| 133 |
# Stream a large language without downloading everything
|
| 134 |
+
ds = load_dataset("deepdml/mtedx", "es", split="train", streaming=True)
|
| 135 |
for sample in ds:
|
| 136 |
audio = sample["audio"]["array"] # numpy float32 array @ 16 kHz
|
| 137 |
text = sample["transcript"]
|
|
|
|
| 139 |
break
|
| 140 |
|
| 141 |
# ASR fine-tuning example (Whisper / wav2vec2)
|
| 142 |
+
ds = load_dataset("deepdml/mtedx", "fr", split="train")
|
| 143 |
ds = ds.select_columns(["audio", "transcript", "duration"])
|
| 144 |
```
|
| 145 |
|