Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -13,7 +13,6 @@ import numpy as np
|
|
13 |
MODELS = {
|
14 |
"RealVisXL V5.0 Lightning": "SG161222/RealVisXL_V5.0_Lightning",
|
15 |
"Lustify Lightning": "GraydientPlatformAPI/lustify-lightning",
|
16 |
-
# "Lustify Inpaint": "andro-flock/LUSTIFY-SDXL-NSFW-checkpoint-v2-0-INPAINTING",
|
17 |
"Juggernaut XL Lightning": "RunDiffusion/Juggernaut-XL-Lightning",
|
18 |
}
|
19 |
|
@@ -485,6 +484,35 @@ with gr.Blocks(css=css, fill_height=True) as demo:
|
|
485 |
use_as_input_button_outpaint = gr.Button("Use as Input Image", visible=False)
|
486 |
history_gallery = gr.Gallery(label="History", columns=6, object_fit="contain", interactive=False)
|
487 |
preview_image = gr.Image(label="Preview")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
488 |
use_as_input_button_outpaint.click(
|
489 |
fn=use_output_as_input,
|
490 |
inputs=[result_outpaint],
|
|
|
13 |
MODELS = {
|
14 |
"RealVisXL V5.0 Lightning": "SG161222/RealVisXL_V5.0_Lightning",
|
15 |
"Lustify Lightning": "GraydientPlatformAPI/lustify-lightning",
|
|
|
16 |
"Juggernaut XL Lightning": "RunDiffusion/Juggernaut-XL-Lightning",
|
17 |
}
|
18 |
|
|
|
484 |
use_as_input_button_outpaint = gr.Button("Use as Input Image", visible=False)
|
485 |
history_gallery = gr.Gallery(label="History", columns=6, object_fit="contain", interactive=False)
|
486 |
preview_image = gr.Image(label="Preview")
|
487 |
+
|
488 |
+
target_ratio.change(
|
489 |
+
fn=preload_presets,
|
490 |
+
inputs=[target_ratio, width_slider, height_slider],
|
491 |
+
outputs=[width_slider, height_slider, settings_panel],
|
492 |
+
queue=False
|
493 |
+
)
|
494 |
+
|
495 |
+
width_slider.change(
|
496 |
+
fn=select_the_right_preset,
|
497 |
+
inputs=[width_slider, height_slider],
|
498 |
+
outputs=[target_ratio],
|
499 |
+
queue=False
|
500 |
+
)
|
501 |
+
|
502 |
+
height_slider.change(
|
503 |
+
fn=select_the_right_preset,
|
504 |
+
inputs=[width_slider, height_slider],
|
505 |
+
outputs=[target_ratio],
|
506 |
+
queue=False
|
507 |
+
)
|
508 |
+
|
509 |
+
resize_option.change(
|
510 |
+
fn=toggle_custom_resize_slider,
|
511 |
+
inputs=[resize_option],
|
512 |
+
outputs=[custom_resize_percentage],
|
513 |
+
queue=False
|
514 |
+
)
|
515 |
+
|
516 |
use_as_input_button_outpaint.click(
|
517 |
fn=use_output_as_input,
|
518 |
inputs=[result_outpaint],
|