Download Link: YOLOv5m-crowd-human
python detect.py \
--weights <path to weights file> \
--source <path to input video> \
--view-img \
--heads \
--conf-thres 0.5 \
--save
- --weights: path to weights file
- default = "yolov5s.pt"
- --source: path to input image/video, 0 for webcam
- --results-loc: location to store results text file
- default = "runs/detect"
- --img-size:
- --conf-thres: object confidence threshold
- default = 0.25
- --iou-thres: IOU threshold for non-maxima suppression
- default = 0.45
- --device: identifier for CUDA device
- GPU: 0, 1, 2 or 3 for
- CPU: cpu
- --view-img: View tracking results live
- --save: save resulting video
- --colab: Run inference on Google Colab
- uses cv2_imshow() which works in colab
- --person: display and uses person detections only
- --heads: displays and uses head detections only