update for bakeup

This commit is contained in:
王庆刚
2024-08-06 20:00:29 +08:00
parent 27d57b21d4
commit 5109400a57
19 changed files with 497 additions and 352 deletions

View File

@ -24,6 +24,8 @@ class TrackAnnotator(Annotator):
frame_index: 帧索引,从 1 开始计数
cls类别编号从 0 开始计数,用作 names 的 key 值
"""
if track.size==0: return
id, cls = track[0, 4], track[0, 6]
if id >=0 and cls==0:
@ -51,6 +53,8 @@ class TrackAnnotator(Annotator):
"""
绘制选定 track 的轨迹
"""
if track.size==0: return
x, y = int((track[0]+track[2])/2), int((track[1]+track[3])/2)
cv2.circle(self.im, (x, y), 6, color, 2)