I made a YOLOv4 inference script for both video and image files, easy to use and not complicated.
python yolo_image.py -i street.jpg -o output.jpg
python yolo_video.py -i video.mp4 -o video_out.avi
- Add custom training script
https://github.com/opencv/opencv/blob/master/samples/dnn/object_detection.py https://www.pyimagesearch.com/2020/06/01/opencv-social-distancing-detector/