NuPIC Geospatial Running Error



After running the file of Nupic Geospatial, I get a darkened, watermarked map(which states ‘only for development purposes’). The interface displayed in the screenshots and tutorials of this application is not displayed and I can only see the map. I found the following warnings/errors on chrome’s java console:
Does anyone know a solution for this, or has faced any similar issues?


This is a pretty old app, using a pretty old Google Maps API. I have not run it in a long time. I know that you need to set up Google Maps API keys somehow. That is probably your first step.


I got this thing working a while back and tested it on multiple samples as well and it worked great. Recently I tried a new data file and instead of getting red/green points, the output points were grey. Any reason why that would happen?


Probably because the anomaly likelihood or score is not being produce properly, and is not a float value. Look through the logs coming out of NuPIC and the web console for errors.


This was happening as not enough data points were available and timestamps of consecutive points were far apart. So I made a bigger file with more points and smaller differences in timestamps.
One thing I noticed was that output went from showing a route from red to green (without any orange) after encountering just the second instance of the route.
Also for a route which was learned and shown green , a new route with just a slight deviation at the end was shown completely red whereas only the small deviation should have shown red.


This doesn’t make sense to me. How would it already be giving back high anomaly scores if it had not encountered anomalous data yet? Something else is wrong. Can you share your code?


I am running the code provided on Geospatial GitHub with different gpx files.
I think I framed my doubt wrong. So I have three days of data on that route. On day 1 the route shows up as red since it hasn’t been encountered(pic not included). On the next days it turns green(pic included). Day 3’s route (pic included) is a minor deviation at the end. According to my understanding it should have shown that route green as well and red at point of deviation


Yes exactly. Something is wrong with that route’s input data. Is there anything different about it? Is it a different time of day?


Nope they are all at the same time. That’s another thing I tested. Where a same route encountered at a different time should show as red it shows up as green. This seems quite odd because the code is using opf ModelFactory and other examples like hot gym that use opf are taking into account the temporal aspects while predicting anamolous or not. The same is not happening for Geospatial.


Can you share the input route files you’re using? I know this works, I’ve made videos about it. I can’t figure out what is wrong without seeing some details like data or code.


I have emailed you a few files. Please do have a look


@ansh979 Ok I looked at your routes, and I have some comments.

First of all, you only have 3 days of data, which is not much at all yet. So you can’t draw too many conclusions without seeing more patterns. For example, there could be weekly patterns that will not be exposed at this time scale, and the algorithm will have no chance to learn them.

Second, you must use the -t option when running NuPIC over the input data so that timestamp will be encoded:

You’ll get better results this way, but this will not resolve the issue you are pointing out. Your question is why was the 3rd day more anomalous than the 2nd, and to answer that, we need to look closely at where each of these routes start:





This one starts behind where Day 1 started, and is anomalous until it realizes it has seen this sequence before the day before.



This one is very anomalous because it has seen two routes before (starting at different places) and at no point is one more probable than the other.

Short story is that you need more data. :slight_smile: