modify dotrack module
This commit is contained in:
@ -23,34 +23,6 @@ class doBackTracks(doTracks):
|
||||
|
||||
self.shopcart = ShoppingCart(bboxes)
|
||||
|
||||
# =============================================================================
|
||||
# def array2list(self):
|
||||
# ''' 0, 1, 2, 3, 4, 5, 6, 7, 8
|
||||
# bboxes: [x1, y1, x2, y2, track_id, score, cls, frame_index, box_index]
|
||||
# lboxes:[x1, y1, x2, y2, track_id, score, cls, frame_index, box_index]
|
||||
# '''
|
||||
#
|
||||
# track_ids = set(self.bboxes[:, 4])
|
||||
# lboxes = []
|
||||
# for t_id in track_ids:
|
||||
# idx = np.where(self.bboxes[:, 4] == t_id)[0]
|
||||
# box = self.bboxes[idx, :]
|
||||
#
|
||||
# x = (box[:, 0] + box[:, 2]) / 2
|
||||
# y = (box[:, 1] + box[:, 3]) / 2
|
||||
#
|
||||
# # box: [x, y, w, h, track_id, score, cls, frame_index]
|
||||
# box[:, 2] = box[:, 2] - box[:, 0]
|
||||
# box[:, 3] = box[:, 3] - box[:, 1]
|
||||
# box[:, 0] = x
|
||||
# box[:, 1] = y
|
||||
#
|
||||
# lboxes.append(box)
|
||||
#
|
||||
#
|
||||
# return lboxes
|
||||
# =============================================================================
|
||||
|
||||
def classify(self):
|
||||
'''功能:对 tracks 中元素分类 '''
|
||||
|
||||
|
Reference in New Issue
Block a user