From 161d97e2151ab1896755897cda983d49ef50059d Mon Sep 17 00:00:00 2001 From: Samuel Felton Date: Fri, 20 Sep 2024 18:54:57 +0200 Subject: [PATCH] mestimator setting for silhouetteMe --- .../tracker/rbt/include/visp3/rbt/vpRBSilhouetteMeTracker.h | 3 ++- modules/tracker/rbt/src/features/vpRBSilhouetteMeTracker.cpp | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/modules/tracker/rbt/include/visp3/rbt/vpRBSilhouetteMeTracker.h b/modules/tracker/rbt/include/visp3/rbt/vpRBSilhouetteMeTracker.h index b7f068b4ea..580fbf92c6 100644 --- a/modules/tracker/rbt/include/visp3/rbt/vpRBSilhouetteMeTracker.h +++ b/modules/tracker/rbt/include/visp3/rbt/vpRBSilhouetteMeTracker.h @@ -50,7 +50,7 @@ class VISP_EXPORT vpRBSilhouetteMeTracker : public vpRBFeatureTracker public: vpRBSilhouetteMeTracker() : - vpRBFeatureTracker(), m_me(), m_numCandidates(1), m_globalVVSConvergenceThreshold(1.0), + vpRBFeatureTracker(), m_me(), m_numCandidates(1), m_robustMadMin(1.0), m_globalVVSConvergenceThreshold(1.0), m_singlePointConvergedThresholdPixels(3), m_useMask(false), m_minMaskConfidence(0.f) { } @@ -105,6 +105,7 @@ class VISP_EXPORT vpRBSilhouetteMeTracker : public vpRBFeatureTracker vpMe m_me; //! Moving edge settings unsigned int m_numCandidates; //! Number of best candidates kept when finding correspondence points vpRobust m_robust; //! M-Estimator to filter outliers + double m_robustMadMin; double m_globalVVSConvergenceThreshold; //! Percentage of control points that should have converged to consider VVS as successful double m_singlePointConvergedThresholdPixels; //! Whether a single Control point is considered as converged bool m_useMask; diff --git a/modules/tracker/rbt/src/features/vpRBSilhouetteMeTracker.cpp b/modules/tracker/rbt/src/features/vpRBSilhouetteMeTracker.cpp index 6be651021c..b49b57f8bd 100644 --- a/modules/tracker/rbt/src/features/vpRBSilhouetteMeTracker.cpp +++ b/modules/tracker/rbt/src/features/vpRBSilhouetteMeTracker.cpp @@ -81,7 +81,7 @@ void vpRBSilhouetteMeTracker::extractFeatures(const vpRBFeatureTrackerInput &fra } m_numFeatures = m_controlPoints.size(); - m_robust.setMinMedianAbsoluteDeviation(std::max(m_singlePointConvergedThresholdPixels * 0.5, 1.0) / frame.cam.get_px()); + m_robust.setMinMedianAbsoluteDeviation(m_robustMadMin / frame.cam.get_px()); }