Pavankunchala commited on
Commit
2923f3c
1 Parent(s): 5aa6d90

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -7
app.py CHANGED
@@ -82,19 +82,16 @@ if app_mode == "Run on Image":
82
  st.image(result_image,use_column_width= True)
83
  if app_mode =='Run on Video':
84
  st.markdown('Running on Video')
85
- use_webcam = st.sidebar.button('Use Webcam')
86
  video_file_buffer = st.sidebar.file_uploader("Upload a video", type=[ "mp4", "mov",'avi','asf', 'm4v' ])
87
  tfflie = tempfile.NamedTemporaryFile(delete=False)
88
  stop_button = st.sidebar.button('Stop Processing')
89
  if stop_button:
90
  st.stop()
91
  if not video_file_buffer:
92
- if use_webcam:
93
- vid = cv2.VideoCapture(0)
94
-
95
- else:
96
- vid = cv2.VideoCapture(DEMO_VIDEO)
97
- tfflie.name = DEMO_VIDEO
98
 
99
 
100
  else:
 
82
  st.image(result_image,use_column_width= True)
83
  if app_mode =='Run on Video':
84
  st.markdown('Running on Video')
85
+
86
  video_file_buffer = st.sidebar.file_uploader("Upload a video", type=[ "mp4", "mov",'avi','asf', 'm4v' ])
87
  tfflie = tempfile.NamedTemporaryFile(delete=False)
88
  stop_button = st.sidebar.button('Stop Processing')
89
  if stop_button:
90
  st.stop()
91
  if not video_file_buffer:
92
+
93
+ vid = cv2.VideoCapture(DEMO_VIDEO)
94
+ tfflie.name = DEMO_VIDEO
 
 
 
95
 
96
 
97
  else: