theAIGuysCode / yolov4-deepsort

Object tracking implemented with YOLOv4, DeepSort, and TensorFlow.
GNU General Public License v3.0
1.31k stars 745 forks source link

iou_matching.py:39: RuntimeWarning: invalid value encountered in true_divide return area_intersection / (area_bbox + area_candidates - area_intersection) #117

Open jangelRiveaux opened 2 years ago

jangelRiveaux commented 2 years ago

Running for.a video after some frame the algorithm return this exception. i iou_matching.py:39: RuntimeWarning: invalid value encountered in true_divide return area_intersection / (area_bbox + area_candidates - area_intersection) Traceback (most recent call last): File "object_tracker.py", line 266, in app.run(main) File "/usr/local/lib/python3.7/dist-packages/absl/app.py", line 303, in run _run_main(main, args) File "/usr/local/lib/python3.7/dist-packages/absl/app.py", line 251, in _run_main sys.exit(main(argv)) File "object_tracker.py", line 223, in main tracker.update(detections) File "/content/drive/My Drive/Yolov4/yolov4-deepsort/deep_sort/tracker.py", line 69, in update self._match(detections) File "/content/drive/My Drive/Yolov4/yolov4-deepsort/deep_sort/tracker.py", line 127, in _match detections, iou_track_candidates, unmatched_detections) File "/content/drive/My Drive/Yolov4/yolov4-deepsort/deep_sort/linear_assignment.py", line 58, in min_cost_matching indices = linear_sum_assignment(cost_matrix) File "/usr/local/lib/python3.7/dist-packages/scipy/optimize/_lsap.py", line 93, in linear_sum_assignment raise ValueError("matrix contains invalid numeric entries") ValueError: matrix contains invalid numeric entries

It does not always happens. It happen with one video and yolov4 trained for my own problem.