Artificial-superintelligence commited on
Commit
cd91b22
·
verified ·
1 Parent(s): 3531315

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -2
app.py CHANGED
@@ -61,6 +61,9 @@ def gradio_interface():
61
  # Download and Crop button
62
  process_btn = gr.Button("Download and Crop Video")
63
 
 
 
 
64
  # Define the action on button click
65
  def process_video(url, start_time, end_time):
66
  status_message.value = "Downloading video..."
@@ -76,8 +79,7 @@ def gradio_interface():
76
  status_message.value = "Error downloading video. Please check the URL."
77
  return None, status_message.value
78
 
79
- # Output the cropped video and status message
80
- output_file = gr.File(label="Download Cropped Video")
81
  process_btn.click(process_video, inputs=[url_input, start_time_input, end_time_input], outputs=[output_file, status_message])
82
 
83
  return demo
 
61
  # Download and Crop button
62
  process_btn = gr.Button("Download and Crop Video")
63
 
64
+ # Output the cropped video and status message
65
+ output_file = gr.File(label="Download Cropped Video")
66
+
67
  # Define the action on button click
68
  def process_video(url, start_time, end_time):
69
  status_message.value = "Downloading video..."
 
79
  status_message.value = "Error downloading video. Please check the URL."
80
  return None, status_message.value
81
 
82
+ # Bind button click to processing function
 
83
  process_btn.click(process_video, inputs=[url_input, start_time_input, end_time_input], outputs=[output_file, status_message])
84
 
85
  return demo