I am looking to find an algorithm/method by which I can detect regions of flow in a video. The video is that of a grayscale heatmap where the majority of the image is not in motion. The areas that are in motion generally appear as flickering/moving white dots, whereas in the rest of the image the dots do not move. The easiest way to visualize this is to think of a TV screen with noise, but the noise is only changing in certain areas; I would like to detect these areas.
The current method being implemented to do so is simply to calculate the standard deviation of each pixel over time and use this as a rough estimate of movement. While this does produce the desired image, and it is rather fast, I'm not a huge fan of the method because it doesn't care about how fast things are changing (std(sin(x) == std(sin(2x))).
Based off of this paper by the University of Texas, I tried to estimate regions of flow by the Black and Anandan algorith. Specifically, I used this piece of Matlab code produced by Brown University. Unfortunately, not only does it take forever to run, but it really does not seem to be working (shows areas of high flow where there most certainly is not any). I don't have much of a background in image/signal processing so it is entirely possible that I'm messing up the implementation, but I don't think this is the case.
My question is this: can anyone think of any alternatives I could use that help to estimate regions of flow? Also, am I wrong in thinking that the current method (taking the standard deviation wrt. time) is flawed?
Thanks in advance for any help.