Spaces:
Running
on
Zero
Running
on
Zero
fix module
Browse files
f5_tts/train/datasets/prepare_metadata.py
DELETED
@@ -1,12 +0,0 @@
|
|
1 |
-
import glob
|
2 |
-
from tqdm import tqdm
|
3 |
-
|
4 |
-
wavs_path = glob.glob("data/datasetVN/mc/mc1/*.wav")
|
5 |
-
|
6 |
-
with open("data/vnTTS__char/metadata.csv", "w", encoding="utf8") as fw:
|
7 |
-
fw.write("audio_file|text\n")
|
8 |
-
for wav_path in tqdm(wavs_path):
|
9 |
-
wav_name = wav_path.split("/")[-1]
|
10 |
-
with open(wav_path.replace(".wav", ".lab"), "r", encoding="utf8") as fr:
|
11 |
-
text = fr.readlines()[0].replace("\n", "")
|
12 |
-
fw.write("wavs/" + wav_name + "|" + text + "\n")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|