From cd33ca000903e36beadda352efbb7a159b573543 Mon Sep 17 00:00:00 2001 From: lluis Date: Fri, 6 Sep 2013 19:10:53 +0200 Subject: [PATCH] changed default parameters in CreateERFiltersNM{1,2} functions. They are not needed now in the sample example. --- modules/objdetect/include/opencv2/objdetect/erfilter.hpp | 6 +++--- samples/cpp/erfilter.cpp | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/modules/objdetect/include/opencv2/objdetect/erfilter.hpp b/modules/objdetect/include/opencv2/objdetect/erfilter.hpp index 3906f14..275ed42 100644 --- a/modules/objdetect/include/opencv2/objdetect/erfilter.hpp +++ b/modules/objdetect/include/opencv2/objdetect/erfilter.hpp @@ -172,8 +172,8 @@ public: \param minProbability The minimum probability difference between local maxima and local minima ERs */ CV_EXPORTS Ptr createERFilterNM1(const Ptr& cb = Ptr(), - int thresholdDelta = 1, float minArea = 0.000025, - float maxArea = 0.13, float minProbability = 0.2, + int thresholdDelta = 1, float minArea = 0.00025, + float maxArea = 0.13, float minProbability = 0.4, bool nonMaxSuppression = true, float minProbabilityDiff = 0.1); @@ -191,7 +191,7 @@ CV_EXPORTS Ptr createERFilterNM1(const Ptr& cb = P \param minProbability The minimum probability P(er|character) allowed for retreived ER's */ CV_EXPORTS Ptr createERFilterNM2(const Ptr& cb = Ptr(), - float minProbability = 0.5); + float minProbability = 0.3); } #endif // _OPENCV_ERFILTER_HPP_ diff --git a/samples/cpp/erfilter.cpp b/samples/cpp/erfilter.cpp index 763a966..8a2a45f 100644 --- a/samples/cpp/erfilter.cpp +++ b/samples/cpp/erfilter.cpp @@ -58,7 +58,7 @@ int main(int argc, const char * argv[]) double t = (double)getTickCount(); // Build ER tree and filter with the 1st stage default classifier - Ptr er_filter1 = createERFilterNM1(NULL,1,0.00025,0.13,0.4,true,0.1); + Ptr er_filter1 = createERFilterNM1(); er_filter1->run(grey, regions); @@ -89,7 +89,7 @@ int main(int argc, const char * argv[]) t = (double)getTickCount(); // Default second stage classifier - Ptr er_filter2 = createERFilterNM2(NULL,0.3); + Ptr er_filter2 = createERFilterNM2(); er_filter2->run(grey, regions); t = (double)getTickCount() - t; -- 2.7.4