Mohammed Innat commited on
Commit
2778924
1 Parent(s): dce10e2

Update posestimate.py

Browse files
Files changed (1) hide show
  1. posestimate.py +2 -2
posestimate.py CHANGED
@@ -1,7 +1,7 @@
1
  import mediapipe as mp
2
  from utils import read_n_resize
3
 
4
- def mp_pose_estimation_fn(image):
5
  mp_drawing = mp.solutions.drawing_utils
6
  mp_drawing_styles = mp.solutions.drawing_styles
7
  mp_pose = mp.solutions.pose
@@ -10,7 +10,7 @@ def mp_pose_estimation_fn(image):
10
  static_image_mode=True,
11
  model_complexity=2,
12
  enable_segmentation=True,
13
- min_detection_confidence=0.5
14
  ) as pose:
15
 
16
  image = read_n_resize(image, read=False)
 
1
  import mediapipe as mp
2
  from utils import read_n_resize
3
 
4
+ def mp_pose_estimation_fn(image, min_detect_conf=0.5):
5
  mp_drawing = mp.solutions.drawing_utils
6
  mp_drawing_styles = mp.solutions.drawing_styles
7
  mp_pose = mp.solutions.pose
 
10
  static_image_mode=True,
11
  model_complexity=2,
12
  enable_segmentation=True,
13
+ min_detection_confidence=min_detect_conf
14
  ) as pose:
15
 
16
  image = read_n_resize(image, read=False)