maxmagfreq
maxmagfreq(
@samplerate 44100
@mode 0
) -> llll
Generates audio descriptor to compute the frequency with the largest magnitude in a spectrum. See analyze
.
The resulting buffer will be updated with the following keys:
maxmagfreq
info
maxmagfreq
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
@samplerate
[int]: sampling rate. (default:44100
).@mode
[int]: analysis mode. (default:0
).0
: global1
: time series2
: time-tagged time series3
: buffer
Output
maxmagfreq descriptor [llll]
Usage
maxmagfreq
is meant to be used with the analyze
function:
$buffer = importaudio('singing.wav'); ## input buffer
$descr = maxmagfreq(); ## generate maxmagfreq audio descriptor
$buffer.inspect('before analysis');
$buffer = $buffer.analyze($descr); ## apply analysis
$buffer.inspect('after analysis')