From 47d29fea0d69469d102fd2b278d1886853619c67 Mon Sep 17 00:00:00 2001 From: Dipam Vasani Date: Sun, 13 Sep 2020 01:02:53 -0400 Subject: [PATCH] fix non-smoothed boxes output --- inference.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/inference.py b/inference.py index 2202a4b..9aeee60 100644 --- a/inference.py +++ b/inference.py @@ -97,7 +97,8 @@ def face_detect(images): results.append([x1, y1, x2, y2]) - if not args.nosmooth: boxes = get_smoothened_boxes(np.array(results), T=5) + boxes = np.array(results) + if not args.nosmooth: boxes = get_smoothened_boxes(boxes, T=5) results = [[image[y1: y2, x1:x2], (y1, y2, x1, x2)] for image, (x1, y1, x2, y2) in zip(images, boxes)] del detector