Finding the best parameters for anomally detection in videos

Hello everyone!

I watched HTM school videos, read “On Intelligence”, and tried some examples from nupic repository. And now I’m trying to do a study project with Numenta library, but I’ve stuck with a problem.
My project is about anomaly detection, I would like to build a model to detect temporal anomalies in sequences of frames. For now I use simple sequences with moving geometry figures and as anomalies I change some of the frames for pictures of other figures (like on the picture) and distorted original figures. The frames I use are 64x64 black and white pictures. I use image sensor from vision repo and the model consists of just one layer with spatial pooler, temporal memory, and KNN anomaly detection region in it.
My problem is, even though I feel like I understand what the params of all the algorithms are for, I’m not sure which values for them to choose, and how much influence they have exactly. Can you please suggest some starter params, explain how I should choose them, or suggest me better model configuration, as for now I’m not getting good enough results with my experiments.
Also, what are the best practices for debugging the model? Can I see the sequences that temporal anomaly algorithm learns and other similar stuff?


Thank you!


Have you heard of swarming? That is historically the type of process we use to find the best parameters in a large space. We face similar challenges to DL systems in that there are a lot of parameters that can be changed. And it might make a big difference in some situations but not in others. You will serve yourself in the long run by creating some comparable metric so you can run many models over time and gauge how well they are doing at your task.

You cannot extract the sequences without some form of pooling layer (another topic). But I have a ton of HTM visualizations tools laying around. If you are running NuPIC and you know some JavaScript, you can play with them yourself: How to Run HTM School Visualizations.