Spaces:
Running
on
Zero
Running
on
Zero
Commit
•
d49e26c
1
Parent(s):
dff35d4
Add advanced settings to an accordion
Browse files
app.py
CHANGED
@@ -66,15 +66,18 @@ iface = gr.Interface(
|
|
66 |
fn=generate_image,
|
67 |
inputs=[
|
68 |
gr.Textbox(label="Prompt"),
|
69 |
-
gr.Textbox(label="Negative Prompt")
|
|
|
|
|
70 |
gr.Slider(512, 2048, 1024, step=64, label="Height"),
|
71 |
gr.Slider(512, 2048, 1024, step=64, label="Width"),
|
72 |
gr.Slider(20, 50, 20, step=1, label="Number of Inference Steps"),
|
73 |
gr.Slider(1, 20, 5, step=0.5, label="Guidance Scale"),
|
74 |
gr.Slider(1, 4, 1, step=1, label="Number of images per prompt"),
|
75 |
gr.Checkbox(label="Use Random Seed", value=True),
|
76 |
-
gr.Number(label="Seed", value=0, precision=0)
|
77 |
],
|
|
|
78 |
outputs=[
|
79 |
gr.Gallery(label="Result", elem_id="gallery", show_label=False),
|
80 |
gr.Number(label="Seed Used")
|
|
|
66 |
fn=generate_image,
|
67 |
inputs=[
|
68 |
gr.Textbox(label="Prompt"),
|
69 |
+
gr.Textbox(label="Negative Prompt")
|
70 |
+
],
|
71 |
+
additional_inputs=[
|
72 |
gr.Slider(512, 2048, 1024, step=64, label="Height"),
|
73 |
gr.Slider(512, 2048, 1024, step=64, label="Width"),
|
74 |
gr.Slider(20, 50, 20, step=1, label="Number of Inference Steps"),
|
75 |
gr.Slider(1, 20, 5, step=0.5, label="Guidance Scale"),
|
76 |
gr.Slider(1, 4, 1, step=1, label="Number of images per prompt"),
|
77 |
gr.Checkbox(label="Use Random Seed", value=True),
|
78 |
+
gr.Number(label="Seed", value=0, precision=0)
|
79 |
],
|
80 |
+
additional_inputs_accordion=gr.Accordion(label="Advanced settings", open=False),
|
81 |
outputs=[
|
82 |
gr.Gallery(label="Result", elem_id="gallery", show_label=False),
|
83 |
gr.Number(label="Seed Used")
|