Chaerin5 commited on
Commit
97497a2
·
1 Parent(s): 735c5d1

enable zerogpu

Browse files
Files changed (1) hide show
  1. app.py +3 -0
app.py CHANGED
@@ -256,6 +256,7 @@ hands = mp_hands.Hands(
256
 
257
  @spaces.GPU(duration=120)
258
  def get_ref_anno(ref):
 
259
  if ref is None:
260
  return (
261
  None,
@@ -267,8 +268,10 @@ def get_ref_anno(ref):
267
  img = ref["composite"][..., :3]
268
  img = cv2.resize(img, opts.image_size, interpolation=cv2.INTER_AREA)
269
  keypts = np.zeros((42, 2))
 
270
  if REF_POSE_MASK:
271
  mp_pose = hands.process(img)
 
272
  detected = np.array([0, 0])
273
  start_idx = 0
274
  if mp_pose.multi_hand_landmarks:
 
256
 
257
  @spaces.GPU(duration=120)
258
  def get_ref_anno(ref):
259
+ print("inside get_ref_anno")
260
  if ref is None:
261
  return (
262
  None,
 
268
  img = ref["composite"][..., :3]
269
  img = cv2.resize(img, opts.image_size, interpolation=cv2.INTER_AREA)
270
  keypts = np.zeros((42, 2))
271
+ print("ready to run mediapipe")
272
  if REF_POSE_MASK:
273
  mp_pose = hands.process(img)
274
+ print("processed mediapipe")
275
  detected = np.array([0, 0])
276
  start_idx = 0
277
  if mp_pose.multi_hand_landmarks: