You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 3, 2024. It is now read-only.
1.找到选择device的区域
发现没有进入if语句,查看if语句之前的device.type确定是cpu,但是if判断语句中’cpu’是字符串,而device.type是cpu <class 'torch.device'>所以没有进入if语句。
2.device.type的类别是字符串,修改为device.type。还是报错
分析:追溯是执行vdo_trk.run()是出现问题。查看self.image_track(img0)使用的设备,发现是cpu,没问题。接着查看time_synchronized,发现错误
/home/ahei/DeepSORT_YOLOv5_Pytorch-master/yolov5/utils/torch_utils.py line 53 time_synchronized
原来,首先检查了torch.cuda.is_available()有的话调用了torch.cuda.synchronize(),然而我们的gpu在跑代码显存满了,所以报错。修改如下,问题解决。
The text was updated successfully, but these errors were encountered: