Mercurial Hosting > traffic-intelligence
comparison scripts/classify-objects.py @ 912:fd057a6b04db
corrected bug
author | Nicolas Saunier <nicolas.saunier@polymtl.ca> |
---|---|
date | Wed, 28 Jun 2017 16:51:17 -0400 |
parents | 3dd5acfa1899 |
children | 063d1267585d |
comparison
equal
deleted
inserted
replaced
911:3dd5acfa1899 | 912:fd057a6b04db |
---|---|
93 if frameNum%50 == 0: | 93 if frameNum%50 == 0: |
94 print('frame number: {}'.format(frameNum)) | 94 print('frame number: {}'.format(frameNum)) |
95 if undistort: | 95 if undistort: |
96 img = cv2.remap(img, map1, map2, interpolation=cv2.INTER_LINEAR) | 96 img = cv2.remap(img, map1, map2, interpolation=cv2.INTER_LINEAR) |
97 for obj in objects: | 97 for obj in objects: |
98 if obj.getFirstInstant() >= frameNum: # if images are skipped | 98 if obj.getFirstInstant() <= frameNum: # if images are skipped |
99 obj.initClassifyUserTypeHoGSVM(speedAggregationFunc, pedBikeCarSVM, bikeCarSVM, classifierParams.maxPedestrianSpeed, classifierParams.maxCyclistSpeed, classifierParams.nFramesIgnoreAtEnds) | 99 obj.initClassifyUserTypeHoGSVM(speedAggregationFunc, pedBikeCarSVM, bikeCarSVM, classifierParams.maxPedestrianSpeed, classifierParams.maxCyclistSpeed, classifierParams.nFramesIgnoreAtEnds) |
100 currentObjects.append(obj) | 100 currentObjects.append(obj) |
101 objects.remove(obj) | 101 objects.remove(obj) |
102 | 102 |
103 for obj in currentObjects: | 103 for obj in currentObjects: |