From fc8ad75cb94ca9c75f1d6df3b732ecb0e488060d Mon Sep 17 00:00:00 2001 From: Ken Haagh Date: Thu, 14 Dec 2023 16:23:39 +0100 Subject: [PATCH] z_pos update Signed-off-by: Ken Haagh --- people_tracking/src/people_tracking/person_detection.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/people_tracking/src/people_tracking/person_detection.py b/people_tracking/src/people_tracking/person_detection.py index 5c1b966..6474cf6 100755 --- a/people_tracking/src/people_tracking/person_detection.py +++ b/people_tracking/src/people_tracking/person_detection.py @@ -161,7 +161,7 @@ def process_latest_image(self): # Extract the values based on the mask masked_pixels = cv_depth_image[mask_depth] - median_color = np.median(masked_pixels) + median_color = cv2.mean(cv_depth_image, mask=mask_depth)#np.median(masked_pixels) # print("Median color:", median_color)