diff --git a/exe/FeatureExtraction/FeatureExtraction.cpp b/exe/FeatureExtraction/FeatureExtraction.cpp index a018731..fe7b2bb 100644 --- a/exe/FeatureExtraction/FeatureExtraction.cpp +++ b/exe/FeatureExtraction/FeatureExtraction.cpp @@ -134,6 +134,8 @@ int main (int argc, char **argv) if (sequence_reader.IsWebcam()) { INFO_STREAM("WARNING: using a webcam in feature extraction, Action Unit predictions will not be as accurate in real-time webcam mode"); + INFO_STREAM("WARNING: using a webcam in feature extraction, forcing visualization of tracking to allow quitting the application (press q)"); + visualizer.vis_track = true; } cv::Mat captured_image; diff --git a/lib/local/FaceAnalyser/src/FaceAnalyser.cpp b/lib/local/FaceAnalyser/src/FaceAnalyser.cpp index 041be6e..72e8c7a 100644 --- a/lib/local/FaceAnalyser/src/FaceAnalyser.cpp +++ b/lib/local/FaceAnalyser/src/FaceAnalyser.cpp @@ -478,20 +478,15 @@ void FaceAnalyser::AddNextFrame(const cv::Mat& frame, const cv::Mat_& det if (online) { AU_predictions_reg_corrected = CorrectOnlineAUs(AU_predictions_reg, orientation_to_use, true, false, success, true); - } - - if(online) - { AU_predictions_reg = AU_predictions_reg_corrected; } - else + + // Useful for prediction corrections (calibration after the whole video is processed) + if (success && frames_tracking_succ - 1 < max_init_frames) { - if (success && frames_tracking_succ - 1 < max_init_frames) - { - hog_desc_frames_init.push_back(hog_descriptor); - geom_descriptor_frames_init.push_back(geom_descriptor_frame); - views.push_back(orientation_to_use); - } + hog_desc_frames_init.push_back(hog_descriptor); + geom_descriptor_frames_init.push_back(geom_descriptor_frame); + views.push_back(orientation_to_use); } this->current_time_seconds = timestamp_seconds;