Spaces:
Runtime error
Runtime error
Update app_.py
Browse files
app_.py
CHANGED
|
@@ -252,6 +252,11 @@ with gr.Blocks(theme=gr.themes.Soft()) as demo:
|
|
| 252 |
inputs=[image_input],
|
| 253 |
cache_examples=False,
|
| 254 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 255 |
with gr.Accordion(open=True, label="Driving Video"):
|
| 256 |
video_input = gr.Video()
|
| 257 |
gr.Examples(
|
|
@@ -272,7 +277,6 @@ with gr.Blocks(theme=gr.themes.Soft()) as demo:
|
|
| 272 |
flag_relative_input = gr.Checkbox(value=True, label="relative motion")
|
| 273 |
flag_do_crop_input = gr.Checkbox(value=True, label="do crop")
|
| 274 |
flag_remap_input = gr.Checkbox(value=True, label="paste-back")
|
| 275 |
-
flag_closed_lip_input = gr.Checkbox(value=False, label="closed lip")
|
| 276 |
#gr.Markdown(load_description("assets/gradio_description_animate_clear.md"))
|
| 277 |
with gr.Row():
|
| 278 |
with gr.Column():
|
|
@@ -313,7 +317,6 @@ with gr.Blocks(theme=gr.themes.Soft()) as demo:
|
|
| 313 |
flag_relative_input,
|
| 314 |
flag_do_crop_input,
|
| 315 |
flag_remap_input,
|
| 316 |
-
flag_closed_lip_input
|
| 317 |
],
|
| 318 |
outputs=[output_video, output_video_concat],
|
| 319 |
show_progress=True
|
|
@@ -326,6 +329,15 @@ with gr.Blocks(theme=gr.themes.Soft()) as demo:
|
|
| 326 |
outputs=[video_input],
|
| 327 |
show_progress=True
|
| 328 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 329 |
# audio_gen_button.click(
|
| 330 |
# fn=gpu_wrapped_elevenlabs_pipeline_generate_voice,
|
| 331 |
# inputs=[
|
|
|
|
| 252 |
inputs=[image_input],
|
| 253 |
cache_examples=False,
|
| 254 |
)
|
| 255 |
+
# ========== 여기에 closed mouth 버튼 추가 ========== #
|
| 256 |
+
process_button_closelip = gr.Button("Close lip")
|
| 257 |
+
|
| 258 |
+
|
| 259 |
+
|
| 260 |
with gr.Accordion(open=True, label="Driving Video"):
|
| 261 |
video_input = gr.Video()
|
| 262 |
gr.Examples(
|
|
|
|
| 277 |
flag_relative_input = gr.Checkbox(value=True, label="relative motion")
|
| 278 |
flag_do_crop_input = gr.Checkbox(value=True, label="do crop")
|
| 279 |
flag_remap_input = gr.Checkbox(value=True, label="paste-back")
|
|
|
|
| 280 |
#gr.Markdown(load_description("assets/gradio_description_animate_clear.md"))
|
| 281 |
with gr.Row():
|
| 282 |
with gr.Column():
|
|
|
|
| 317 |
flag_relative_input,
|
| 318 |
flag_do_crop_input,
|
| 319 |
flag_remap_input,
|
|
|
|
| 320 |
],
|
| 321 |
outputs=[output_video, output_video_concat],
|
| 322 |
show_progress=True
|
|
|
|
| 329 |
outputs=[video_input],
|
| 330 |
show_progress=True
|
| 331 |
)
|
| 332 |
+
|
| 333 |
+
process_button_closelip.click(
|
| 334 |
+
fn=gradio_pipeline.prepare_retargeting,
|
| 335 |
+
inputs=image_input,
|
| 336 |
+
outputs=image_input,
|
| 337 |
+
show_progress=True
|
| 338 |
+
|
| 339 |
+
)
|
| 340 |
+
|
| 341 |
# audio_gen_button.click(
|
| 342 |
# fn=gpu_wrapped_elevenlabs_pipeline_generate_voice,
|
| 343 |
# inputs=[
|