There is a problem when using the Yolov5 trained model to call the computer's built-in camera: TypeError: argument of type "int' is not iterable" solution

After we use Yolov5 to train the model, in order to test the effect of the model, when calling the computer's built-in camera, there is a problem: TypeError: argument of type "int' is not iterable
insert image description here

Solution: Modify the code on line 280 in the utils–>datasets.py file, see below:
insert image description here

After modification, it can be run normally to call the camera on the computer side.
insert image description here

The above is the solution to the problem when using the Yolov5 trained model to call the computer's built-in camera: TypeError: argument of type "int' is not iterable, I hope it can help you, a lot of support, thank you!

Guess you like

Origin blog.csdn.net/qq_40280673/article/details/125181731