Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -156,7 +156,7 @@ def generate(
|
|
156 |
height=height,
|
157 |
negative_prompt=negative_prompt,
|
158 |
guidance_scale=0,
|
159 |
-
num_inference_steps=
|
160 |
generator=generator,
|
161 |
num_images_per_prompt=NUM_IMAGES_PER_PROMPT,
|
162 |
use_resolution_binning=use_resolution_binning,
|
@@ -200,11 +200,11 @@ with gr.Blocks() as demo:
|
|
200 |
)
|
201 |
run_button = gr.Button("Run", scale=0)
|
202 |
result = gr.Gallery(label="Result", columns=NUM_IMAGES_PER_PROMPT, show_label=False)
|
203 |
-
|
204 |
with gr.Group():
|
205 |
with gr.Row():
|
206 |
use_negative_prompt = gr.Checkbox(label="Use negative prompt", value=False, visible=True)
|
207 |
-
|
208 |
label="Negative prompt",
|
209 |
max_lines=1,
|
210 |
placeholder="Enter a negative prompt",
|
@@ -258,12 +258,11 @@ with gr.Blocks() as demo:
|
|
258 |
with gr.Row():
|
259 |
inference_steps = gr.Slider(
|
260 |
label="Steps",
|
261 |
-
minimum=
|
262 |
-
maximum=
|
263 |
step=1,
|
264 |
-
value=
|
265 |
-
)
|
266 |
-
)
|
267 |
|
268 |
gr.Examples(
|
269 |
examples=examples,
|
|
|
156 |
height=height,
|
157 |
negative_prompt=negative_prompt,
|
158 |
guidance_scale=0,
|
159 |
+
num_inference_steps=inference_steps,
|
160 |
generator=generator,
|
161 |
num_images_per_prompt=NUM_IMAGES_PER_PROMPT,
|
162 |
use_resolution_binning=use_resolution_binning,
|
|
|
200 |
)
|
201 |
run_button = gr.Button("Run", scale=0)
|
202 |
result = gr.Gallery(label="Result", columns=NUM_IMAGES_PER_PROMPT, show_label=False)
|
203 |
+
with gr.Accordion("Advanced options", open=False):
|
204 |
with gr.Group():
|
205 |
with gr.Row():
|
206 |
use_negative_prompt = gr.Checkbox(label="Use negative prompt", value=False, visible=True)
|
207 |
+
negative_prompt = gr.Text(
|
208 |
label="Negative prompt",
|
209 |
max_lines=1,
|
210 |
placeholder="Enter a negative prompt",
|
|
|
258 |
with gr.Row():
|
259 |
inference_steps = gr.Slider(
|
260 |
label="Steps",
|
261 |
+
minimum=4,
|
262 |
+
maximum=20,
|
263 |
step=1,
|
264 |
+
value=4,
|
265 |
+
)
|
|
|
266 |
|
267 |
gr.Examples(
|
268 |
examples=examples,
|