dorian3d / DBoW2

Enhanced hierarchical bag-of-word library for C++
Other
866 stars 370 forks source link

DLib error while installation in ubuntu 14.04 #9

Closed Fahimkh closed 8 years ago

Fahimkh commented 9 years ago

Hello @dorian3d ,

I am getting this error in ubuntu 14.04

[ 3%] Building CXX object CMakeFiles/DLib.dir/src/DVision/SurfSet.cpp.o /home/faheem/My Research Project Data/DLib-master/src/DVision/SurfSet.cpp:29:42: fatal error: opencv2/nonfree/features2d.hpp: No such file or directory

include <opencv2/nonfree/features2d.hpp>

                                      ^

compilation terminated. make[2]: * [CMakeFiles/DLib.dir/src/DVision/SurfSet.cpp.o] Error 1 make[1]: * [CMakeFiles/DLib.dir/all] Error 2 make: *\ [all] Error 2

can you help me in this case

dorian3d commented 9 years ago

Hey @Fahimkh, Latest OpenCV version changed some directory structure. The quickest fix is to change the few include directives that cause troubles in DLib/DBoW/etc. The correct include path depends on the OpenCV verison you use.

ac4fun commented 8 years ago

@dorian3d I used opencv2.4.9 and DLib for Kintinuous as https://github.com/mp3guy/Kintinuous/blob/master/build.sh but there are some problems when doing the command "make -j8" in line 80.

I want to know how this error happen? there are some complier problem like this: /home/kingsley/workspace/Kintinuous/deps/DLib/src/DVision/Matches.cpp:14:28: fatal error: opencv2/core.hpp: No such file or directory

include <opencv2/core.hpp>

I guess this may be the problem of version, and another problem maybe the syntax problem: In file included from /home/kingsley/workspace/Kintinuous/deps/DLib/src/DVision/ImageFunctions.cpp:13:0: /home/kingsley/workspace/Kintinuous/deps/DLib/include/DVision/ImageFunctions.h:38:52: error: ‘KeyPoint’ in namespace ‘cv’ does not name a type static cv::Mat getPatch(const cv::Mat &im, const cv::KeyPoint &kp,

I don't know if the problems may exist in the next two library: DBoW2, DLoopDetector or I should change the version of opencv.

Thanks very much for your help, My operating system version is Ubuntu 14.04 x64 Thank you~

dorian3d commented 8 years ago

Last version expects OpenCV 3 at least. You can try fixing the include directives, though, see https://github.com/dorian3d/DLib/issues/7