Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -127,11 +127,12 @@ with gr.Blocks(css=css) as demo:
|
|
| 127 |
examples = examples,
|
| 128 |
inputs = [prompt]
|
| 129 |
)
|
| 130 |
-
|
| 131 |
-
|
|
|
|
| 132 |
fn = infer,
|
| 133 |
inputs = [prompt, negative_prompt, seed, randomize_seed, width, height, guidance_scale, num_inference_steps],
|
| 134 |
outputs = [result, seed]
|
| 135 |
)
|
| 136 |
|
| 137 |
-
demo.launch()
|
|
|
|
| 127 |
examples = examples,
|
| 128 |
inputs = [prompt]
|
| 129 |
)
|
| 130 |
+
|
| 131 |
+
# Use .click() to link the button to the infer function
|
| 132 |
+
run_button.click(
|
| 133 |
fn = infer,
|
| 134 |
inputs = [prompt, negative_prompt, seed, randomize_seed, width, height, guidance_scale, num_inference_steps],
|
| 135 |
outputs = [result, seed]
|
| 136 |
)
|
| 137 |
|
| 138 |
+
demo.launch()
|