YOLO-pytorch
YOLO-pytorch copied to clipboard
darknet to pytorch
trafficstars
YOLO-Pytorch
中文说明
Description
This is a pytorch version of YAD2K。
Original paper: YOLO9000: Better, Faster, Strongerby Joseph Redmond and Ali Farhadi.

Requirements
- Pytorch 0.3.0
- torchvision
- opencv(Requirement for camera and video)
- python 3
Usage
-
Download Darknet model cfg and weights from the official YOLO website.
# for example --- or other version cfg and weights wget http://pjreddie.com/media/files/yolo.weights wget https://raw.githubusercontent.com/pjreddie/darknet/master/cfg/yolo.cfgNote: you can download other types: like
yolo-voc.cfg -
Convert the weights to
.pthpython tools/yad2t.py path-to-yolo-cfg path-to-yolo-weights path-to-output-folderNote: default choose
- copy your
yolo.cfgandyolo.weightsto the directoryconfig - the output folder is
model
- copy your
-
Three demos (picture, camera, video)
-
demo.pypython demo.py pic-path yolo-type --cuda=TrueNote: default choose
- picture in folder
results/demo yolo-typeisyolo: three kinds:[yolo, tiny-yolo-voc, yolo-voc]
- picture in folder
-
demo_cam.pypython demo_cam.py --trained_model=pth_model_from_1 -
demo_video.pypython demo_video.py --demo_path=video_path --trained_model=pth_model_from_1
-