AlexeyAB / darknet

YOLOv4 / Scaled-YOLOv4 / YOLO - Neural Networks for Object Detection (Windows and Linux version of Darknet )
http://pjreddie.com/darknet/
Other
21.58k stars 7.95k forks source link

darknet.py #5175

Open fused-byte opened 4 years ago

fused-byte commented 4 years ago

Is darknet.py optimised to run in minimal time? Is it slower than the usual detection time?

VolkovAK commented 4 years ago

Time is the same, because python just use C++ library for detection and post-processing.

fused-byte commented 4 years ago

Does detection depend upon the input resolution of the image? My network is trained on 640x192. I asked this question because the Pytorch implementation of YOLOv3 is doing detection in 26ms while the darknet based yolo-tiny is doing detection in 47ms.

VolkovAK commented 4 years ago

Yes, it does. Such big difference is strange, did you compiled Darknet with CUDA=1, OPENCV=1, CUDNN=1 in makefile?

fused-byte commented 4 years ago

Yes. I checked my GPU usage as well.

folkien commented 3 years ago

@fused-byte Do you solved this issue? I have 37 FPS with darknet binary run and about 30FPS when ruining code from python. Maybe problem is in my python code which uses opencv video reader/decoder not compiled for GPU?