mindspore.dataset.audio.linear_fbanks

mindspore.dataset.audio.linear_fbanks(n_freqs, f_min, f_max, n_filter, sample_rate)[source]

Creates a linear triangular filterbank.

Parameters
  • n_freqs (int) – Number of frequencies to highlight/apply.

  • f_min (float) – Minimum frequency in Hz.

  • f_max (float) – Maximum frequency in Hz.

  • n_filter (int) – Number of (linear) triangular filter.

  • sample_rate (int) – Sample rate of the waveform.

Returns

numpy.ndarray, the linear triangular filterbank.

Raises
Supported Platforms:

CPU

Examples

>>> from mindspore.dataset.audio import linear_fbanks
>>>
>>> fbanks = linear_fbanks(n_freqs=4096, f_min=0, f_max=8000, n_filter=40, sample_rate=16000)