From 3038cad92b5908eae3982584a27f415c20ea08fd Mon Sep 17 00:00:00 2001 From: Emiliana <38952746+emilianavt@users.noreply.github.com> Date: Sun, 18 Oct 2020 20:35:55 +0200 Subject: [PATCH] Modified how the mouth open feature is calculated. --- tracker.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tracker.py b/tracker.py index 3ff8c56..161503b 100644 --- a/tracker.py +++ b/tracker.py @@ -315,7 +315,7 @@ class FeatureExtractor(): else: features["mouth_corner_inout_r"] = 0. - f = (np.mean([pts[59, 1], pts[60, 1], pts[61, 1]]) - np.mean([pts[65, 1], pts[64, 1], pts[63, 1]])) / norm_distance_y + f = abs(np.mean(pts[[59,60,61], 1], axis=0) - np.mean(pts[[63,64,65], 1], axis=0)) / norm_distance_y features["mouth_open"] = self.mouth_open.update(f, now) f = abs(pts[58, 0] - pts[62, 0]) / norm_distance_x