Update app.py
Browse files
app.py
CHANGED
|
@@ -62,7 +62,7 @@ def add_new_image(image):
|
|
| 62 |
refer_image: {ip_img}
|
| 63 |
video_path: null
|
| 64 |
width: width"""
|
| 65 |
-
with open ("
|
| 66 |
configs.write(img_settings)
|
| 67 |
|
| 68 |
@spaces.GPU
|
|
@@ -73,9 +73,10 @@ def run(duration=180):
|
|
| 73 |
|
| 74 |
with gr.Blocks() as demo:
|
| 75 |
image = gr.Image()
|
| 76 |
-
|
| 77 |
-
|
|
|
|
| 78 |
video = gr.Video()
|
| 79 |
-
|
| 80 |
|
| 81 |
demo.launch()
|
|
|
|
| 62 |
refer_image: {ip_img}
|
| 63 |
video_path: null
|
| 64 |
width: width"""
|
| 65 |
+
with open ("/home/user/app/MuseV/configs/tasks/run.yaml","r+") as configs:
|
| 66 |
configs.write(img_settings)
|
| 67 |
|
| 68 |
@spaces.GPU
|
|
|
|
| 73 |
|
| 74 |
with gr.Blocks() as demo:
|
| 75 |
image = gr.Image()
|
| 76 |
+
button1 = gr.Button()
|
| 77 |
+
button1.clock(fn=add_new_image,inputs=image)
|
| 78 |
+
button2 = gr.Button()
|
| 79 |
video = gr.Video()
|
| 80 |
+
button2.click(fn=run,outputs=video)
|
| 81 |
|
| 82 |
demo.launch()
|