Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
@@ -95,17 +95,17 @@ def convert_video(video_file, quality, aspect_ratio, video_url, api_key, upload)
|
|
95 |
return output_copy_path
|
96 |
|
97 |
def main():
|
98 |
-
video_file = gr.
|
99 |
-
quality = gr.
|
100 |
choices=["18", "23", "28", "32"], label="Quality", default="23")
|
101 |
-
aspect_ratio = gr.
|
102 |
choices=[None, "1:1", "4:3", "3:2", "5:4", "16:9", "21:9",
|
103 |
"1.85:1", "2.35:1", "3:1", "360", "9:16", "16:9",
|
104 |
"2:1", "1:2", "9:1"],
|
105 |
label="Aspect Ratio", default=None)
|
106 |
-
video_url = gr.
|
107 |
-
api_key = gr.
|
108 |
-
upload = gr.
|
109 |
|
110 |
gr.Interface(
|
111 |
convert_video,
|
@@ -114,5 +114,6 @@ def main():
|
|
114 |
).launch()
|
115 |
|
116 |
|
|
|
117 |
if __name__ == "__main__":
|
118 |
main()
|
|
|
95 |
return output_copy_path
|
96 |
|
97 |
def main():
|
98 |
+
video_file = gr.inputs.File(label="Video File", type="file")
|
99 |
+
quality = gr.inputs.Dropdown(
|
100 |
choices=["18", "23", "28", "32"], label="Quality", default="23")
|
101 |
+
aspect_ratio = gr.inputs.Dropdown(
|
102 |
choices=[None, "1:1", "4:3", "3:2", "5:4", "16:9", "21:9",
|
103 |
"1.85:1", "2.35:1", "3:1", "360", "9:16", "16:9",
|
104 |
"2:1", "1:2", "9:1"],
|
105 |
label="Aspect Ratio", default=None)
|
106 |
+
video_url = gr.inputs.Textbox(label="Video URL")
|
107 |
+
api_key = gr.inputs.Textbox(label="web3.storage API Key")
|
108 |
+
upload = gr.inputs.Checkbox(label="Upload to web3.storage", default=False)
|
109 |
|
110 |
gr.Interface(
|
111 |
convert_video,
|
|
|
114 |
).launch()
|
115 |
|
116 |
|
117 |
+
|
118 |
if __name__ == "__main__":
|
119 |
main()
|