Ask Your Question

How can I debug into function like "cvCreateTreeCascadeClassifier "?

asked 2012-07-21 04:10:29 -0600

lcs gravatar image

updated 2012-07-25 02:38:35 -0600

Kirill Kornyakov gravatar image

Hi,everyone.I'm studying on HAAR training of OpenCV recently. OpenCV supply several tools like opencv_createsamples.exe, opencv_haartraining.exe, etc.And I want to debug into the functions. Who can tell me how to creat my own objects which have the same functions of "opencv_haartraining.exe", then I can debug into it, instead of using OpenCV' tools.

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted

answered 2012-07-22 08:43:43 -0600

Maria Dimashova gravatar image

updated 2012-07-22 08:45:28 -0600

Why are you studing opencv_haartraining application? It's obsolete version of a cascade training. In my opinion opencv_haartraining is more difficult for study than the newer opencv_traincascade. In any case the easiest way to achieve your goals is to build OpenCV from source in debug mode, open it in your favorite IDE and debug the choosen application as you usually do. You don't need to create your 'own objects'.

I also recommend you to try LBP features instead of HAAR. They are real-time even on mobile platforms. But they are supported by opencv_traincascade only ;)

edit flag offensive delete link more

answered 2012-07-21 05:55:11 -0600

yes123 gravatar image

updated 2012-07-21 06:03:43 -0600

There is all code you need available.

Haartraining.exe is compiled from /OpenCV/apps/haartraining/haartraining.cpp

It based all functions from /OpenCV/apps/haartraining/cvhaartraining.cpp

edit flag offensive delete link more


@Maria: (i am writing here because I can't write a comment under your answer) Anyway I believe he is using haartraining because no one knows that traincascade is a newer version... I used haartraining too without knowing of traincascade

yes123 gravatar imageyes123 ( 2012-07-22 12:29:30 -0600 )edit

@yes123 We wrote about it in the user_guide, see 'Important notes' section. Please, advise us where should we mention about this more to be sure that OpenCV users are in the know of this?

Maria Dimashova gravatar imageMaria Dimashova ( 2012-07-23 01:13:12 -0600 )edit

@Maria: Yes! For example In my opinio you should mention it here:

yes123 gravatar imageyes123 ( 2012-07-23 04:08:38 -0600 )edit

@yes123 OK, accept your criticism and valuable suggestion :) We have to update a doc on detection part of the cascade classifier too. Please open an issue in OpenCV redmine, when it'll be available (you may assign it to me).

Maria Dimashova gravatar imageMaria Dimashova ( 2012-07-23 04:46:06 -0600 )edit

@yes123 Issue is opened #2184.

Maria Dimashova gravatar imageMaria Dimashova ( 2012-07-24 13:20:12 -0600 )edit

@Maria: Thanks maria! When SVN will let me download the updates I will test it (now it says: could not open the requested svn filesystem )

yes123 gravatar imageyes123 ( 2012-07-24 18:18:20 -0600 )edit

Our svn repo is no longer available! OpenCV was moved to git All updates you can find and get there.

Maria Dimashova gravatar imageMaria Dimashova ( 2012-07-25 06:14:22 -0600 )edit

Wow didn't know about it, damn i was so used to TortoiseSVN (anyway everywhere in the doc points to the old svn url)

yes123 gravatar imageyes123 ( 2012-07-25 09:13:22 -0600 )edit

Question Tools


Asked: 2012-07-21 04:10:29 -0600

Seen: 2,436 times

Last updated: Jul 25 '12