mfcc
mfcc(
@dcttype 2
@highfrequencybound 11000
@inputsize 1025
@liftering 0
@logtype 'dbamp'
@lowfrequencybound 0
@normalize 'unit_sum'
@numberbands 40
@numbercoefficients 13
@samplerate 44100
@silencethreshold 0.0000
@type 'power'
@warpingformula 'htkmel'
@weighting 'warping'
@mode 0
) -> llll
Generates an audio descriptor to compute the mel-frequency cepstrum coefficients of a buffer's spectrum. As there is no standard implementation, the MFCC-FB40 is used by default.
The resulting buffer will be updated with the following keys:
mfcc_bandsmfcc
info
mfcc is a mirror implementation of the same algorithm in the Essentia library.
For more details on the algorithm, please check the Essentia Algorithms reference.
Arguments
@dcttype[int]: DCT type. (default:2).@highfrequencybound[int/float]: Upper bound of the frequency range, in Hz. (default:11000).@inputsize[int]: Size of input spectrum. (default:1025).@liftering[int]: Liftering coefficient. Use0to bypass it. (default:0).@logtype[symbol]: Logarithmic compression type. (default:'dbamp').'natural''dbpow''dbamp''log'
@lowfrequencybound[float]: Lower bound of the frequency range, in Hz. (default:0).@normalize[symbol]: Spectrum bin weights to use for each mel band. (default:'unit_sum').'unit_sum''unit_tri''unit_max'
@numberbands[int]: Number of mel-bands in the filter. (default:40).@numbercoefficients[int]: Number of output mel coefficients. (default:13).@samplerate[int]: Sampling rate of the audio signal, in Hz. (default:44100).@silencethreshold[int/float]: Silence threshold for computing log-energy bands. (default:0.0000).@type[symbol]: Use magnitude or power spectrum. (default:'power').'magnitude''power'
@warpingformula[symbol]: Scale implementation type. (default:'htkmel').'slaneymel''htkmel'
@weighting[symbol]: Type of weighting function for determining triangle area. (default:'warping').'warping''linear'
@mode[int]: Analysis mode. (default:0).0: Global1: Time series2: Time-tagged time series3: Buffer
Output
Mfcc descriptor [llll]
Usage
mfcc is meant to be used with the analyze function:
$buffer = importaudio('singing.wav'); ## input buffer
$descr = mfcc(); ## generate mfcc audio descriptor
$buffer.view('before analysis');
$buffer = $buffer.analyze($descr); ## apply analysis
$buffer.view('after analysis')