libpabod
libpabod copied to clipboard
make fails on Ubuntu 15.04
my machine:
Ubuntu 15.04 (64-bit)
the version of the libraries on my machine:
libmatio-dev:amd64 1.5.2-3build1 amd64
libcv-dev:amd64 2.4.9+dfsg-1ub amd64
libhighgui-dev:amd64 2.4.9+dfsg-1ub amd64
make fails
[ 5%] Building CXX object src/CMakeFiles/pabod.dir/gdetect.cpp.o
In file included from /home/user/libpabod/include/model.h:5:0,
from /home/user/libpabod/include/featPyramid.h:4,
from /home/user/libpabod/include/gdetect.h:4,
from /home/user/libpabod/src/gdetect.cpp:1:
/home/user/libpabod/include/cell.h: In member function ‘void Cell::addIxItem(CvMat*)’:
/home/user/libpabod/include/cell.h:551:46: error: no matching function for call to ‘std::vector<cv::Mat>::push_back(CvMat*&)’
void addIxItem(CvMat * Ix){_Ix.push_back(Ix);};
^
/home/user/libpabod/include/cell.h:551:46: note: candidate is:
In file included from /usr/include/c++/4.9/vector:64:0,
from /home/user/libpabod/include/cell.h:4,
from /home/user/libpabod/include/model.h:5,
from /home/user/libpabod/include/featPyramid.h:4,
from /home/user/libpabod/include/gdetect.h:4,
from /home/user/libpabod/src/gdetect.cpp:1:
/usr/include/c++/4.9/bits/stl_vector.h:913:7: note: void std::vector<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = cv::Mat; _Alloc = std::allocator<cv::Mat>; std::vector<_Tp, _Alloc>::value_type = cv::Mat]
push_back(const value_type& __x)
^
/usr/include/c++/4.9/bits/stl_vector.h:913:7: note: no known conversion for argument 1 from ‘CvMat*’ to ‘const value_type& {aka const cv::Mat&}’
In file included from /home/user/libpabod/include/model.h:5:0,
from /home/user/libpabod/include/featPyramid.h:4,
from /home/user/libpabod/include/gdetect.h:4,
from /home/user/libpabod/src/gdetect.cpp:1:
/home/user/libpabod/include/cell.h: In member function ‘void Cell::addIyItem(CvMat*)’:
/home/user/libpabod/include/cell.h:552:46: error: no matching function for call to ‘std::vector<cv::Mat>::push_back(CvMat*&)’
void addIyItem(CvMat * Iy){_Iy.push_back(Iy);};
^
/home/user/libpabod/include/cell.h:552:46: note: candidate is:
In file included from /usr/include/c++/4.9/vector:64:0,
from /home/user/libpabod/include/cell.h:4,
from /home/user/libpabod/include/model.h:5,
from /home/user/libpabod/include/featPyramid.h:4,
from /home/user/libpabod/include/gdetect.h:4,
from /home/user/libpabod/src/gdetect.cpp:1:
/usr/include/c++/4.9/bits/stl_vector.h:913:7: note: void std::vector<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = cv::Mat; _Alloc = std::allocator<cv::Mat>; std::vector<_Tp, _Alloc>::value_type = cv::Mat]
push_back(const value_type& __x)
^
/usr/include/c++/4.9/bits/stl_vector.h:913:7: note: no known conversion for argument 1 from ‘CvMat*’ to ‘const value_type& {aka const cv::Mat&}’
In file included from /home/user/libpabod/include/gdetect.h:4:0,
from /home/user/libpabod/src/gdetect.cpp:1:
/home/user/libpabod/include/featPyramid.h: In member function ‘void FeatPyramid::setFeat(CvMatND*, int)’:
/home/user/libpabod/include/featPyramid.h:247:14: error: no match for ‘operator=’ (operand types are ‘cv::Mat’ and ‘CvMatND*’)
_feat[i] = feat;
^
/home/user/libpabod/include/featPyramid.h:247:14: note: candidates are:
In file included from /usr/local/include/opencv2/core/mat.hpp:3417:0,
from /usr/local/include/opencv2/core.hpp:59,
from /usr/local/include/opencv2/core/types_c.h:101,
from /usr/local/include/opencv2/core/core_c.h:48,
from /usr/local/include/opencv/cv.h:63,
from /home/user/libpabod/include/image.h:1,
from /home/user/libpabod/include/handlerOpenCVStructs.h:4,
from /home/user/libpabod/include/cell.h:6,
from /home/user/libpabod/include/model.h:5,
from /home/user/libpabod/include/featPyramid.h:4,
from /home/user/libpabod/include/gdetect.h:4,
from /home/user/libpabod/src/gdetect.cpp:1:
/usr/local/include/opencv2/core/mat.inl.hpp:565:6: note: cv::Mat& cv::Mat::operator=(const cv::Mat&)
Mat& Mat::operator = (const Mat& m)
^
/usr/local/include/opencv2/core/mat.inl.hpp:565:6: note: no known conversion for argument 1 from ‘CvMatND*’ to ‘const cv::Mat&’
/usr/local/include/opencv2/core/mat.inl.hpp:3015:6: note: cv::Mat& cv::Mat::operator=(const cv::MatExpr&)
Mat& Mat::operator = (const MatExpr& e)
^
/usr/local/include/opencv2/core/mat.inl.hpp:3015:6: note: no known conversion for argument 1 from ‘CvMatND*’ to ‘const cv::MatExpr&’
In file included from /usr/local/include/opencv2/core.hpp:59:0,
from /usr/local/include/opencv2/core/types_c.h:101,
from /usr/local/include/opencv2/core/core_c.h:48,
from /usr/local/include/opencv/cv.h:63,
from /home/user/libpabod/include/image.h:1,
from /home/user/libpabod/include/handlerOpenCVStructs.h:4,
from /home/user/libpabod/include/cell.h:6,
from /home/user/libpabod/include/model.h:5,
from /home/user/libpabod/include/featPyramid.h:4,
from /home/user/libpabod/include/gdetect.h:4,
from /home/user/libpabod/src/gdetect.cpp:1:
/usr/local/include/opencv2/core/mat.hpp:1103:10: note: cv::Mat& cv::Mat::operator=(const Scalar&)
Mat& operator = (const Scalar& s);
^
/usr/local/include/opencv2/core/mat.hpp:1103:10: note: no known conversion for argument 1 from ‘CvMatND*’ to ‘const Scalar& {aka const cv::Scalar_<double>&}’
/home/user/libpabod/src/gdetect.cpp: In function ‘void applyStructuralRule(Model*, const Cell&, int, int)’:
/home/user/libpabod/src/gdetect.cpp:568:28: error: conversion from ‘CvMat*’ to non-scalar type ‘cv::Mat’ requested
cv::Mat sTmp2 = sTmp;
^
/home/user/libpabod/src/gdetect.cpp: In function ‘void applyDeformationRule(Model*, const Cell&)’:
/home/user/libpabod/src/gdetect.cpp:654:31: error: no matching function for call to ‘std::vector<cv::Mat>::push_back(CvMat*&)’
scoreTmp.push_back(score[i]);
^
/home/user/libpabod/src/gdetect.cpp:654:31: note: candidate is:
In file included from /usr/include/c++/4.9/vector:64:0,
from /home/user/libpabod/include/cell.h:4,
from /home/user/libpabod/include/model.h:5,
from /home/user/libpabod/include/featPyramid.h:4,
from /home/user/libpabod/include/gdetect.h:4,
from /home/user/libpabod/src/gdetect.cpp:1:
/usr/include/c++/4.9/bits/stl_vector.h:913:7: note: void std::vector<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = cv::Mat; _Alloc = std::allocator<cv::Mat>; std::vector<_Tp, _Alloc>::value_type = cv::Mat]
push_back(const value_type& __x)
^
/usr/include/c++/4.9/bits/stl_vector.h:913:7: note: no known conversion for argument 1 from ‘CvMat*’ to ‘const value_type& {aka const cv::Mat&}’
src/CMakeFiles/pabod.dir/build.make:54: recipe for target 'src/CMakeFiles/pabod.dir/gdetect.cpp.o' failed
make[2]: *** [src/CMakeFiles/pabod.dir/gdetect.cpp.o] Error 1
CMakeFiles/Makefile2:137: recipe for target 'src/CMakeFiles/pabod.dir/all' failed
make[1]: *** [src/CMakeFiles/pabod.dir/all] Error 2
Makefile:137: recipe for target 'all' failed
make: *** [all] Error 2
same error on ubuntu 14.02. Any solution?
Hi! It seems that those errors are due to the OpenCV version you are using, which doesn't support anymore the conversion between types 'CvMat' and class 'cv::Mat'. Unfortunately, I'm quite busy these days. So if someone fixes it, please, let me know to add it from a pull request. Best, Manuel
Having same issues...please help me out...
Hi, I have just installed Ubuntu 15.10 and compiled OpenCV 2.4.11 (with g++ version 5.2.1). After installing libmatio 1.5.2 by using apt-get, I have been able to successfully compile the master version of libpabod. So, apologies, but I am not able to reproduce your problem...
It has problems with opencv3.0.....works fine with opencv 2.4...Thanks a lot
Thanks @mjmarin. I still can not "make" it due to the same error message. It seems @Ruling-Alfa is right. The current installed OpenCV on my machine is 3.0.0.
pkg-config --modversion opencv
3.0.0
@rfarid try installing it with openCv 2.4... Works for me
Thanks @Ruling-Alfa for the update. Installing OpenCV 2.4 might crash other programs I have. I might try it if necessary.
Hi @rfarid Have you found any solution?
Hi @25mordad, I did not try it again. I moved on from using libpabod.
@rfarid Thanx, actually I had to switch to windows.