From 53be15c204b453347d7b99a92726ebca48b19fd5 Mon Sep 17 00:00:00 2001 From: AUTOMATIC <16777216c@gmail.com> Date: Sun, 25 Sep 2022 08:40:29 +0300 Subject: [PATCH] by popular request, moves width/height sliders higher --- modules/ui.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/modules/ui.py b/modules/ui.py index 5c355e15..19ed5002 100644 --- a/modules/ui.py +++ b/modules/ui.py @@ -412,6 +412,10 @@ def create_ui(txt2img, img2img, run_extras, run_pnginfo): steps = gr.Slider(minimum=1, maximum=150, step=1, label="Sampling Steps", value=20) sampler_index = gr.Radio(label='Sampling method', elem_id="txt2img_sampling", choices=[x.name for x in samplers], value=samplers[0].name, type="index") + with gr.Group(): + width = gr.Slider(minimum=64, maximum=2048, step=64, label="Width", value=512) + height = gr.Slider(minimum=64, maximum=2048, step=64, label="Height", value=512) + with gr.Row(): restore_faces = gr.Checkbox(label='Restore faces', value=False, visible=len(shared.face_restorers) > 1) tiling = gr.Checkbox(label='Tiling', value=False) @@ -427,10 +431,6 @@ def create_ui(txt2img, img2img, run_extras, run_pnginfo): cfg_scale = gr.Slider(minimum=1.0, maximum=30.0, step=0.5, label='CFG Scale', value=7.0) - with gr.Group(): - width = gr.Slider(minimum=64, maximum=2048, step=64, label="Width", value=512) - height = gr.Slider(minimum=64, maximum=2048, step=64, label="Height", value=512) - seed, reuse_seed, subseed, reuse_subseed, subseed_strength, seed_resize_from_h, seed_resize_from_w, seed_checkbox = create_seed_inputs() with gr.Group(): @@ -589,6 +589,10 @@ def create_ui(txt2img, img2img, run_extras, run_pnginfo): steps = gr.Slider(minimum=1, maximum=150, step=1, label="Sampling Steps", value=20) sampler_index = gr.Radio(label='Sampling method', choices=[x.name for x in samplers_for_img2img], value=samplers_for_img2img[0].name, type="index") + with gr.Group(): + width = gr.Slider(minimum=64, maximum=2048, step=64, label="Width", value=512) + height = gr.Slider(minimum=64, maximum=2048, step=64, label="Height", value=512) + with gr.Row(): restore_faces = gr.Checkbox(label='Restore faces', value=False, visible=len(shared.face_restorers) > 1) tiling = gr.Checkbox(label='Tiling', value=False) @@ -601,10 +605,6 @@ def create_ui(txt2img, img2img, run_extras, run_pnginfo): cfg_scale = gr.Slider(minimum=1.0, maximum=30.0, step=0.5, label='CFG Scale', value=7.0) denoising_strength = gr.Slider(minimum=0.0, maximum=1.0, step=0.01, label='Denoising strength', value=0.75) - with gr.Group(): - width = gr.Slider(minimum=64, maximum=2048, step=64, label="Width", value=512) - height = gr.Slider(minimum=64, maximum=2048, step=64, label="Height", value=512) - seed, reuse_seed, subseed, reuse_subseed, subseed_strength, seed_resize_from_h, seed_resize_from_w, seed_checkbox = create_seed_inputs() with gr.Group():