pjreddie / darknet

Convolutional Neural Networks
http://pjreddie.com/darknet/
Other
25.82k stars 21.33k forks source link

YoloV3 running on video? #725

Open austinmw opened 6 years ago

austinmw commented 6 years ago

If anybody has got YoloV3 running on video would you please tell me your versions of CUDA & OpenCV, as well as if you had to make any modifications to OpenCV?

Seems like OpenCV 3.4.1 has a bug which prevents compiling, but 3.4.0 doesn't support V3 layers? Or am I mistaken?

AlexeyAB commented 6 years ago

Darknet works well with OpenCV 3.4.0

wait1988 commented 6 years ago

why so much memory used with yolo models?

austinmw commented 6 years ago

AlexeyAB I had a problem with OpenCV 3.4.0 saying it did not recognize a layer type (I think it was skip layer) using a YoloV3 config file. No issues with this for you?

AlexeyAB commented 6 years ago

Darknet Yolo v3 works well with OpenCV 3.4.0. But OpenCV-dnn module doesn't contain Yolo v3.

austinmw commented 6 years ago

I'm a bit confused. So you're saying that Yolo v3 is compatible with OpenCV 3.4.0, but OpenCV 3.4.0 is not fully compatible with Yolo v3, so the end result is that they will not work together?

TheMikeyR commented 6 years ago

@austinmw He is saying that you can use YoloV3 together with OpenCV 3.4.0 to display images, process live video etc.

But you are not capable of using OpenCV's deep neural network module which contains a YOLO version, but unfortunately it doesn't contain yolov3 yet. https://docs.opencv.org/3.4.1/da/d9d/tutorial_dnn_yolo.html

OpenCV is a library which contains 100 of different modules which makes it easy to go from idea to execution. So Darknet is capable of using YOLO modules to e.g. show images, video, generating bounding boxes on the images/videoes etc. but the module inside opencv which can detection, classification of images doesn't contain a version of yolov3 yet.

Hope this clarify it.

austinmw commented 6 years ago

BTW @AlexeyAB got your fork working great, thanks!!

Clara85 commented 6 years ago

For the dog.jpg image detection, the original yolo takes me 0.032142 seconds, while @AlexeyAB , your version needs 0.054932 seconds. Any idea why? (With the same threshold, the results are slightly different, there's one more label generated in your version) But overall, time of loading the net is much faster in your version. Thanks a lot!

Clara85 commented 6 years ago

CUDA 9.1 and OPENCV 3.4.0 so far work perfectly for me.

minmummax commented 6 years ago

why so slow?

saiteja011 commented 6 years ago

i am using cuda 8.0 cudnn v6 and opencv 3.2.0 and yolov3 gets trained and detects very well.

saiteja011 commented 6 years ago

can anyone tell me how to save all the predicted images in a folder . i am using darknet pjreddie repository where i get to see predictions in the same folder but when i run another image the old prediction disappers and is updated with the new prediction . thank you in advance.

MGO29 commented 5 years ago

Rename existing image name

NiksanJP commented 5 years ago

I had the same problem here take my code it works. https://github.com/NiksanJP/ImageAI-Live-Detection