RizwanMunawar / yolov7-object-tracking

YOLOv7 Object Tracking Using PyTorch, OpenCV and Sort Tracking
GNU General Public License v3.0
576 stars 174 forks source link

The parameter of bbox width and length #33

Open Keke-Long opened 1 year ago

Keke-Long commented 1 year ago

it seems the 224 lane of detect_and_track.py should be: txt_str += " %f %f" % (np.abs(track.bbox_history[-1][0] - track.bbox_history[-1][2]) / im0.shape[1], np.abs(track.bbox_history[-1][1] - track.bbox_history[-1][3]) / im0.shape[0])

the first value divided by im0.shape[1]. im0.shape[1] is the width of the picture and track.bbox_history[-1][0] is the x of object.

Ayaki22 commented 1 year ago

@Keke-Long I'm experiencing a similar issue.