Skip to content

Commit

Permalink
Merge pull request #5 from eschmidbauer/main
Browse files Browse the repository at this point in the history
train.py fix: RuntimeError: stft requires the return_complex
  • Loading branch information
zhenye234 authored Sep 27, 2023
2 parents 4408428 + c0968a1 commit 2bec3ff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hifi-gan/meldataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ def mel_spectrogram(y, n_fft, num_mels, sampling_rate, hop_size, win_size, fmin,
y = y.squeeze(1)

spec = torch.stft(y, n_fft, hop_length=hop_size, win_length=win_size, window=hann_window[str(y.device)],
center=center, pad_mode='reflect', normalized=False, onesided=True)
center=center, pad_mode='reflect', normalized=False, onesided=True, return_complex=False)

spec = torch.sqrt(spec.pow(2).sum(-1)+(1e-9))

Expand Down

0 comments on commit 2bec3ff

Please sign in to comment.