_fy = [] _fz = [] _c = [] _xMap = [] _yMap = [] _zMap = [] #the preceding variables are there for maintaining history and visual representation only if (param.DEBUG==1): ts = time.time() print "System started at {}" .format(datetime.datetime.fromtimestamp(ts).strftime('%Y-%m-%d %H:%M:%S')) for i in range(param.GT_START_INDEX,param.GT_END_INDEX): # !...to replace this loop by something else in an online system...! imageName1 = rd.readFrameStatic(i,param.PATH) imageName2 = rd.readFrameStatic(i+1,param.PATH) IMG1 = param.PATH + imageName1 IMG2 = param.PATH + imageName2 OptFlow = OpticalFlow(IMG1,IMG2,0) features = OptFlow.computeFlow(param.FEATURE_SIZE) #Features of IMG1 prevFeatures= OptFlow.prevFeatures #Features of IMG2 featureSize = len(features) prevFeatureSize = len(prevFeatures) if(featureSize == prevFeatureSize): count = 0