cannam@6: cannam@6: cannam@6:
cannam@6: cannam@6: cannam@6: cannam@6:The “vamp-example-plugins” library contains a number of cannam@6: Vamp audio analysis cannam@6: plugins provided as part of the Vamp plugin SDK. cannam@6: cannam@6:
cannam@6:These are simple, but sometimes useful, plugins whose source code you cannam@6: are free to study and reuse in any proprietary or non-proprietary cannam@6: plugins of your own without any licensing obligation. cannam@6:
cannam@6:User documentation for the individual plugins in this library follows. cannam@6:
cannam@6: cannam@6: cannam@6: cannam@6: cannam@6: cannam@6: cannam@6: cannam@6:System identifier – vamp-example-plugins:amplitudefollower
cannam@6: RDF URI – http://vamp-plugins.org/rdf/plugins/vamp-example-plugins#amplitudefollower
cannam@17:
Links – Back to top of library documentation – Download location – Source code
cannam@6:
Amplitude Follower tracks and returns the amplitude of the audio cannam@6: signal sample by sample, returning peak values block by block. cannam@6:
cannam@6:Attack time (seconds) – The 60dB convergence time for an increase in amplitude.
cannam@6: Release time (seconds) – The 60dB convergence time for a decrease in amplitude.
cannam@6:
For example, if you feed the plugin with a simple step function that cannam@6: jumps from level A to level B, then the output will start off as A, cannam@6: then at the moment of stepping it will start to converge exponentially cannam@6: to B, reaching with 60dB of the actual value within the time specified cannam@6: by the Attack time parameter. cannam@6:
cannam@6:Similarly, if the plugin's input then steps down from B to A, the cannam@6: output will start converging at the moment of stepping, reaching cannam@6: within 60dB of the new value within the time specified by the Release cannam@6: time parameter. cannam@6:
cannam@6:The peak tracked amplitude (in volts) for the current processing block. cannam@6:
cannam@6:Amplitude Follower uses a method from the SuperCollider audio cannam@6: processing language. It was implemented as a Vamp plugin by Dan cannam@6: Stowell. cannam@6:
cannam@6:System identifier – vamp-example-plugins:fixedtempo
cannam@6: RDF URI – http://vamp-plugins.org/rdf/plugins/vamp-example-plugins#fixedtempo
cannam@17:
Links – Back to top of library documentation – Download location – Source code
cannam@6:
Simple Fixed Tempo Estimator analyses a fragment of audio and cannam@6: estimates its tempo. It assumes that its input is of fixed tempo, and cannam@6: it analyses only the first (small but configurable number of) seconds cannam@6: before returning a result, discarding all subsequent input. cannam@6:
cannam@6:The plugin calculates an overall energy rise function across a series cannam@6: of short frequency-domain input frames, takes the autocorrelation of cannam@6: this function, filters it to stress possible metrical patterns, cannam@6: locates peaks, and converts from autocorrelation lag to the cannam@6: corresponding tempo. cannam@6:
cannam@6:The filtering process involves searching for peaks at simple cannam@6: metrically related intervals (at a given autocorrelation lag as well cannam@6: as at 0.5, 2, and 4 times that lag), boosting each peak that shows cannam@6: strong related peaks. A simplistic perceptual curve is also applied cannam@6: in order to increase the probability of detecting a "likely" tempo. cannam@6: For improved tempo precision, each tempo with strong related peaks is cannam@6: averaged with the tempi calculated from those peaks. cannam@6:
cannam@6:The method is best suited for 4/4 pop and dance rhythms. cannam@6:
cannam@6:This plugin returns many of its intermediate calculations as cannam@6: additional outputs, as well as the most favoured tempo. Although as a cannam@6: tempo estimator it's still fairly primitive, it is intended to provide cannam@6: a useful example of a slightly more complex feature extraction plugin cannam@6: than the other examples, as well as one that returns several different cannam@6: types of output at a time. cannam@6:
cannam@6:Minimum estimated tempo, Maximum estimated tempo (bpm) – These cannam@6: parameters control the range of values within which the tempo cannam@6: estimator will return its estimate. cannam@6:
cannam@6:Input duration to study (seconds) – The tempo estimator uses only the cannam@6: first part of its input, discarding any that follows. This parameter cannam@6: controls how much input it will use. There is no value in increasing cannam@6: this beyond 8x the duration of the slowest returned beat. The default cannam@6: of 10 seconds is likely to be appropriate for most purposes. cannam@6:
cannam@6:The tempo estimator's best guess at the tempo of its input, in beats cannam@6: per minute. cannam@6:
cannam@6:This is returned as a feature whose timestamp and duration cover the cannam@6: range of the input which was used in estimating the tempo, with a cannam@6: single value containing the tempo. cannam@6:
cannam@6:Several guesses at the possible tempo. This output is returned as a cannam@6: single feature whose timestamp and duration cover the range of the cannam@6: input which was used in estimating the tempo, with up to 10 bins cannam@6: containing one tempo value in each bin, with the "best guess" tempo in cannam@6: bin 0. cannam@6:
cannam@6:The basic onset detection function used in tempo estimation. cannam@6:
cannam@6:The autocorrelation of the onset detection function. cannam@6:
cannam@6:The autocorrelation after filtering to boost values with possible cannam@6: metrically related peaks and to apply perceptual weighting. The peak cannam@6: value of this function is the one that will be used as the "best cannam@6: guess". cannam@6:
cannam@6:Simple Fixed Tempo Estimator uses a method derived from work by cannam@6: Matthew Davies: see for example M. E. P. Davies and M. D. Plumbley, cannam@6: Beat Tracking With A Two State Model, in Proceedings of the IEEE cannam@6: International Conference on Acoustics, Speech and Signal Processing cannam@6: 2005. This plugin, made by Chris Cannam, is only an unsubtle cannam@6: simplification of a small part of the published method. cannam@6:
cannam@6:The Queen Mary plugin set cannam@6: (http://www.elec.qmul.ac.uk/digitalmusic/downloads/index.html#qm-vamp-plugins) cannam@6: contains a Tempo and Beat Tracker plugin by Matthew Davies providing a cannam@6: more realistic implementation. cannam@6:
cannam@6:System identifier – vamp-example-plugins:percussiononsets
cannam@6: RDF URI – http://vamp-plugins.org/rdf/plugins/vamp-example-plugins#percussiononsets
cannam@17:
Links – Back to top of library documentation – Download location – Source code
cannam@6:
Simple Percussion Onset Detector estimates the locations of percussive cannam@6: onsets in the audio signal. cannam@6:
cannam@6:The principle is to exploit the broadband nature of noisy percussive cannam@6: onsets by identifying only those frames in which the energy rise shows cannam@6: a broadband profile. cannam@6:
cannam@6:The plugin takes a series of frequency domain frames, and examines cannam@6: each frame to count the number of bins whose energy content has cannam@6: increased by more than a certain threshold since the prior frame. cannam@6: Frames in which this number is at a peak relative to prior and cannam@6: following frames and also exceeds another threshold value are cannam@6: classified as percussive onsets. cannam@6:
cannam@6:Energy rise threshold (dB) – The rise in energy within a bin from one cannam@6: frame to the next that is required for a bin to be counted toward the cannam@6: detection function's bin count. This roughly corresponds to how cannam@6: "loud" a percussive sound must be in order to be detected. cannam@6:
cannam@6:Sensitivity (%) – The proportion of bins that must exceed the energy cannam@6: rise threshold in order for an onset to be detected (at frames in cannam@6: which the detection function peaks). This roughly corresponds to how cannam@6: "noisy" a percussive sound must be in order to be detected. cannam@6:
cannam@6:The energy rise detection function whose peaks were used to estimate cannam@6: onset locations. cannam@6:
cannam@6:The method used in Simple Percussion Onset Detector was described in cannam@6: Dan Barry, Derry Fitzgerald, Eugene Coyle and cannam@6: Bob Lawlor, Drum Source Separation using Percussive Feature Detection and cannam@6: Spectral Modulation, ISSC 2005. The plugin was made by Chris Cannam. cannam@6:
cannam@6:System identifier – vamp-example-plugins:powerspectrum
cannam@6: RDF URI – http://vamp-plugins.org/rdf/plugins/vamp-example-plugins#powerspectrum
cannam@17:
Links – Back to top of library documentation – Download location – Source code
cannam@6:
Simple Power Spectrum returns a power spectrum calculated from cannam@6: windowed short-time Fourier transforms of the input audio. (The power cannam@6: spectrum for a frame consists of a sequence of the squares of the cannam@6: magnitudes of the complex values for each frequency bin in the result cannam@6: of the Fourier transform.) cannam@6:
cannam@6:This very simple plugin is an illustration of the fact that if a cannam@6: plugin requests frequency-domain input, its input will already be in cannam@6: the form needed for a spectrum such as this. The plugin has no work cannam@6: left to do except to calculate the squared magnitude from the cannam@6: cartesian complex representation. cannam@6:
cannam@6:This plugin also illustrates how to return "grid-type" visualisation cannam@6: data from a Vamp plugin. cannam@6:
cannam@6:The power spectrum calculated from the input frame. This output cannam@6: returns a single feature per processing block, containing cannam@6: blocksize/2+1 power values corresponding to the FFT bins from DC to cannam@6: Nyquist inclusive. The DC bin is always returned. cannam@6:
cannam@6:System identifier – vamp-example-plugins:spectralcentroid
cannam@6: RDF URI – http://vamp-plugins.org/rdf/plugins/vamp-example-plugins#spectralcentroid
cannam@17:
Links – Back to top of library documentation – Download location – Source code
cannam@6:
Spectral Centroid calculates the "centre of gravity" of the frequency cannam@6: spectrum for each input frame. cannam@6:
cannam@6:The centroid of the log-weighted frequency spectrum. That is, the sum cannam@6: across Fourier transform output bins of the logarithm of the bin cannam@6: frequency multiplied by the bin magnitude, divided by the sum of the cannam@6: bin magnitudes, and the inverse logarithm taken so as to give the cannam@6: result as a frequency in Hz. cannam@6:
cannam@6:The centroid of the linear-weighted frequency spectrum. That is, the cannam@6: sum across Fourier transform output bins of the bin frequency cannam@6: multiplied by the bin magnitude, divided by the sum of the bin cannam@6: magnitudes. The result is a frequency in Hz. cannam@6:
cannam@6:System identifier – vamp-example-plugins:zerocrossing
cannam@6: RDF URI – http://vamp-plugins.org/rdf/plugins/vamp-example-plugins#zerocrossing
cannam@17:
Links – Back to top of library documentation – Download location – Source code
cannam@6:
Zero Crossings calculates the positions and density of "zero-crossing" cannam@6: points in an audio waveform. For the purposes of this plugin, that cannam@6: means those positions at which the sampled value switches from cannam@6: zero-or-less to greater-than-zero, or vice versa. cannam@6:
cannam@6: