Jeffgold commited on
Commit
d10be9a
·
1 Parent(s): 1528f81

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -7
app.py CHANGED
@@ -102,22 +102,22 @@ def convert_video(video_file, quality, aspect_ratio, video_url, api_key, upload)
102
  return output_copy_path
103
 
104
  def main():
105
- video_file = gr.components.File(label="Video File", type="file")
106
- quality = gr.components.Dropdown(
107
  choices=["18", "23", "28", "32"], label="Quality", default="23")
108
- aspect_ratio = gr.components.Dropdown(
109
  choices=[None, "1:1", "4:3", "3:2", "5:4", "16:9", "21:9",
110
  "1.85:1", "2.35:1", "3:1", "360", "9:16", "16:9",
111
  "2:1", "1:2", "9:1"],
112
  label="Aspect Ratio", default=None)
113
- video_url = gr.components.Textbox(label="Video URL")
114
- api_key = gr.components.Textbox(label="web3.storage API Key")
115
- upload = gr.components.Checkbox(label="Upload to web3.storage", default=False)
116
 
117
  gr.Interface(
118
  convert_video,
119
  inputs=[video_file, quality, aspect_ratio, video_url, api_key, upload],
120
- outputs=gr.components.File(label="Download File"),
121
  live=True,
122
  ).launch()
123
 
 
102
  return output_copy_path
103
 
104
  def main():
105
+ video_file = gr.inputs.File(label="Video File")
106
+ quality = gr.inputs.Dropdown(
107
  choices=["18", "23", "28", "32"], label="Quality", default="23")
108
+ aspect_ratio = gr.inputs.Dropdown(
109
  choices=[None, "1:1", "4:3", "3:2", "5:4", "16:9", "21:9",
110
  "1.85:1", "2.35:1", "3:1", "360", "9:16", "16:9",
111
  "2:1", "1:2", "9:1"],
112
  label="Aspect Ratio", default=None)
113
+ video_url = gr.inputs.Textbox(label="Video URL")
114
+ api_key = gr.inputs.Textbox(label="web3.storage API Key")
115
+ upload = gr.inputs.Checkbox(label="Upload to web3.storage", default=False)
116
 
117
  gr.Interface(
118
  convert_video,
119
  inputs=[video_file, quality, aspect_ratio, video_url, api_key, upload],
120
+ outputs=gr.outputs.File(label="Download File"),
121
  live=True,
122
  ).launch()
123