richardsl commited on
Commit
a226c91
·
verified ·
1 Parent(s): e495ccd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -8,16 +8,15 @@ mp_people_detection = mp.solutions.pose
8
 
9
  # Function to process the video and count unique people
10
  def count_people(video_file):
11
- cap = cv2.VideoCapture(video_file.name)
12
 
13
  with mp_people_detection.Pose(static_image_mode=False) as pose_detector:
14
  unique_people_count = 0
15
- # Logic to count unique people will go here
16
- # This is a placeholder for the actual implementation
17
 
18
  cap.release()
19
  return unique_people_count
20
-
21
  # Create the Gradio interface
22
  iface = gr.Interface(
23
  fn=count_people,
 
8
 
9
  # Function to process the video and count unique people
10
  def count_people(video_file):
11
+ cap = cv2.VideoCapture(video_file) # Use the file path directly
12
 
13
  with mp_people_detection.Pose(static_image_mode=False) as pose_detector:
14
  unique_people_count = 0
15
+ # Your processing logic here
 
16
 
17
  cap.release()
18
  return unique_people_count
19
+
20
  # Create the Gradio interface
21
  iface = gr.Interface(
22
  fn=count_people,