title: OpenCV4 - Deep Neural Network - dnn.hpp no such file or directory
body: <p>on my Debian laptop I've downloaded and compiled OpenCV4, with contrib extra modules, and everything seems to work fine; I can load an image in a Mat object and I can apply filter to it.</p>
  
  <p>Now I want to try YOLO object detection so I tried to include the Deep Neural Network dnn module in my Qt project with</p>
  
  <pre><code>#include &lt;opencv2/opencv.hpp&gt;
  </code></pre>
  
  <p>but when I compile the code I get this error</p>
  
  <pre><code>error: opencv2/dnn.hpp: No such file or directory
  </code></pre>
  
  <p>I've looked for OpenCV files, and here where I've found the dnn module</p>
  
  <ul>
  <li>usr/include/opencv</li>
  <li>usr/include/opencv2</li>
  <li>usr/local/include/opencv4/opencv2/dnn</li>
  </ul>
  
  <p>Then I've tried to include </p>
  
  <pre><code>#include &lt;opencv4/opencv2/dnn.hpp&gt;
  </code></pre>
  
  <p>but I get the same error.</p>
  
  <p>Any idea on how to solve this issue?</p>
  
  <p>Thanks in advance for your help.</p>