'real-time' onset detection example

By now I thought I would understand onset detection… but I still thought this little patch would help. For now there is only one native slice object and one in prototype form from examples you’ve seen, but I hope this helps someone else to understand a bit better how these 2 algo differ:


----------begin_max5_patcher----------
4728.3oc6cs0jihik94r9UP3GlnpdSmkjPhK8r0D8Nw9v939x9T2SjA1fcRW
jfC.WUkSGc9ae0ULfAr3pckcMSztbBFzQemqR5ni9i2c2pMIeKHakwOa7qF2
c2e7t6tieI1EtS922s5YuusMxKi+yVsM44mChyWcu3d4AeKme87zv86CRM7L
xRNltMvvK12HH92SdQ8SyxeIJf+aUWI93ygwQA472LTdwCd4aeJLd+ioAayE
TFxF+.4dCjyCf6MfXW1+f.O.L9WxmIzm+dS176qg.yRu9ji4p2OP89SCxnc.
u7vj3JsAh+Z4sAP9gw+h8L+46dG6i60DgXPxli44IwJBg1cxqzwOGJDDZ9KG
BDjC8Fh+i+np9YTvdusuvZfsIQIokgMswRr8IrDANGJ2GmP+0Qga+b42TEDF
qn5cIw4wdOK5J+WogdQF+yjH+yDNJdfzjiw9A72kEqsUjYJ8kjGj9XPr2FAx
.ZjIZJu5l8E.vuZ.EbKaGGjIg8MrMf33bO6FE8q1X6XxI1dCvQEr9WouaSrK
.ceCeANPwkiT0oi8PvfIPHkMNIXnK2GBbYbeaKtvNDHjEPsoJgVMXNTK3MzF
Th.NomoZ87fmkliVkEDwdLZ+7d1GdOeHJL+nePwUxS8hyBC3JHC.3iC9JsWd
lrZThm+yAYYFv9ns1aNgooEmEXgY+iz3SqLBXy1zf25xalVb1MzgqeQfc0Kc
cGtzVY4l0qKjPNDF+4ShKIwACSRgIN3sO3LQElHd93kRPsieX.W7ff3xGl1c
heNSmPRK5FGnN2SyWmracjWdP71WVukZPmxnVuKIcM2owZpe+0AweoGvRF0m
iWDiEI+VyvDtq.Dbdvh9+HVTrxxjiRllcBVVMCVU3EAoRHRhQTGdgQAeIHMi
ZTqjj+cq7Nbnzkuqziv.1eW39v99hKEFKtjYwkRC9Rn54IEW0Kk1Uy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h2KKWy1kpK9GRSXU0PUcs
9AS2he+w7jhNZwRXqViulYeU0NziKVtJ2qgzEmmgohU.D+az9ro6fkrnOye9
t+ef8.+MT
-----------end_max5_patcher-----------
1 Like

I was thinking about making a thread about this a while back, but it seemed to off topic BUT now I have an opportunity to post this.

I was working on this I think shortly after the Hudd Black Box project, and got something really useful even though I’m not really following the algorithm correctly.

The main thing that’s it seems to respond really nicely to fast onsets (check it out on jongly, it picks up waaay more detail than other approaches I’ve used).


----------begin_max5_patcher----------
3812.3oc0bj1baaq7yN+JP079fchNH3kDSh6qpoIstSywXm75jotiGHRHIFy
CURPaq1I429aA.oDoDkCkDjaqlXcficwdhcAVl+5QG0ZT7czzVnmh9MzQG8W
O5niDMwa3n7eeTqPxctAjTwvZ4FGFRiXsZK6iQuiIZWqnknrv3LV.kIFuVow
8orTl+XeWByONh2oddm9dBPDO5SczsJfy33HVp+eR4cMnq1Rn6GU.bbdiyHL
2o9QStJg5xjDiklALGjIF20.dYZXoYMvxwnuUaD1g2E1pqF524.3yO5Q72Zu
mbfNFphGXqJdfNmPsLrD7f9lZ5.ifyAz0NHb.rhneSEQ+lbpzXfwClJfpT.z
UICvRquxY.otwyne49o1DRzDpbgHU233pFhsrVyRxReyjUeCobsNxxPhJ9G6
DgAqgQzjMPYEqoT+IBBcg.IL1iVd.bw1XhKsL6PBG17Y47DNThHAsZiZMNHl
.zVMLG7f5zDv50qJTF8QjPwXaMLwmikMxMwZBUAv+fPYwl+tt9Nx9.JAVQEX
6FRxhkgjw9aV+98yZWiKw4Oi.Mo5YO1KIrD.SLZxUzHxn.ZYKilZtnaHMJrw
RylkbhE70jPhXv1EZBjandWQXrD+QYL5xuklyjx4RbdQPFMdbQyEsWdkWP0F
sWuOfuNYi7xJizOxmAR704CqLpa7S8u2AH.ijyXpsjKTYToSiSX0rtjiTn7T
7gp0jLUqljkR0jbjlQZBGv11+SWSx7ASSZfl1VoKYpdcIkntXbepKa69zFFB
ON5l1csgWC5qgw8wC3anc+dg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FSFMk6s2XRuobu5xkekp
9lijUp16Upz60qx6MWg2qVc2hJ6ttp5le1LO5yO5+CTBmSKC
-----------end_max5_patcher-----------

Lots of room for improvement here, specifically with using a dynamic thresholding as described by the thesis as well. (Right now going from dead silence to the tiniest sound produces a wild differential and subsequently a chattery behavior)

I’ll explore this patch later it looks interesting (and see if I can pinch bits of it for my comparison)

Be curious to see your thoughts. It’s not too different from the main one we have been using except that it uses a median filter instead of a “slow” slide~ to calculate the differential.

The thesis itself (specifically from section 2.3 (pg. 40)) goes into significantly more detail about the algorithms used and tested with my implementation being a pretty sloppy and incomplete one.

I just kind of hit a wall with what to do next with it, and never got around to coming back to it.

The response speed, especially within faster sections is badass, and would really work well in a system that can detect “rolls”.

As a point of reference, the Sensory Percussion system (which I discuss in this thread) has a forking algorithm that detects whether there is a “roll” present and processes the signal differently.

Relevant text from the patent pdf:

Also notable that their lockout is around 3-16ms(!!).

the patented algo, you’ll explore by yourself for obvious reasons :wink:

I’ll check the dynamic - the short vs long thing I gave you during BB is what is in my comparison, and I get results so quick I’d be surprised to match them with a spectral process (which we have coming soon and are already available in SC - check [my comparison of SC](Training for real-time NMF (fluid.nmfmatch~) code) I offered a certain time ago)

Unless I’m mistaken, that word doesn’t think what you think it means in this context.

Their specific implementation is patented, but not the general purpose algorithm surrounding it.

Either way, it can serve as a point of inspiration.

Time vs freq approaches are definitely faster, and for the purposes of brute force onset detection are probably ideal, just a matter of getting it to respond quickly/cleanly.

But have a look at the median filter and see what you think.

the process they describe is quite generic - miller’s bonk does that, faking the stft-mel by a 13 band constant q transform… in the 90s! I will go back to it as I find this interesting actually.

looiking forward to try that - another way to look at context vs specific indeed.

I think they could do a 128 fft so that could explains their time window - I will investigate around there and see.

1 Like

So here is a version comparing the (pa improved) median filter based algo. I made 3 improvements

  1. added an absolute gate to remove the noise floor triggering you spoke about (think of it as low level high variance, so lots of attacks)
  2. raised the highpass to a decent frequency
  3. raised the lowpass to a higher freq and less steep, to remove some of the lag induced by that

It is now pretty nervous and tight :wink: The real take home message though: it is faster on transient but I cannot get it to catch the softer attacks like in my test signals.

Let me know what you think


----------begin_max5_patcher----------
8386.3oc68j1biairedxuBDUuJO6DKYhCdkISdwIaxlYqMG0LIusRkYqonjn
kYLEoVRJ6wuTw+1e3fjhThGfWRxGShkk4APitazMZf93O+nWLZp+GrCGA9bv
uCdwK9yO5EufeI1EdQ7e+hQKs9vLWqP9iMxa8xo1A2O5Lw8n+o+5HW6H9cQw
WckUzrqb7V79.6YQhV2PmLQ4LfoB+WPHl8KDZhB3eG+RW56Eco0La1yqDeMm
47N0e5eLFpkzmhNL5tU1hldTnyBOK2QmAFcoquEsCy1jgN+e7mCR6qLW1yZI
+xitHvg8toCGGusGMzlmCSou+R+414dfn6bEM1H1E9qO5iXeblrXT6aoiuDH
Hx9CbL1nwkfig0hiMzDHWyIpaghyhNI0gNSeqhQJcaL2RtHScHaPoap2VtHz
iUtn1NujPl.0zzLz6DZE+zZxYn0Usd5otJCXAX8cPxYQnvC5zydbTaRkCI8n
V4HbTOyesWz8.E5+Aa6nWSWkiDpbz+fThrFQiIQV0znkhNvOKPNGBUEZlJPt
8XUzSK4wq.A9y+uCAWYM6ZvkA9KAtNgQfOCrxhdUmkqB7uYoMc707IvpZLbO
QWQPBpV9U6lAC2E0jEfrChQHwXDJMww09F6fPGeuLu+KFYsZUlK+hLuBCM9G
97FR+rzK43ItDN8RA123j79poW0JfhVhn3j0AB36CZIBqhovAdqc3fh3hTB5
GkzfoL1bIgPgA.I5BYxESPJTZ+BW+YWaOOCSMEWtx1ywaUfcHk.ZEECbo2dt
8kVqcidewru4u+VSXxeyBYxewnEANy88X.QNTM6xIc2uCfbw6vbCF9S3Yspf
WlxqPQKkbyP5fbc3Tq.FkXpa1IOTNdee272J88bsuLJ91qb771BKF4up7aF3
r3pJd2o9zatrp1lemv2u1Sb22SmuF89Pqaxisirbcim.mu4+fkmyRqH6HGAI
.ojdSaOK5.8pvYA9tt4Fuh6bSA2YNkIdl8sNyitJ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rntFM7cMeeO68kgnpH6Z7
5pAAxH3njk3gG7NdKJPeQWknmwngXYsxzyvgP3BwTxET2USFHFxZIaWkIQzk
jysqyPHxnSfzGaqGQJU.v9nmjRppRezSJsW.CZ364xjv.G9tFOHV+PjUmU+O
nkomGjs5CaJK2bWkEfQxtPHTuOHQxtPHTeSYgRYcQOHr.JEOTebTXPoVaGYH
3VkqqwCwTTnhzLQcFAqHkMCl8RWIKsD1+HTY55AQPuzljg68Asr7P39VkNTV
UL0XPl3L62pHEv5zsJJAaULB1sHDTdwGX6hN.2SNDtPvV9IPpmWrz5CZo4h7
jrzedLByaI3kZf263wf8rg8+lOxTxAFYMalsWTtxSfA6wLvlHnF6a5JlFJj7
uUtBZ.LtMi+PYhZxD1yhodArJq2VtKxnkTn2IAymkZma.mI1DJdHmCzIHrJh
WYEv5HUB+aHchJLF76MvJmWpzWzhoKtzw0Mc.k0wcR7BkQKBrl6jI0wHF+vT
ZGaqV0OqvuksRSHdMTxqoaXPwbmU32180RdKjoBzjyifi4QXeidI3Vukk2h3
xyfdl5fyp.+U9Ao0whIXyzmecje5.M0qVSbmnhIe4mcHGULaUsQBtKNMiPYq
TP7uQGyXyVyYQem+5i9+Aw34+5A
-----------end_max5_patcher-----------
1 Like

Nice!

That works much nicer.

I don’t really understand the latency-counter section, or subsequent sah~s. Are they there to just count~ samples and figure out the difference in timing between them in samples?

From this test is the median one the fastest?

I still get bad nervousness when sending it “raw” audio. (i.e. stop and start playback on jongly to hear what I mean) Is it possible to have the absolute gate earlier in the signal chain to remove that problem altogether?

Also, the output from the differential (aside from the initial nervousness) looks like a stable/clean display of “velocity”. Since it’s all in the audio domain now I would imagine it’s easier (and much faster to extract velocity information from the attacks).

I’m guessing a sah~ after the differential being triggered by the final output of the algorithm BUT going from silence to audio seems to always throw a crazy high value out of the differential.

Or it can just take the minmax~ after the atodb~ like the cleaned up version of your patch does. (pasted below for sake of forum browsing)


----------begin_max5_patcher----------
2577.3ocybs0bihbE9Y6eEcom7jR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OSxdmKLYLlJRulpgJkQ6iUc2YIZ3fh1mYROE0zpWSMg0iPNEFU
.kwLbvPF2PAw44Ml0e+PicvaDQeCdan6Uj9X7oY4LrYh9AkTkt56cvGZRUj9
DssYLLNsqFbcqGO7opOfR8tYppwBga17jMun9t8Sxr0g+R0Fpdt+WSRq9UeW
LlkaeJo498es2lElG8XRoMpbadUmM9lr5b7My0A97zsI05Z.7foz2VGWWPJ1
T++SL7c+41e+1+OfUQU3Y
-----------end_max5_patcher-----------

that was not the take home message. it was: it is more nervous for transient material but does not work well with slower attack types :wink:

yes, most of the time. The sharper the attack, the truer that is.

just raise the absolute threshold (-70 is really low - just check the data you get in ‘silence’ from your real audio and then from the most silence attack you want to detect - in my case it is more around -50 usually)

it won’t be: this is a peak to median differential, so not really perceptually accurate. Should be in the right ballpark though for continuous material, and with the help of my hipass should be a little less influenced by timbre/fundamental/spectrum. To understand what is happening, and this:

you have to understand what the algo is doing. It is a peak follower, on which you have a slope down. 2 examples:

  1. your noisefloor is -70dB, you play a MP snare at -34, you have 36dB dif
  2. you are playing PP snare at -40 and you play a MP snare at -34 (6dB per nuance is quite common in software)

you’ll get a def read of 36, and 6, for 2 similar perceptual shots.

if you took a sah~ at the detected attack of the actual reading of the peak, you might have a non-finished raising envelope

so I prefer mine there, but in line with this, you can decide to reset a minmax~ at the detected attack, then sah~ the maximum out exactly X samples later - with a hipass of 160 you can use 140 samples to be certain you let through half a wave of the lowest amount. again these are guestimates and will work only in certain cases, but it is worth a try…

p

1 Like

Heh, with your mushy bass notes. I didn’t test too thoroughly, but it seemed to work ok even with slow noise attacks. (I didn’t test it with any pitched ones)

In this case the silence was absolute (stopped playback), so the jumping had more to do with the algorithm. (more below)

Ok, so looked and poked a bit further and it looks like the culprit is atodb~ which will spin off into infinity if you keep feeding it with 0. as the slide~ does. I did chuck a clip~ -180 20 after the atodb~ and that helped the “nervousness” some, but only a little, as the first transient after silence is always calculated against -180., but that’s better than -infinity (actually it stops precisely at -6080.165184).

I’m guessing slide~ is sending out nearly zero values ant that’s spinning off atodb~.

I’m not sure what to do there besides sticking in a clip~, but is there another (manual?) way to calculate atodb that doesn’t spin out into infinity when it has an input of zero? I guess zero amplitude is near -6080.165184 dB, so it’s unavoidable.

Yeah, I see that. Once it’s going it looks like velocity, but really isn’t.

I’ll definitely play with this further as having a faster response time is more important (to me) than having it respond to softer attacks in general.

Out of curiosity, did you try it with low (electric) bass notes, or purely the synthetic tones?

you’ll never get that with real signal so save yourself a problem !

at the moment, we are talking about a few samples ahead, so really insignificant. What I’m interested in is accuracy, including less false positives and less misses. I’ll need to continue exploring.

1 Like

The brute latency doesn’t bother me, it’s more the fact that it can respond to multiple hits in fast succession. Even with more sensitive thresh~ settings with your other version, I can’t get it to respond to as many transients as the median version does with something like jongly.

So false positives are no good, but I’m also worried about false negatives.

I understand. I had a few inappropriate jokes here. I’m sure you can put a daddy joke plugin on my reply.

I’ll keep investigating on my side too.

1 Like

Definitely ‘too nervous’, but here’s a version implemented with all that stuff (I think).


----------begin_max5_patcher----------
4290.3oc6c02aaaiF+ua+TvYb3PxpihHoDkzZytk0acqGV2J5K2vv5PfrDss
ZjkLjjaZ1vxm86gj5UaoDkXYmb.KcwQV70m2eH4Oo8mO9QilD+Yd5HzWg9Mz
idze93G8H4sD23Q4e+QiV39YuP2TY0Fw+CeWuqFMVUTfu7lwS93QL6haFsZQ
PTHOS1.R0MiWkUbW876tzMyadPzryR3dYpogA0RybLBiwDM8wHCyhOQ+tnM+
0ier3iw8b5Fwu.lbEyrL9mkixnurUJv5VPA3to.pEVyBHAalslM1hZSrwD36
lDAgQHBRIu0pNL6xkbUSGkFLKxMbzPRq97P2KuBgMzE+1FcqOPzstsPVYoS0
bLHXGGKc3ZIo6fEkr2I8T24sInMGHAMQmnwferszwXKrsPnaYyznVN1DrkkE
ETlE5xDCMJ7Cl3XWnLr63EdwKVvix1fYfKtyz3nrzf+PNVBI1F7GCmV4O3q0
TVLNebUZVvz.O2rf3n5rzVXdXa5FLOaF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LIspF
0W5fY0S5.2g9ZeGHQD7abfDfF.M3z3Z8Z6CsS0pvtyCjkQeowskaZw56HQ1x
Qh0G4F6Z0zoX4aMUwaQJaKGKGvSoiESsxDpMVizdgCsZ.kzWJA2EkPvDM75u
22ffbV5vT2BRnzI+0ikA1PqiBGbK3dYX0jrJGZ7VMzXbe3n5WmtAgJeRFXlT
MBrPdwxObJwvgRuokxFbOD8wKXg9y1oD1TPbMRqscjH8hlFBW68xvxD2tqc7
tenMXsOzjsytyru72aR42vfogsXFTKpkkCwgYaKPsmcGksIgP28Vwh2hhCu3
asdsigdHrFv8wZfYND1c8we7ZSmAxMVuRJ0dmXHh6yPK0z1VuMhmutaVmQeH
Fo9jNmjv25QpO9RDnJc6GIm9x81K1ADbO7ORg0SaynLFwB6XQDIGBILR6nnA
ODSenCigPeix5qrgrOVLlQuhcY6n4XioNNlTFlRTOIlzNJZnkMF8wW.cHzlM
5iEZwzY6xEsOwDwCwxU6UFLq4Xu6LXrn11Fl1DSriHGcAjBs6nrAeIPl2B0f
qmPzM0n5vJLJ2GS6wkOYhaV1PqO2KBYMi2AJcVm9F+da05rw8YEP1CQNer9l
NDtkMGbM38KFj0f0+ZP5eS372MT9WGF+RH7qfy7ZaHY4Vmtv8yrRXGW.T9lb
.WOOdTViC92Vbl+1TGBlItxR2wV2n4K+kFPE.m+pgI+CwS2yuWaylk0Tb.F.
mo9KSlpOvU6z53boUBLoVGo1iV.y9fBS+5R2FDrbifuNRtAwZPnlDIJGnVfY
p7JhkgIdnmVMNp11mX2BtUobXZPXXIAU+LwJN8fQyRb8CpN.fb5GWJsE+Ok.
qwsdUCXhHaFonYV11.mabqWsYyJZEwQG6H0pn4ZUhqfagWqUtQyxepIrpA8+
kIwKiSJe7QznNk0eUVbIgVDbn7nwZW70z5neRQ0AJzasKoLy.TqzIxq.Zl5b
m0rTNYZ4A1QPEO9ud7+S53+mx
-----------end_max5_patcher-----------
1 Like

I think you will like these improvement:

  1. if placed carefully, the clip at the top (in db) sorts 2 problems: too low, and noisefloor so no more need for the condition at the bottom

  2. I removed the useless conditional after my time hysteresis in gen~ - it is built in

  3. the scale at the bottom is between the silence thresh (-60) and the absolute max so you get more sensible values

  4. thresholds are now working for all 3 drumbeats from max, and the timing is almost perfect.

Now, try this on real drums and tell me how they behave.


----------begin_max5_patcher----------
3962.3oc6bs2baaiD+uc9Tfp4lN1MxzD.7YSbu5lqoM2zjlIOtNYR5jghDRB
wTjZHoriam5O62B.RJRIJJJKIa2GdhTnvycWr6hEK+Q96O3fdCh+LKsG5qQu
GcvA+9CN3.YQhBNH+2Gzah2m8C8RkMqG62B77utWeUUQylviBYYx5H4EN0Ky
eLOZzGSX9Ypw1fZqY1GgwXhldejgYw2neMuS7.4vGO3SGa4TY3imkUL954kl
lcUHS15dhB9iG7.wW86HCDwtDljhYHi8YII16q1XdhZi0rAlxwxQyAaScn8Q
lDAaRHqfwralwv4kpJJ6poL0LzKkOJxKrW4XsW37.Vn2UWivF5hOarTP2QrV
ZqS0bMHj9HWr32qTDneeTDj5MdiW9I5DMK3OGaf6crzn1tNB9GSLznveX5pk
Bl2sJB9wSlvhxVRLfaTFfqzrOMKMiOj66kwiiVi.B6PKEPNVTMGPnXa.BHWg
BBtpw+v3nrT9uI4Hg5zRBLC28oKgUIOz2axCWG6sRdXpuOkGo9wSYakAQUeh
XptjAE+WiFC314kDunQ41ApApxvrkdClMY.KocFUrTLzymUkhZZwU4Fr1dAV
K4Hr55pbmvbtfORN7Mp4a0qRmi7lnX2yR3f+fFkaET9j3.V0euJmJ8Q8FFF6
ksu8w56ExtFA6.frPvVMMJ0s5n5EABmv0wzVreiUa62PI2G2uA3XnYarEF1Q
5pvFBbBag0w39HK8V49UrOiw5UIVT43VRKwKKNXv0s52sIcCkKFJkn4ZS0MA
qOCm1DL361MfuYAQSg0cH5RWh45ig1det+v.IwwRJliK3rKufmxGvC4YWUSN
NbXJKm7O1PPvGSqPvgw9myBBR7Fk5mDGFVkD8C49mmMNId1nwUKmE4MHj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UDv
LAmS96Lxp1cJZWsVLXzPdXXICUMs6EYmr2nDu.97zIly+3x0NwyEgc+FupFl
xkciTzMaGGPx0uwqVtaE8h3pick5HzbcDwUPQ3E5kWznb.aaWA0wSShmFmTh
bcMpaY6mkEWxnE1lkYeu4ku5VGcaUTkKxNqcIWyL.0Jch7Jfmot2XMKnO+wC
9+TLsfEG
-----------end_max5_patcher-----------
1 Like

Nice!

I’ll have a further play with this.

On initial/quick test, it seems to act a little funny on brushes, but it could maybe just use further tweaking on the thresh and lockouts to get it to work right.

The maths goes beyond my understanding, but the thesis that this is pulled from does go into more detail in terms of the topology and such.

This is from page 51:

Some (a lot?) of the approach being discussed applies to non-real-time analysis and use, but the pair of moving medians are of particular interest.

you misread hon’ they do a median and a mean. Like we do. But in series, so I’ll read more.

The whole point of this project is for you to be empowered enough to try stuff though, not for me to code it for you, so keep on trying stuff out on this front and I’ll try to finish the JIT-bufnmf with our 2 different algo :wink: . It would be good to know what you don’t understand in my current code for instance…

Yeah, I misread that diagram thinking it was one long series!

Their algo also has the mean/median in the opposite order, which I tried but didn’t get anywhere with it. With the sort of half-and-half version being the most effective one I could come up with.

1 Like

ok this is good as it is implemented in Python and C and open source and maintained. https://aubio.org/ is the website and I’ll start investigating a bit more. @weefuzzy and @groma should be happy too :wink: