Spaces:
Runtime error
Runtime error
Salman11223
commited on
Commit
•
aecb38a
1
Parent(s):
63ba6cc
Update app.py
Browse files
app.py
CHANGED
@@ -1,6 +1,7 @@
|
|
1 |
from translate import Translate # Import the Translate class
|
2 |
import gradio as gr
|
3 |
import os
|
|
|
4 |
|
5 |
def app(video_path, original_language, target_language):
|
6 |
translator = Translate(video_path, original_language, target_language)
|
@@ -12,8 +13,8 @@ interface_video_file = gr.Interface(
|
|
12 |
fn=app,
|
13 |
inputs=[
|
14 |
gr.Video(label="Video Path"),
|
15 |
-
gr.Dropdown(["English", "German", "
|
16 |
-
gr.Dropdown(["English", "German", "
|
17 |
],
|
18 |
outputs=gr.Video(label="Translated Video")
|
19 |
)
|
|
|
1 |
from translate import Translate # Import the Translate class
|
2 |
import gradio as gr
|
3 |
import os
|
4 |
+
from google.colab import files
|
5 |
|
6 |
def app(video_path, original_language, target_language):
|
7 |
translator = Translate(video_path, original_language, target_language)
|
|
|
13 |
fn=app,
|
14 |
inputs=[
|
15 |
gr.Video(label="Video Path"),
|
16 |
+
gr.Dropdown(["English", "German", "Italian", "Spanish"], label="Original Language"),
|
17 |
+
gr.Dropdown(["English", "German", "Italian", "Spanish"], label="Targeted Language"),
|
18 |
],
|
19 |
outputs=gr.Video(label="Translated Video")
|
20 |
)
|