Training max to recognise the path most trodden…
Hi everyone, I have a unique programming challenge. For simplicity I will start this in 2 dimensions but the eventual aim is to scale this up to 3D (4 including time). Imagine you are moving your mouse across the screen, I would like to map a series of note to that movement, not just horizontally but vertically as well so that it is looking at the path of travel in those dimensions and mapping notes to that. Now this is the bit I am having trouble with, imagine you move your mouse without too much precision but following a basic (if messy) path, something like the movements I made with my pen in this jpeg:
I would like to program a patch that looks at all of the paths and identifies the strongest route over all, the path most trodden. I would like that to be the path the notes are mapped to, and I would like the patch to punish the user when s/he strays from the path by more than a certain amount by not playing back notes.
I just happened to revisit zsa.descriptors yesterday. zsa.dist might be a starting point: http://www.e–j.com/?page_id=85
I also know Hidden Markov Models are used for training and recognizing patterns, also in Max, but I have no examples of that.
Yeah, just found this in relation to HMM
Most of the line i drew with my pen might be recognised as the same "pattern" though…
I’ve been told that I might need to look at the line/curve of best fit, would that be right?
depending on the details of what you want to achieve, it might be worth reducing the trajectories as parameterized functions of time, and then getting the derivative. This might provide a more meaningful analysis than a set of mouse positional values…