Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
|
@@ -158,8 +158,8 @@ def infer(
|
|
| 158 |
def infer_example(input_image, prompt, lora_adapter):
|
| 159 |
input_pil = input_image.convert("RGB")
|
| 160 |
# Set reasonable default values for example inference
|
| 161 |
-
guidance_scale =
|
| 162 |
-
steps =
|
| 163 |
# Call the main infer function
|
| 164 |
result, seed = infer(input_pil, prompt, lora_adapter, 0, True, guidance_scale, steps)
|
| 165 |
return result, seed
|
|
@@ -199,8 +199,8 @@ with gr.Blocks(css=css, theme=steel_blue_theme) as demo:
|
|
| 199 |
with gr.Accordion("⚙️ Advanced Settings", open=False):
|
| 200 |
seed = gr.Slider(label="Seed", minimum=0, maximum=MAX_SEED, step=1, value=0)
|
| 201 |
randomize_seed = gr.Checkbox(label="Randomize Seed", value=True)
|
| 202 |
-
guidance_scale = gr.Slider(label="Guidance Scale", minimum=1.0, maximum=10.0, step=0.1, value=
|
| 203 |
-
steps = gr.Slider(label="Inference Steps", minimum=1, maximum=50, step=1, value=
|
| 204 |
|
| 205 |
with gr.Column():
|
| 206 |
output_image = gr.Image(label="Output Image", interactive=False, format="png", height=400)
|
|
|
|
| 158 |
def infer_example(input_image, prompt, lora_adapter):
|
| 159 |
input_pil = input_image.convert("RGB")
|
| 160 |
# Set reasonable default values for example inference
|
| 161 |
+
guidance_scale = 1.0
|
| 162 |
+
steps = 4
|
| 163 |
# Call the main infer function
|
| 164 |
result, seed = infer(input_pil, prompt, lora_adapter, 0, True, guidance_scale, steps)
|
| 165 |
return result, seed
|
|
|
|
| 199 |
with gr.Accordion("⚙️ Advanced Settings", open=False):
|
| 200 |
seed = gr.Slider(label="Seed", minimum=0, maximum=MAX_SEED, step=1, value=0)
|
| 201 |
randomize_seed = gr.Checkbox(label="Randomize Seed", value=True)
|
| 202 |
+
guidance_scale = gr.Slider(label="Guidance Scale", minimum=1.0, maximum=10.0, step=0.1, value=1.0)
|
| 203 |
+
steps = gr.Slider(label="Inference Steps", minimum=1, maximum=50, step=1, value=4)
|
| 204 |
|
| 205 |
with gr.Column():
|
| 206 |
output_image = gr.Image(label="Output Image", interactive=False, format="png", height=400)
|