Pie31415 commited on
Commit
ab92e15
·
1 Parent(s): 863da55

updated app

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -200,9 +200,9 @@ def video_inference(
200
 
201
  upload = True
202
 
203
- def toggle_webcam(toggle):
204
  global upload
205
- upload = not toggle
206
 
207
  description = """<p style='text-align: center'> Create a personal avatar from just a single image using ROME. <br> <a href='https://arxiv.org/abs/2206.08343' target='_blank'>Paper</a> | <a href='https://samsunglabs.github.io/rome' target='_blank'>Project Page</a> | <a href='https://github.com/SamsungLabs/rome' target='_blank'>Github</a> </p>"""
208
  quote = """
@@ -241,6 +241,6 @@ with gr.Blocks() as demo:
241
 
242
  image_button.click(image_inference, inputs=[source_img, driver_img], outputs=image_output)
243
  video_button.click(video_inference, inputs=[source_img2, driver_vid], outputs=video_output)
244
- toggle_cam.click(toggle_webcam, inputs=[upload])
245
 
246
  demo.launch()
 
200
 
201
  upload = True
202
 
203
+ def toggle_webcam():
204
  global upload
205
+ upload = not upload
206
 
207
  description = """<p style='text-align: center'> Create a personal avatar from just a single image using ROME. <br> <a href='https://arxiv.org/abs/2206.08343' target='_blank'>Paper</a> | <a href='https://samsunglabs.github.io/rome' target='_blank'>Project Page</a> | <a href='https://github.com/SamsungLabs/rome' target='_blank'>Github</a> </p>"""
208
  quote = """
 
241
 
242
  image_button.click(image_inference, inputs=[source_img, driver_img], outputs=image_output)
243
  video_button.click(video_inference, inputs=[source_img2, driver_vid], outputs=video_output)
244
+ toggle_cam.click(toggle_webcam)
245
 
246
  demo.launch()