kan-bayashi / ParallelWaveGAN

Unofficial Parallel WaveGAN (+ MelGAN & Multi-band MelGAN & HiFi-GAN & StyleMelGAN) with Pytorch
https://kan-bayashi.github.io/ParallelWaveGAN/
MIT License
1.54k stars 339 forks source link

illegal line count -- -2 #401

Closed noanymore closed 1 year ago

noanymore commented 1 year ago

I install the project and I tested ljspeech successfully. but when i try to excute the run.sh at csmsc/voc1/ the job start to download wav and interval files and then I got this log

Extracting PhoneLabeling/009998.interval OK Extracting PhoneLabeling/009999.interval OK Extracting PhoneLabeling/010000.interval OK All OK Successfully finished download. Stage 0: Data preparation head: illegal line count -- -2

i check the run.sh and found this problem seems to happend at local/data_prep.sh
how can i fix it?

noanymore commented 1 year ago

resolve it,it is because of my head version it can be change to end_sec=$(head -n $(($(wc -l < "${filename}") - 2)) "${filename}" | tail -n 1) origin version end_sec=$(head -n - 2 "${filename}" | tail -n 1)