Skip to content

Commit fb1d4b1

Browse files
authored
Fix deprecated positional arguments in mel (#133)
1 parent 329d739 commit fb1d4b1

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

train/mel_processing.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,9 @@ def spec_to_mel_torch(spec, n_fft, num_mels, sampling_rate, fmin, fmax):
9898
dtype_device = str(spec.dtype) + "_" + str(spec.device)
9999
fmax_dtype_device = str(fmax) + "_" + dtype_device
100100
if fmax_dtype_device not in mel_basis:
101-
mel = librosa_mel_fn(sampling_rate, n_fft, num_mels, fmin, fmax)
101+
mel = librosa_mel_fn(
102+
sr=sampling_rate, n_fft=n_fft, n_mels=num_mels, fmin=fmin, fmax=fmax
103+
)
102104
mel_basis[fmax_dtype_device] = torch.from_numpy(mel).to(
103105
dtype=spec.dtype, device=spec.device
104106
)

0 commit comments

Comments
 (0)