Jeffgold commited on
Commit
7e18507
·
1 Parent(s): b902b0c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -7
app.py CHANGED
@@ -82,15 +82,15 @@ def convert_video(video_file: File, quality, aspect_ratio, video_url):
82
  gr.components.Video(output_path)
83
 
84
  # Create a temporary file to store the download link
85
- with tempfile.NamedTemporaryFile(delete=False) as f:
86
- f.write(output_path.encode())
87
- download_link = f.name
88
 
89
  # Add a button to download the file
90
- gr.components.HTML("""
91
- <a href="{}" download="downloaded_file.mp4">Download</a>
92
- """.format(download_link))
93
 
94
  from gradio import outputs
95
 
96
- gr.Interface(convert_video, inputs=[video_file, quality, aspect_ratio, video_url], outputs=[outputs.Video()]).launch(share=False)
 
82
  gr.components.Video(output_path)
83
 
84
  # Create a temporary file to store the download link
85
+ # with tempfile.NamedTemporaryFile(delete=False) as f:
86
+ # f.write(output_path.encode())
87
+ # download_link = f.name
88
 
89
  # Add a button to download the file
90
+ # gr.components.HTML("""
91
+ # <a href="{}" download="downloaded_file.mp4">Download</a>
92
+ # """.format(download_link))
93
 
94
  from gradio import outputs
95
 
96
+ gr.Interface(convert_video, inputs=[video_file, quality, aspect_ratio, video_url], outputs=[outputs.Video()]).launch()