Coyote:
Filter:
sc3-plugins/Classes (extension) | UGens > Analysis

Coyote
ExtensionExtension

an amplitude tracking based onset detector

Description

Coyote is an onset detector which tries to find onset attacks in a signal without using FFT processing. It tracks the amplitude changes in the incoming signal and sends a trigger when an onset is found. To get the best tracking for a particular signal by tweaking the arguments, one needs to understand how the onset detection works inside the UGen:

Coyote compares three different analysis results in parallel and tries to report an onset event in the signal. The first phase is amplitude tracking. The trackFall argument is the 60dB convergence time of the decaying signal(the attack time is constant: 0.001, the process is the same with the Amplitude UGen, trackFall is the releaseTime). The output of this tracking is divided to 3 inputs inside. The first two are smoothers(lowpass filters) with different lag times. slowLag is the lag time of the slow smoother, and the fastLag is the lag time of the fast one. The fast smoother is multiplied by a value(fastMul argument) which should be between 0 and 0.9 so its output is always below the slow smoother, except in onsets. So when an onset occurs, the fast smoother output rises quicker than the slow smoother, and when the fast one exceeds the slower at an instant(occurs only at onsets), a trigger is sent to the output from the UGen. For the next trigger to happen, a specified time should pass which is defined by the minDur parameter. So minDur defines the minimum time between events/triggers.

This approach is extremely fast in response(compared to FFT based detectors) when detecting onsets and works well on most contexts(guitar, percussion, etc...). But it has a drawback when there are sustaining sounds present from the same instrument at the moment of an onset, so there is a third unit inside that averages the input beginning from the last trigger whose output is also smoothed by a smoother(lag time is also set to slowLag) and it too is compared with the output of fast smoother to make the tracking work better when there are sustaining sounds present at the moment of an onset.

The default values are a good starting point and works well on many contexts.

Class Methods

.kr

Arguments:

in

Signal input.

trackFall

60dB convergence time for the initial amplitude tracker.

slowLag

Lag time for the slow smoother.

fastLag

Lag time for the fast smoother.

fastMul

Multiplier for the fast smoother. At the instant of onsets, fast smoother output will exceed the slow smoother and trigger an onset report. If you want to tweak the sensitivity of the tracking, you should try tweaking this value first. Higher values(approaching to 1) makes the tracking more sensitive.

thresh

The minimum threshold for the input to begin tracking onsets.

minDur

Minimum duration between events.

Examples