kan-bayashi / PytorchWaveNetVocoder

WaveNet-Vocoder implementation with pytorch.
https://kan-bayashi.github.io/WaveNetVocoderSamples/
Apache License 2.0
297 stars 57 forks source link

RuntimeError: zero(s) are found in periodogram, use eps option to floor #40

Closed greaber closed 5 years ago

greaber commented 6 years ago

Hi, I modified one of the arctic egs to train on a different dataset, and I get this error from the mcep extraction. I looked into it, and it seems that this happens when there is a long enough period of silence in the audio. It seems to fix the problem to change the mcep calculation line to:

    mcep = [pysptk.mcep(x[shiftl * i: shiftl * i + fftl] * win, dim, alpha, eps=EPS, etype=1) for i in range(n_frame)]

However, this might not be a complete fix. In particular, it looks like there are places where you use world to calculate mcep, and a colleague told me that he recalls that world will actually dump core because of this problem and doesn't have an eps option, so it to fix it it might be necessary to add a tiny bit of noise to the audio.

kan-bayashi commented 5 years ago

Fixed in #53