Wav2Lip
Wav2Lip copied to clipboard
mel() error
when I run the project in the colab,
i will show the error below:
Using cuda for inference.
Reading video frames...
Number of frames available for inference: 223
Traceback (most recent call last):
File "/content/Wav2Lip/inference.py", line 280, in
Don't know if it will helpful for you but I have created a repository that fixes the running for inference using the pretrained model. here is the link https://github.com/HassanMuhammadSannaullah/Wav2lip-Fix-For-Inference
pip install librosa == 0.8.0
when using librosa>=0.10.0, you should fix “_build_mel_basis()” in audio.py
def _build_mel_basis():
assert hp.fmax <= hp.sample_rate // 2
return librosa.filters.mel(sr=hp.sample_rate, n_fft=hp.n_fft, n_mels=hp.num_mels,
fmin=hp.fmin, fmax=hp.fmax)
when using librosa>=0.10.0, you should fix “_build_mel_basis()” in audio.py
def _build_mel_basis(): assert hp.fmax <= hp.sample_rate // 2 return librosa.filters.mel(sr=hp.sample_rate, n_fft=hp.n_fft, n_mels=hp.num_mels, fmin=hp.fmin, fmax=hp.fmax)
Thanks for sharing, this change works for me
when using librosa>=0.10.0, you should fix “_build_mel_basis()” in audio.py
def _build_mel_basis(): assert hp.fmax <= hp.sample_rate // 2 return librosa.filters.mel(sr=hp.sample_rate, n_fft=hp.n_fft, n_mels=hp.num_mels, fmin=hp.fmin, fmax=hp.fmax)
You're a lifesaver! Thank you very much :)