Skip to content

Commit

Permalink
fix detection
Browse files Browse the repository at this point in the history
  • Loading branch information
thang-dao committed Aug 10, 2019
1 parent 734e2a1 commit 0274c70
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions query_tracking.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,15 +78,15 @@ def detect(self):

ret = self.centernet.run(ori_im)
confidences = []
bbox = []
if ret['results'] is not None:
for box in ret['results'][1]:
for i in range(4):
if box[i] < 0:
box[i] = 0
confidences.append(box[4])
np.append(bbox, box[:4], axis=0)
outputs = self.deepsort.update(bbox, confidences, im)
# np.append(bbox, box[:4], axis=0)
np.delete(ret['results'][1], 1, 1)
outputs = self.deepsort.update(ret['results'][1], confidences, im)
if len(outputs) > 0:
bbox_xyxy = outputs[:,:4]
identities = outputs[:,-1]
Expand Down

0 comments on commit 0274c70

Please sign in to comment.