From 576a59a8588025ba44064eebdff7f59ae7f8d88f Mon Sep 17 00:00:00 2001 From: song Date: Wed, 14 Jun 2023 06:23:15 +0000 Subject: [PATCH 1/2] modify yolov5 parameter Signed-off-by: song --- cv/detection/yolov5/pytorch/README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/cv/detection/yolov5/pytorch/README.md b/cv/detection/yolov5/pytorch/README.md index c502c039..aee6c1e8 100644 --- a/cv/detection/yolov5/pytorch/README.md +++ b/cv/detection/yolov5/pytorch/README.md @@ -47,22 +47,22 @@ Train the yolov5 model as follows, the train log is saved in ./runs/train/exp ### On single GPU $ cd yolov5 - $ python3 train.py --data ./data/coco.yaml --batch-size 32 --cfg ./models/yolov5m.yaml + $ python3 train.py --data ./data/coco.yaml --batch-size 32 --cfg ./models/yolov5s.yaml ### On single GPU (AMP) - $ python3 train.py --data ./data/coco.yaml --batch-size 32 --cfg ./models/yolov5m.yaml --amp + $ python3 train.py --data ./data/coco.yaml --batch-size 32 --cfg ./models/yolov5s.yaml --amp ### Multiple GPUs on one machine $ # eight cards - $ python3 -m torch.distributed.launch --nproc_per_node 8 train.py --data ./data/coco.yaml --batch-size 256 --cfg ./models/yolov5m.yaml --device 0,1,2,3,4,5,6,7 # bash run_dist_training.sh + $ python3 -m torch.distributed.launch --nproc_per_node 8 train.py --data ./data/coco.yaml --batch-size 256 --cfg ./models/yolov5s.yaml --device 0,1,2,3,4,5,6,7 ### Multiple GPUs on one machine (AMP) $ # eight cards - $ python3 -m torch.distributed.launch --nproc_per_node 8 train.py --data ./data/coco.yaml --batch-size 256 --cfg ./models/yolov5m.yaml --device 0,1,2,3,4,5,6,7 --amp + $ python3 -m torch.distributed.launch --nproc_per_node 8 train.py --data ./data/coco.yaml --batch-size 256 --cfg ./models/yolov5s.yaml --device 0,1,2,3,4,5,6,7 --amp ## Test the detector @@ -70,8 +70,8 @@ Train the yolov5 model as follows, the train log is saved in ./runs/train/exp Test the yolov5 model as follows, the result is saved in ./runs/detect: $ cd yolov5 - $ python3 detect.py --source ./data/images/bus.jpg --weight yolov5m.pt --img 640 - $ python3 detect.py --source ./data/images/zidane.jpg --weight yolov5m.pt --img 640 + $ python3 detect.py --source ./data/images/bus.jpg --weight yolov5s.pt --img 640 + $ python3 detect.py --source ./data/images/zidane.jpg --weight yolov5s.pt --img 640 ## Results on BI-V100 -- Gitee From 68e8d196831de38061d38c0dfd35f858178f90ef Mon Sep 17 00:00:00 2001 From: song Date: Thu, 15 Jun 2023 02:27:04 +0000 Subject: [PATCH 2/2] modify yolov5 parameter Signed-off-by: song --- cv/detection/yolov5/pytorch/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cv/detection/yolov5/pytorch/README.md b/cv/detection/yolov5/pytorch/README.md index aee6c1e8..d3c99021 100644 --- a/cv/detection/yolov5/pytorch/README.md +++ b/cv/detection/yolov5/pytorch/README.md @@ -70,8 +70,8 @@ Train the yolov5 model as follows, the train log is saved in ./runs/train/exp Test the yolov5 model as follows, the result is saved in ./runs/detect: $ cd yolov5 - $ python3 detect.py --source ./data/images/bus.jpg --weight yolov5s.pt --img 640 - $ python3 detect.py --source ./data/images/zidane.jpg --weight yolov5s.pt --img 640 + $ python3 detect.py --source ./data/images/bus.jpg --weight ''--img 640 + $ python3 detect.py --source ./data/images/zidane.jpg --weight '' --img 640 ## Results on BI-V100 -- Gitee