HaroldSP / Harold

GNU General Public License v3.0
7 stars 0 forks source link

Error during darknet-nnpack install #1

Open Deca opened 4 years ago

Deca commented 4 years ago

Hi, I'm trying too to run yolo on rpi4, I've found your wiki and actually stuck at the step 2

After cloning darknet-nnpack and running "make" I get this error. It seem unable to find some opencv modules, by the way I followed also your guide to manually install opencv 4.3.0

`pi@raspberrypi:~/darknet-nnpack $ make

gcc -Iinclude/ -Isrc/ -DOPENCV pkg-config --cflags opencv -DNNPACK -DNNPACK_FAST -Wall -Wno-unknown-pragmas -Wfatal-errors -fPIC -march=native -Ofast -DOPENCV -DNNPACK -DNNPACK_FAST obj/captcha.o obj/lsd.o obj/super.o obj/art.o obj/tag.o obj/cifar.o obj/go.o obj/rnn.o obj/segmenter.o obj/regressor.o obj/classifier.o obj/coco.o obj/yolo.o obj/detector.o obj/nightmare.o obj/darknet.o libdarknet.a -o darknet -lm -pthread pkg-config --libs opencv -lnnpack -lpthreadpool libdarknet.a /usr/bin/ld: cannot find -lopencv_contrib /usr/bin/ld: cannot find -lopencv_legacy /usr/bin/ld: cannot find -l-lnnpack collect2: error: ld returned 1 exit status make: *** [Makefile:105: darknet] Error 1 pi@raspberrypi:~/darknet-nnpack $

`

HaroldSP commented 4 years ago

Hi

Did you check the step 3? It seems like it can't find opencv.pc file, it is step 3.1, you can read the full article, there's a link over there. It is not that hard, but if it doesn't help - text here. Also check step3.2.

This evening if we have some time we are going to install it on a new fresh raspberry pi 4. @alekseika7 @AlexSeverin

Deca commented 4 years ago

Thanks for th reply Yes I've already followed the step 3.X and installed the required packages since I previously got the error about opencv.pc missing file and was very specific. Anyway I removed the opencv /build folder and repeated the building steps and opencv seems installed correctly...the comamnd 'cv2.version' return me '4.3.0' Still when I try to launch 'make' on darknet-nnpack I get the same error mentioned above.

In the step 4.2 when you git cloned darknet-nnpack in NNPACK folder? Probabily not relevant but my case I installed it in /home/pi/

HaroldSP commented 4 years ago

Hi!

In the step 4.2 when you git cloned darknet-nnpack in NNPACK folder? Probabily not relevant but my case I installed it in /home/pi/

That should be alright, I did the same in my case. Yesterday evening we also encountered several errors on the other Pi, so right now we are checking how to fix them.

Deca commented 4 years ago

Thanks, keep it updated! Perhaps in the meantime I can try to build a less recent version of opencv

aidamanzano commented 4 years ago

Hi @Deca I was having the same issue as you, and @HaroldSP steps worked for me, so I did sudo find / -iname opencv.pc and I got find: ‘/run/user/1000/gvfs’: Permission denied, so then I did export PKG_CONFIG_PATH=/run/user/1000/gvfs and after that sudo apt-get install pkg-config and sudo apt-get install libopencv-dev and then make worked. When I installed OpenCV I just did sudo apt-get install python-opencv