Spaces:
Runtime error
Runtime error
Updating labels for clearer user steps
Browse files
app.py
CHANGED
|
@@ -526,8 +526,10 @@ with Blocks(
|
|
| 526 |
analytics_enabled=False,
|
| 527 |
title="GLIGen demo",
|
| 528 |
) as main:
|
| 529 |
-
gr.Markdown('<h1 style="text-align: center;">MSR:
|
| 530 |
-
gr.Markdown('<h3 style="text-align: center;">Using NLP and Grounding
|
|
|
|
|
|
|
| 531 |
|
| 532 |
with gr.Row():
|
| 533 |
with gr.Column(scale=4):
|
|
@@ -547,10 +549,10 @@ with Blocks(
|
|
| 547 |
)
|
| 548 |
|
| 549 |
with gr.Column():
|
| 550 |
-
user_input = gr.Text(label="Enter your prompt here:")
|
| 551 |
gr.Examples(["2 horses running", "A cowboy and ninja fighting", "An apple and an orange on a table"], inputs=[user_input])
|
| 552 |
with gr.Column():
|
| 553 |
-
btn = gr.Button("
|
| 554 |
with gr.Column():
|
| 555 |
separated_text = gr.Text(label="Subjects Separated by Semicolon")
|
| 556 |
btn.click(separate_subjects, inputs=[user_input], outputs=[separated_text])
|
|
@@ -561,11 +563,11 @@ with Blocks(
|
|
| 561 |
grounding_instruction=separated_text
|
| 562 |
|
| 563 |
with gr.Row():
|
| 564 |
-
sketch_pad = ImageMask(label="Sketch
|
| 565 |
out_imagebox = gr.Image(type="pil", label="Parsed Sketch Pad")
|
| 566 |
with gr.Row():
|
| 567 |
clear_btn = gr.Button(value='Clear')
|
| 568 |
-
gen_btn = gr.Button(value='Generate')
|
| 569 |
with gr.Accordion("Advanced Options", open=False):
|
| 570 |
with gr.Column():
|
| 571 |
alpha_sample = gr.Slider(minimum=0, maximum=1.0, step=0.1, value=0.3, label="Scheduled Sampling (Ο)", visible=False)
|
|
|
|
| 526 |
analytics_enabled=False,
|
| 527 |
title="GLIGen demo",
|
| 528 |
) as main:
|
| 529 |
+
gr.Markdown('<h1 style="text-align: center;">MSR: Multi-Subject Render Model</h1>')
|
| 530 |
+
gr.Markdown('<h3 style="text-align: center;">Using NLP and Grounding Inputs to improve image generation of multiple subjects with base Stable Diffusion Model</h3>')
|
| 531 |
+
gr.Markdown('<h4 style="text-align: center;">jwsun Computer Science Independent Work Spring 2023</h4>')
|
| 532 |
+
gr.Markdown('<h4 style="text-align: center;">Princeton University</h4>')
|
| 533 |
|
| 534 |
with gr.Row():
|
| 535 |
with gr.Column(scale=4):
|
|
|
|
| 549 |
)
|
| 550 |
|
| 551 |
with gr.Column():
|
| 552 |
+
user_input = gr.Text(label="STEP 1: Enter your prompt here:")
|
| 553 |
gr.Examples(["2 horses running", "A cowboy and ninja fighting", "An apple and an orange on a table"], inputs=[user_input])
|
| 554 |
with gr.Column():
|
| 555 |
+
btn = gr.Button("STEP 2: Parse Subjects")
|
| 556 |
with gr.Column():
|
| 557 |
separated_text = gr.Text(label="Subjects Separated by Semicolon")
|
| 558 |
btn.click(separate_subjects, inputs=[user_input], outputs=[separated_text])
|
|
|
|
| 563 |
grounding_instruction=separated_text
|
| 564 |
|
| 565 |
with gr.Row():
|
| 566 |
+
sketch_pad = ImageMask(label="STEP 3: Sketch Boundaries", elem_id="img2img_image")
|
| 567 |
out_imagebox = gr.Image(type="pil", label="Parsed Sketch Pad")
|
| 568 |
with gr.Row():
|
| 569 |
clear_btn = gr.Button(value='Clear')
|
| 570 |
+
gen_btn = gr.Button(value='STEP 4: Generate')
|
| 571 |
with gr.Accordion("Advanced Options", open=False):
|
| 572 |
with gr.Column():
|
| 573 |
alpha_sample = gr.Slider(minimum=0, maximum=1.0, step=0.1, value=0.3, label="Scheduled Sampling (Ο)", visible=False)
|