Compiling Darknet with opencv-python

Abhijeet Singh picture Abhijeet Singh · Mar 27, 2018 · Viewed 7.5k times · Source

I installed Darknet with CUDA support. I ran

./darknet detector test cfg/coco.data cfg/yolov3.cfg yolov3.weights data/dog.jpg

enter image description here

I want it to run with opencv support. I had already installed opencv.

enter image description here

I compiled darknet with remake/make after making OPENCV=1 in Makefile, but still it is not detecting the installed opencv.

How can I make it to detect the already installed opencv?

I have installed opencv with this command pip install opencv-python --user before installing darknet.

Answer

Bardo91 picture Bardo91 · Jun 16, 2018

You need to install the c++ libraries not just the python wrapper. You can do it from the sources: https://docs.opencv.org/trunk/d7/d9f/tutorial_linux_install.html.