Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -499,9 +499,8 @@ with gr.Blocks(title="Diffusion as Shader") as demo:
|
|
499 |
outputs=[source_preview]
|
500 |
)
|
501 |
|
502 |
-
gr.Markdown("###
|
503 |
-
gr.
|
504 |
-
common_prompt = gr.Textbox(label="Prompt: ", lines=2)
|
505 |
|
506 |
with gr.Tabs() as task_tabs:
|
507 |
# Motion Transfer tab
|
@@ -550,17 +549,17 @@ with gr.Blocks(title="Diffusion as Shader") as demo:
|
|
550 |
with gr.TabItem("Object Manipulation"):
|
551 |
gr.Markdown("Object Manipulation is not available in Huggingface Space, please deploy our [GitHub project](https://github.com/IGL-HKUST/DiffusionAsShader) on your own machine")
|
552 |
|
553 |
-
|
554 |
-
|
555 |
-
|
556 |
-
|
557 |
-
|
558 |
-
|
559 |
-
|
560 |
-
|
561 |
-
|
562 |
-
|
563 |
-
|
564 |
|
565 |
|
566 |
# Launch interface
|
|
|
499 |
outputs=[source_preview]
|
500 |
)
|
501 |
|
502 |
+
gr.Markdown("### 2. Enter the prompt")
|
503 |
+
common_prompt = gr.Textbox(label="Describe the scene and the motion you want to create: ", lines=2)
|
|
|
504 |
|
505 |
with gr.Tabs() as task_tabs:
|
506 |
# Motion Transfer tab
|
|
|
549 |
with gr.TabItem("Object Manipulation"):
|
550 |
gr.Markdown("Object Manipulation is not available in Huggingface Space, please deploy our [GitHub project](https://github.com/IGL-HKUST/DiffusionAsShader) on your own machine")
|
551 |
|
552 |
+
examples_list = load_examples()
|
553 |
+
if examples_list:
|
554 |
+
with gr.Blocks() as examples_block:
|
555 |
+
gr.Examples(
|
556 |
+
examples=examples_list,
|
557 |
+
inputs=[source_preview, mt_repaint_preview, common_prompt, tracking_video, output_video],
|
558 |
+
outputs=[source_preview, mt_repaint_preview, common_prompt, tracking_video, output_video],
|
559 |
+
fn=lambda *args: args,
|
560 |
+
cache_examples=True,
|
561 |
+
label="Examples"
|
562 |
+
)
|
563 |
|
564 |
|
565 |
# Launch interface
|