temporalcentroid
temporalcentroid() -> llll
Generates audio descriptor to calculate the temporal centroid of a buffer, defined as the point in time that is a temporal balancing point of the sound's energy. See analyze
.
The resulting buffer will be updated with the following keys:
temporalcentroid
info
temporalcentroid
is a mirror implementation of the same algorithm in the Essentia library.
For more details on the algorithm, please check the Essentia Algorithms reference.
Output
temporalcentroid descriptor [llll]
Usage
temporalcentroid
is meant to be used with the analyze
function:
$buffer = importaudio('singing.wav'); ## input buffer
$descr = temporalcentroid(); ## generate temporalcentroid audio descriptor
$buffer.inspect('before analysis');
$buffer = $buffer.analyze($descr); ## apply analysis
$buffer.inspect('after analysis')