- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi
I am trying to compile opencv example located at /opt/intel/computer_vision_sdk/opencv/share/OpenCV/samples/pvl/facerecognizer.cpp and following instructions in /opt/intel/computer_vision_sdk/opencv/share/OpenCV/samples/README.md. When i run cmake --build . , i get following errors
/opt/intel/computer_vision_sdk/opencv/share/OpenCV/samples/pvl/facerecognizer.cpp:9:27: fatal error: opencv2/pvl.hpp: No such file or directory
I am using computer_vision_sdk_fpga_2018.1.267 for the setup.
Thanks
Yatish
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Mishra Yatish,
I'm not sure how you exactly tested this but I could compile with this steps.
$ cd /opt/intel/computer_vision_sdk/opencv/share/OpenCV/samples
$ sudo mkdir -p samples_build && pushd samples_build
$ cmake /opt/intel/computer_vision_sdk/opencv/share/OpenCV/samples
$ sudo cmake --build .
$ popd
I also used same version of package.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I ran exactly the same commands, maybe some environment variable is not set correctly ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Probably your cmake is too old, please check its version:
cmake --version
Try to add one line to the samples/CMakeLists.txt in your installation, after the messages block:
include_directories(${OpenCV_INCLUDE_DIRS})
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Maksim
cmake version is 3.5.1. Adding that extra include didn't help. I still get the same error.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Came across this issue on Github that details the same issue and how to solve it - https://github.com/opencv/opencv/issues/5989. In a nutshell, if you have a custom install of opencv2 in a local -I
(system include path) directory, let's say /usr/local/myproject/include/opencv2
without objdetect
compiled, and a system one (e.g. older but does include objdetect
) in /usr/include
, then it looks for it in the /usr/include directory. Unfortunately even whereis opencv2 points to the /usr/include directory and I haven't been able to find the same opencv2 folder in the SDK folder that was created. Will update as soon as I find it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks everyone
Peter helped me to root cause the issue. I had another version of OpenCV installed. I uninstalled it and now it works like magic :)
Best Regards
Yatish
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am unable to install the /usr/local/OpenCV as I have a shared machine. What is the solution if we cannot uninstall the root version of open cv?
I see setupvars.sh has only OPENCV_DIR path. What should OpenCV_INCLUDE_DIRS point to?
Did setting include_directories(${OpenCV_INCLUDE_DIRS})help?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page