Update app.py
Browse files
app.py
CHANGED
@@ -5,11 +5,7 @@ import pytube
|
|
5 |
|
6 |
def app(video_link):
|
7 |
downloaded_file_path = download_youtube_video(video_link)
|
8 |
-
|
9 |
-
# Do something with the downloaded video file, such as returning it to the user
|
10 |
-
with open(downloaded_file_path, 'rb') as f:
|
11 |
-
video_data = f.read()
|
12 |
-
# Return the video data here (e.g., send it as a response in a web application)
|
13 |
|
14 |
interface = gr.Interface(fn = app, inputs = [gr.components.Textbox(label="Enter youtube link")],
|
15 |
outputs=[gr.components.Video(label="Your result")]
|
|
|
5 |
|
6 |
def app(video_link):
|
7 |
downloaded_file_path = download_youtube_video(video_link)
|
8 |
+
return downloaded_file_path
|
|
|
|
|
|
|
|
|
9 |
|
10 |
interface = gr.Interface(fn = app, inputs = [gr.components.Textbox(label="Enter youtube link")],
|
11 |
outputs=[gr.components.Video(label="Your result")]
|