I'm currently developing a Shazam like tool for college where I take a live audio input and output an audio fingerprint to be searched within an internal database. What I have so far is getting a processed stream of audio into a zl.slice with 512 bins of frequencies that range from 0 to 0. Looking to only have the upper quartile of frequencies shown, so if I had the following sample data:
1 2 0 3 2 0 3 1 1 1
It would output this:
0 2 0 3 2 0 3 0 0 0
How can I get this into my patch?
This patcher image shows what I have have done so far
Thanks in advance
Here’s a patch that does what you describe (copy and then choose “New from Clipboard” in Max).
Sort and split the data into two halves.
Calculate median of top half of data, which is the lower threshold of the upper quartile
Iterate through the list, setting values lower than the threshold to 0.