Forums > MaxMSP

Grain Analysis – Mean Amplitude and Dominant Frequency

February 25, 2010 | 7:10 pm

Hi – I am trying to analyze the mean amplitude and dominant frequencies of individual grains within a larger sample, then organize those grains in a list according to these attributes. I realize that this is a job better suited for non-real time analysis, such as MATLAB, but would like to be able to do it in Max as to record a sample and organize its grains in real time. I am struggling with an approach making use of [avg~], [pitch~] and [gate] but am not having very much luck. I was curious if anyone could give some suggestions or post a basic patch to nudge me in the right direction.

Thanks for your help!



MIB
February 25, 2010 | 7:24 pm

I don’t really have anything overly useful to say other than you might want to have a look at the IRCAM ftm library for storage and sorting. It’s very fast and flexible. There is also gbr from IRCAM (might come with ftm, can’t remember) which does some nifty stuff with audio…


February 25, 2010 | 8:19 pm

ftm.ircam.fr

check the catart package, it does exactly this

pa


February 25, 2010 | 9:05 pm

Do you know lisp programming? This would be easy to do in lisp:

http://music.columbia.edu/~brad/maxlispj/

brad

http://music.columbia.edu/~brad


February 25, 2010 | 11:07 pm

Thanks for the replies :)

i should stress that i’m not very concerned about the list sorting, that’s simple enough to do with coll and a few objects, or even with js. i’m much more interested in solutions for the grain amp and freq analysis. would lisp help for this, brad?

are the ftm objects useful for the grain analysis? Or just list sorting? on my computer, it seems the ftm objects can’t be opened. im on mac os x, 10.6. It says "the following disk image cannot be recognized." would someone be able to post the externals (if they are useful for grain analysis) ?


February 26, 2010 | 12:34 am

on a sample (or event vector) level, lisp probably wouldn’t be best. It’s good at structuring lists, doing all kinds of data-manipulation, etc. If you’re asking about the direct analysis of the incoming audio data stream, then you’ll probably have to do some C-coding or find an external that can do this (maybe FTM? I don’t know that package well… or maybe Eric Lyon’s FFTease objects have something that could help).

brad

http://music.columbia.edu/~brad


February 26, 2010 | 3:45 am

for the frequency analysis, you could maybe use zsa.freqpeak~ from the zsa.descriptors (http://www.e–j.com/?page_id=83) package to get the highest n peaks from a signal. run it over your windowed data.


February 26, 2010 | 3:57 pm

the zsa objects are incredible. precisely the kind of thing i was looking for. many thanks, tdaeik (and to mikhail and ej).


Viewing 8 posts - 1 through 8 (of 8 total)