transform_mel_scale: Mel Scale

transform_mel_scaleR Documentation

Mel Scale

Description

Turn a normal STFT into a mel frequency STFT, using a conversion matrix. This uses triangular filter banks.

Usage

transform_mel_scale(
  n_mels = 128,
  sample_rate = 16000,
  f_min = 0,
  f_max = NULL,
  n_stft = NULL
)

Arguments

n_mels

(int, optional): Number of mel filterbanks. (Default: 128)

sample_rate

(int, optional): Sample rate of audio signal. (Default: 16000)

f_min

(float, optional): Minimum frequency. (Default: 0.)

f_max

(float or NULL, optional): Maximum frequency. (Default: ⁠sample_rate // 2⁠)

n_stft

(int, optional): Number of bins in STFT. Calculated from first input if NULL is given. See n_fft in :class:Spectrogram. (Default: NULL)

Details

forward param: specgram (Tensor): Tensor of audio of dimension (..., freq, time).

Value

tensor: Mel frequency spectrogram of size (..., n_mels, time).


curso-r/torchaudio documentation built on May 4, 2023, 2:27 a.m.