Repository: https://github.com/yxlijun/Pelee.Pytorch by Jun Li
You can run object detection in video using webcam
Pelee: A Real-Time Object Detection System on Mobile Devices NeurIPS 2018
Robert J. Wang, Xiang Li, Charles X. Ling
University of Western Ontario
The official and original Caffe code can be found here.
the pretrained model can be downloaded in peleenet.pth.
Method | 07+12 | 07+12+coco |
---|---|---|
SSD300 | 77.2 | 81.2 |
SSD+MobileNet | 68 | 72.7 |
Original Pelee | 70.9 | 76.4 |
pytorch-Pelee | 71.76 | --- |
the supported version is pytorch-0.4.1 or pytorch-1.0
- tqdm
- opencv
- addict
- pytorch>=0.4
- Clone this repository.
git clone https://github.com/jinyoungHan/pytorch-Pelee.git
- Compile the nms and coco tools:
sh make.sh
- Prepare dataset (e.g., VOC, COCO), refer to ssd.pytorch for detailed instructions.
you can train different set according to configs/*,First, you should download the pretrained model peleenet.pth,then,move the file to weights/
python train.py --dataset VOC\COCO --config ./configs/Pelee_VOC.py
if you train with multi gpu
CUDA_VISIBLE_DEVICES=0,1 python train.py --dataset VOC\COCO --config ./configs/Pelee_VOC.py --ngpu 2
you can evaluate your model in voc and coco
python test.py --dataset VOC\COCO --config ./configs/Pelee_VOC.py --trained_model ./weights/Pelee_VOC.pth
you can test your image, First, download the trained model Pelee_VOC.pth file. Then, move the file to weights/.
python demo.py --dataset VOC\COCO --config ./configs/Pelee_VOC.py --trained_model ./weights/Pelee_VOC.pth --show
You can see the image with drawed boxes as: