Hi, if you watch the video of this tutorial you can see at the end of the training and the reportings with tensorboard and utils.plot_results, the code to predict for the test images. You can see it on his jupyter colab.

The command calls detect.py of the yolov5 package with the best weights and on the test images:

!python detect.py --weights runs/train/yolov5s_results/weights/best.pt --img 416 --conf 0.4 --source ../test/images

I hope that helps you :)

Amal Laouaj Nozieres
Amal Laouaj Nozieres

No responses yet