Welcome new user! You can search existing questions and answers without registering, but please register to post new questions and receive answers.
Welcome to JeVois Tech Zone, where you can ask questions and receive answers from other members of the community.

error: nnpack.h: No such file or directory

0 votes

Hi guys,

I tried to install and run the latest Jevois 1.11.0 on Ubuntu 18.04 and met some problems. Although I solved it, I still don't know why. So I would like to ask here to get some ideas.

With a fully new installed Ubuntu 18.04, I used the method mentioned on https://jevois.usc.edu/ to install all Jevois packages. The exact command I used was 'sudo apt-get install jevois-sdk-dev'. And everything went on well. At this step, I assume that everything should be installed on my computer. 

Then I went to my Jevois module (it was written by my colleague, so I am sure it could be built)  and run './rebuild-platform'. But an error was issued, which is list below,

 /var/lib/jevois-build/usr/include/jevoisbase/Components/ObjectDetection/Yolo.H:24:10: fatal error: nnpack.h: No such file or directory

#include <nnpack.h>

         ^~~~~~~~~~

compilation terminated. 

From my understanding, it means that there is no "nnpack.h" file on my computer. The question is that I have already used 'apt-get install' to install Jevoisbase package. Shouldn't the packages/dependencies including "nnpack,h" also be installed on my computer? 

I solved this issue by cloning Jevoisbase repository and went to /jevoisbase/Contrib to execute ./reinstal.sh. After this, my project could be built without errors. 

To make my question clear, why "apt-get install jevoisbase" does not install packages including "nnpack.h" and why do I have to go to jevoisbase source folder to install these manually? 

I am very new to this area, if I asked some very basic or stupid questions, please correct me. Thanks in advance.

asked Jan 6 in Programmer Questions by ls90911 (210 points)

1 Answer

+1 vote
I think you have found a use case that we did not think about: looks like your module is using some of the components in JeVoisBase (here, YOLO). So indeed you do need to install the contrib of JeVoisBase to be able to compile it. Your solution is correct.

The assumption was that user modules would be independent and standalone, thus would not require the contrib dependencies of JeVoisBase.

How are you getting the actual YOLO code into your module? Are you compiling YOLO.C into your module, or are you linking your module against libjevoisbase?

If I am not mistaken, including nnpack.h and darknet.h is not necessary in YOLO.H and could be moved to YOLO.C which should solve the problem in case you are just including YOLO.H and then linking against libjevoisbase.
answered Jan 8 by JeVois (38,060 points)
...