womenhenzhiliu / changeable_region_detection

A changeable region detection method based on yolov5

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

changeable_region_detection

Yolov5 detection for regional detection

###For the environments:

pip install -r requirements.txt

###For running:

The default weight is yolov5s.pt you can change it by add --weights xxx.pt like:
python detect.py --source data/images --weights xxx.pt

run python detect.py --source data/images for image detection

run python detect.py --source xxx.mp4 for video detection

run python detect.py --source 0 for stream detection use your own camera

The results are saved in yolov5/results/

If you want to change the detection region, go to detect.py line 96 to change the four points:

hl1, wl1, hl2, wl2, hl3, wl3, hl4, wl4

or you can further load points for regional detection

About

A changeable region detection method based on yolov5


Languages

Language:Python 98.8%Language:Shell 0.9%Language:Dockerfile 0.4%