seawolf2357 commited on
Commit
d49d212
Β·
1 Parent(s): 244d581

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -6
app.py CHANGED
@@ -120,22 +120,20 @@ def generate_status(content_id):
120
  def gradio_generate_status(content_id):
121
  download_url = generate_status(content_id)
122
  if download_url != 'FAILED':
123
- return download_url, requests.get(download_url).content
124
  else:
125
- return "컨텐츠 생성 μ‹€νŒ¨ λ˜λŠ” IDκ°€ 잘λͺ»λ˜μ—ˆμŠ΅λ‹ˆλ‹€.", None
126
 
127
  status_iface = gr.Interface(
128
  fn=gradio_generate_status,
129
  inputs=gr.Textbox(label="컨텐츠 ID"),
130
- outputs=[
131
- gr.Textbox(label="λ‹€μš΄λ‘œλ“œ URL"),
132
- gr.File(label="λ‹€μš΄λ‘œλ“œ λ²„νŠΌ")
133
- ]
134
  )
135
 
136
  status_iface.launch()
137
 
138
 
 
139
  def download_content(url):
140
  data = requests.get(url, timeout=30)
141
  save_path = "downloaded_example.mp4"
 
120
  def gradio_generate_status(content_id):
121
  download_url = generate_status(content_id)
122
  if download_url != 'FAILED':
123
+ return download_url
124
  else:
125
+ return "컨텐츠 생성 μ‹€νŒ¨ λ˜λŠ” IDκ°€ 잘λͺ»λ˜μ—ˆμŠ΅λ‹ˆλ‹€."
126
 
127
  status_iface = gr.Interface(
128
  fn=gradio_generate_status,
129
  inputs=gr.Textbox(label="컨텐츠 ID"),
130
+ outputs=gr.Textbox(label="λ‹€μš΄λ‘œλ“œ 링크 λ˜λŠ” λ©”μ‹œμ§€")
 
 
 
131
  )
132
 
133
  status_iface.launch()
134
 
135
 
136
+
137
  def download_content(url):
138
  data = requests.get(url, timeout=30)
139
  save_path = "downloaded_example.mp4"