fairseq
fairseq copied to clipboard
"Incompatibility with Librosa 0.10.1 due to missing 'size' keyword in util.pad_center" in GSLM TTS code
🐛 Bug
Description:
The latest versions of Librosa (tested with 0.10.1) have introduced a required "size" keyword for the second argument of the util.pad_center function. This change causes an error when trying to run fairseq/examples/textless_nlp/gslm/unit2speech/synthesize_audio_from_units.py.
Affected Files:
fairseq/examples/textless_nlp/gslm/unit2speech/tacotron2/stft.py- Line 67:
fft_window = pad_center(fft_window, filter_length)
- Line 67:
fairseq/examples/textless_nlp/gslm/unit2speech/tacotron2/audio_processing.py- Line 50:
win_sq = librosa_util.pad_center(win_sq, n_fft)
- Line 50:
Proposed Solution:
Add the "size" keyword argument to the pad_center() function calls in the aforementioned files.
fairseq/examples/textless_nlp/gslm/unit2speech/tacotron2/stft.py- Line 67:
fft_window = pad_center(fft_window, size = filter_length)
- Line 67:
fairseq/examples/textless_nlp/gslm/unit2speech/tacotron2/audio_processing.py- Line 50:
win_sq = librosa_util.pad_center(win_sq, size=n_fft)
- Line 50: