Update libriheavy.py
Browse files- libriheavy.py +2 -3
libriheavy.py
CHANGED
@@ -153,7 +153,6 @@ class Libriheavy(datasets.GeneratorBasedBuilder):
|
|
153 |
# skip the last utterance
|
154 |
if utterance_id == sorted(list(text.keys()))[-1]:
|
155 |
continue
|
156 |
-
print(utterance["phone_segments"])
|
157 |
result = {
|
158 |
"id": chunk["speaker_id"] + "_" + utterance_id,
|
159 |
"speaker_id": chunk["speaker_id"],
|
@@ -163,7 +162,7 @@ class Libriheavy(datasets.GeneratorBasedBuilder):
|
|
163 |
{"start": segment[0], "end": segment[1], "word": segment[2]} for segment in utterance["word_segments"]
|
164 |
],
|
165 |
"phone_segments": [
|
166 |
-
{"start": segment[0], "end": segment[1], "
|
167 |
],
|
168 |
"mel_spectrogram": npz[str(utterance_id)].item()["mel"][0][0],
|
169 |
}
|
@@ -181,7 +180,7 @@ class Libriheavy(datasets.GeneratorBasedBuilder):
|
|
181 |
{"start": segment[0], "end": segment[1], "word": segment[2]} for segment in utterance["word_segments"]
|
182 |
],
|
183 |
"phone_segments": [
|
184 |
-
{"start": segment[0], "end": segment[1], "
|
185 |
],
|
186 |
"mel_spectrogram": npz[str(utterance_id)].item()["mel"][0][0],
|
187 |
}
|
|
|
153 |
# skip the last utterance
|
154 |
if utterance_id == sorted(list(text.keys()))[-1]:
|
155 |
continue
|
|
|
156 |
result = {
|
157 |
"id": chunk["speaker_id"] + "_" + utterance_id,
|
158 |
"speaker_id": chunk["speaker_id"],
|
|
|
162 |
{"start": segment[0], "end": segment[1], "word": segment[2]} for segment in utterance["word_segments"]
|
163 |
],
|
164 |
"phone_segments": [
|
165 |
+
{"start": segment[0], "end": segment[1], "phone": segment[2]} for segment in utterance["phone_segments"]
|
166 |
],
|
167 |
"mel_spectrogram": npz[str(utterance_id)].item()["mel"][0][0],
|
168 |
}
|
|
|
180 |
{"start": segment[0], "end": segment[1], "word": segment[2]} for segment in utterance["word_segments"]
|
181 |
],
|
182 |
"phone_segments": [
|
183 |
+
{"start": segment[0], "end": segment[1], "phone": segment[2]} for segment in utterance["phone_segments"]
|
184 |
],
|
185 |
"mel_spectrogram": npz[str(utterance_id)].item()["mel"][0][0],
|
186 |
}
|