From 1685a9c6a847c236cbd35d691a3eb29adba75dc8 Mon Sep 17 00:00:00 2001 From: Tadas Baltrusaitis Date: Sun, 10 Sep 2017 12:30:19 +0100 Subject: [PATCH] A bug fix with hierarchical models and the multi-view setting. --- lib/local/LandmarkDetector/src/LandmarkDetectorFunc.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/lib/local/LandmarkDetector/src/LandmarkDetectorFunc.cpp b/lib/local/LandmarkDetector/src/LandmarkDetectorFunc.cpp index bd0e460..40b13d9 100644 --- a/lib/local/LandmarkDetector/src/LandmarkDetectorFunc.cpp +++ b/lib/local/LandmarkDetector/src/LandmarkDetectorFunc.cpp @@ -486,11 +486,8 @@ bool LandmarkDetector::DetectLandmarksInImage(const cv::Mat_ &grayscale_i best_detected_landmarks = clnf_model.detected_landmarks.clone(); best_landmark_likelihoods = clnf_model.landmark_likelihoods.clone(); best_success = success; - } - for (size_t part = 0; part < clnf_model.hierarchical_models.size(); ++part) - { - if (hypothesis == 0 || best_likelihood < clnf_model.hierarchical_models[part].model_likelihood) + for (size_t part = 0; part < clnf_model.hierarchical_models.size(); ++part) { best_likelihood_h[part] = clnf_model.hierarchical_models[part].model_likelihood; best_global_parameters_h[part] = clnf_model.hierarchical_models[part].params_global; @@ -499,7 +496,6 @@ bool LandmarkDetector::DetectLandmarksInImage(const cv::Mat_ &grayscale_i best_landmark_likelihoods_h[part] = clnf_model.hierarchical_models[part].landmark_likelihoods.clone(); } } - } // Store the best estimates in the clnf_model