Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

compiling error in face_recognition

I'm new to ROS and OpenCV. I am having trouble in making the face_recognition package work. I get the following error while running catkin_make after cloning the package. My guess is there is a problem with OpenCV integration but i dont know how to correct it. I aslo installed OpenCV latest stable version 3.2 and cv_bridge ROS package. Any help would be appreciated. Thanks in advance. :)

[ 92%] Building CXX object procrob_functional/CMakeFiles/Fserver.dir/src/face_recognition.cpp.o [ 96%] Built target Fclient /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘void FaceRecognitionLib::storeEigenfaceImages()’: /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:333:31: error: ‘cvCopyImage’ was not declared in this scope cvCopyImage(byteImg, bigImg); ^ /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘bool FaceRecognitionLib::learn(const char)’: /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:375:45: error: ‘cvEigenDecomposite’ was not declared in this scope projectedTrainFaceMat->data.fl + ioffset); ^ /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘void FaceRecognitionLib::doPCA()’: /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:553:3: error: ‘CV_EIGOBJ_NO_CALLBACK’ was not declared in this scope CV_EIGOBJ_NO_CALLBACK, ^ /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:558:23: error: ‘cvCalcEigenObjects’ was not declared in this scope eigenValMat->data.fl); ^ procrob_functional/CMakeFiles/face_recognition_lib.dir/build.make:62: recipe for target 'procrob_functional/CMakeFiles/face_recognition_lib.dir/src/face_recognition_lib.cpp.o' failed make[2]: * [procrob_functional/CMakeFiles/face_recognition_lib.dir/src/face_recognition_lib.cpp.o] Error 1 CMakeFiles/Makefile2:3397: recipe for target 'procrob_functional/CMakeFiles/face_recognition_lib.dir/all' failed make[1]: [procrob_functional/CMakeFiles/face_recognition_lib.dir/all] Error 2 make[1]: Waiting for unfinished jobs.... In file included from /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp:42:0: /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘void FaceRecognitionLib::storeEigenfaceImages()’: /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:333:31: error: ‘cvCopyImage’ was not declared in this scope cvCopyImage(byteImg, bigImg); ^ /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘bool FaceRecognitionLib::learn(const char)’: /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:375:45: error: ‘cvEigenDecomposite’ was not declared in this scope projectedTrainFaceMat->data.fl + ioffset); ^ /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘void FaceRecognitionLib::doPCA()’: /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:553:3: error: ‘CV_EIGOBJ_NO_CALLBACK’ was not declared in this scope CV_EIGOBJ_NO_CALLBACK, ^ /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:558:23: error: ‘cvCalcEigenObjects’ was not declared in this scope eigenValMat->data.fl); ^ /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp: In constructor ‘FaceRecognition::FaceRecognition(std::__cxx11::string)’: /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp:413:35: warning: ‘FaceRecognition::it_’ will be initialized after [-Wreorder] image_transport::ImageTransport it_; ^ /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp:411:24: warning: ‘ros::NodeHandle FaceRecognition::pnh_’ [-Wreorder] ros::NodeHandle nh_, pnh_; ^ /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp:50:3: warning: when initialized here [-Wreorder] FaceRecognition(std::string name) : ^ /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp: In member function ‘void FaceRecognition::imageCB(const ImageConstPtr&)’: /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp:340:108: error: ‘cvEigenDecomposite’ was not declared in this scope lizedImg,frl.nEigens,frl.eigenVectArr,0, 0,frl.pAvgTrainImg,projectedTestFace); ^ procrob_functional/CMakeFiles/Fserver.dir/build.make:62: recipe for target 'procrob_functional/CMakeFiles/Fserver.dir/src/face_recognition.cpp.o' failed make[2]: [procrob_functional/CMakeFiles/Fserver.dir/src/face_recognition.cpp.o] Error 1 CMakeFiles/Makefile2:3510: recipe for target 'procrob_functional/CMakeFiles/Fserver.dir/all' failed make[1]: [procrob_functional/CMakeFiles/Fserver.dir/all] Error 2 Makefile:138: recipe for target 'all' failed make: * [all] Error 2

compiling error in face_recognition

I'm new to ROS and OpenCV. I am having trouble in making the face_recognition package work. I get the following error while running catkin_make after cloning the package. My guess is there is a problem with OpenCV integration but i dont know how to correct it. I aslo installed OpenCV latest stable version 3.2 and cv_bridge ROS package. Any help would be appreciated. Thanks in advance. :)

[ 92%] Building CXX object procrob_functional/CMakeFiles/Fserver.dir/src/face_recognition.cpp.o
[ 96%] Built target Fclient
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘void FaceRecognitionLib::storeEigenfaceImages()’:
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:333:31: error: ‘cvCopyImage’ was not declared in this scope
    cvCopyImage(byteImg, bigImg);
                               ^
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘bool FaceRecognitionLib::learn(const char)’:
char*)’:
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:375:45: error: ‘cvEigenDecomposite’ was not declared in this scope
    projectedTrainFaceMat->data.fl + ioffset);
i*offset);
                                             ^
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘void FaceRecognitionLib::doPCA()’:
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:553:3: error: ‘CV_EIGOBJ_NO_CALLBACK’ was not declared in this scope
   CV_EIGOBJ_NO_CALLBACK,
   ^
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:558:23: error: ‘cvCalcEigenObjects’ was not declared in this scope
   eigenValMat->data.fl);
                       ^
procrob_functional/CMakeFiles/face_recognition_lib.dir/build.make:62: recipe for target 'procrob_functional/CMakeFiles/face_recognition_lib.dir/src/face_recognition_lib.cpp.o' failed
make[2]: * *** [procrob_functional/CMakeFiles/face_recognition_lib.dir/src/face_recognition_lib.cpp.o] Error 1
CMakeFiles/Makefile2:3397: recipe for target 'procrob_functional/CMakeFiles/face_recognition_lib.dir/all' failed
make[1]:  *** [procrob_functional/CMakeFiles/face_recognition_lib.dir/all] Error 2
make[1]:  *** Waiting for unfinished jobs....
In file included from /home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp:42:0:
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘void FaceRecognitionLib::storeEigenfaceImages()’:
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:333:31: error: ‘cvCopyImage’ was not declared in this scope
    cvCopyImage(byteImg, bigImg);
                               ^
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘bool FaceRecognitionLib::learn(const char)’:
char*)’:
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:375:45: error: ‘cvEigenDecomposite’ was not declared in this scope
    projectedTrainFaceMat->data.fl + ioffset);
i*offset);
                                             ^
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp: In member function ‘void FaceRecognitionLib::doPCA()’:
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:553:3: error: ‘CV_EIGOBJ_NO_CALLBACK’ was not declared in this scope
   CV_EIGOBJ_NO_CALLBACK,
   ^
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition_lib.cpp:558:23: error: ‘cvCalcEigenObjects’ was not declared in this scope
   eigenValMat->data.fl);
                       ^
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp: In constructor ‘FaceRecognition::FaceRecognition(std::__cxx11::string)’:
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp:413:35: warning: ‘FaceRecognition::it_’ will be initialized after [-Wreorder]
   image_transport::ImageTransport it_;
                                   ^
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp:411:24: warning:   ‘ros::NodeHandle FaceRecognition::pnh_’ [-Wreorder]
   ros::NodeHandle nh_, pnh_;
                        ^
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp:50:3: warning:   when initialized here [-Wreorder]
   FaceRecognition(std::string name) : 
   ^
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp: In member function ‘void FaceRecognition::imageCB(const ImageConstPtr&)’:
/home/dkr92/catkin_ws/src/procrob_functional/src/face_recognition.cpp:340:108: error: ‘cvEigenDecomposite’ was not declared in this scope
 lizedImg,frl.nEigens,frl.eigenVectArr,0, 0,frl.pAvgTrainImg,projectedTestFace);
                                                                              ^
procrob_functional/CMakeFiles/Fserver.dir/build.make:62: recipe for target 'procrob_functional/CMakeFiles/Fserver.dir/src/face_recognition.cpp.o' failed
make[2]:  *** [procrob_functional/CMakeFiles/Fserver.dir/src/face_recognition.cpp.o] Error 1
CMakeFiles/Makefile2:3510: recipe for target 'procrob_functional/CMakeFiles/Fserver.dir/all' failed
make[1]:  *** [procrob_functional/CMakeFiles/Fserver.dir/all] Error 2
Makefile:138: recipe for target 'all' failed
make: * *** [all] Error 2

2