Ask Your Question
0

cmake build error for 'trancascade' app

asked 2019-08-14 06:01:59 -0600

ppgun gravatar image

Hi,

I followed https://docs.opencv.org/master/d7/d9f..., opencv-4.1.1dev to install succesfully opencv on ubuntu16.04.

When i was following https://docs.opencv.org/master/dc/d88... to try use traincascade, i couldnt find the 'traincascade' app in my opencv/build/bin, then i checked /opencv/apps/CmakeLists.txt, i found that the line "ocv_add_app(traincascade)" was commented out, then i uncommented it.

back to /opencv/build, i run command "cmake ." without problem, but next i run command "make", there poped out plenty of errors, mainly telling:

old_ml.hpp error CvFileStorage has not been declared old_ml.hpp error CvFileNode has not been declared
old_ml.hpp error read_split has not been declared

Can someone tell how to fix this? thanks in advance!

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
2

answered 2019-08-15 12:49:35 -0600

berak gravatar image

with opencv 4.1.0, parts of the deprecated c-api were removed, and those tools (which unfortunately heavily relied on it) can no more be built.

note, that training / using cascades also has been superseeded by cnn methods like ssd, which are much faster.

if you really need those cascade tools, you have to checkout the opencv 3.4 branch (any version of it), and build opencv with :

 cmake -DBUILD_opencv_apps=ON
edit flag offensive delete link more

Comments

Hi, thanks so much, i did as you said and now i have it.

ppgun gravatar imageppgun ( 2019-08-15 23:25:55 -0600 )edit

Also, if you really want them in, I am still looking for someone with spare time that wants to pick up this transfering of the cascade principle to OpenCV4.x :D Sadly we didn't find an interested student for this during GSoC2019.

StevenPuttemans gravatar imageStevenPuttemans ( 2019-08-19 09:15:32 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2019-08-14 06:01:59 -0600

Seen: 594 times

Last updated: Aug 15 '19