From 6eb94743330b84469efba5cc6e2015bd281c0711 Mon Sep 17 00:00:00 2001 From: haoyuying <18844182690@163.com> Date: Fri, 9 Oct 2020 20:07:20 +0800 Subject: [PATCH] revise transform and add processor --- .../keypoint_detection/openpose_body_estimation/processor.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hub_module/modules/image/keypoint_detection/openpose_body_estimation/processor.py b/hub_module/modules/image/keypoint_detection/openpose_body_estimation/processor.py index 73e91071..e5dc17ca 100644 --- a/hub_module/modules/image/keypoint_detection/openpose_body_estimation/processor.py +++ b/hub_module/modules/image/keypoint_detection/openpose_body_estimation/processor.py @@ -223,8 +223,8 @@ class DrawPose: mY = np.mean(Y) length = ((X[0] - X[1])**2 + (Y[0] - Y[1])**2)**0.5 angle = math.degrees(math.atan2(X[0] - X[1], Y[0] - Y[1])) - polygon = cv2.ellipse2Poly((int(mY), int(mX)), (int(length / 2), self.stickwidth), int(angle), 0, 360, - 1) + polygon = cv2.ellipse2Poly((int(mY), int(mX)), (int(length / 2), self.stickwidth), \ + int(angle), 0, 360, 1) cv2.fillConvexPoly(cur_canvas, polygon, self.colors[i]) canvas = cv2.addWeighted(canvas, 0.4, cur_canvas, 0.6, 0) return canvas -- GitLab