webui, config: save and load overwrite upscale strength

This commit is contained in:
blckbx 2024-02-11 11:51:10 +01:00
parent f1846c154a
commit d921cd428b
No known key found for this signature in database
GPG Key ID: 44F2F78C2BB10B16
2 changed files with 8 additions and 2 deletions

View File

@ -363,6 +363,11 @@ default_overwrite_switch = get_config_item_or_set_default(
default_value=-1,
validator=lambda x: isinstance(x, int)
)
default_overwrite_upscale = get_config_item_or_set_default(
key='default_overwrite_upscale',
default_value=-1,
validator=lambda x: isinstance(x, numbers.Number)
)
example_inpaint_prompts = get_config_item_or_set_default(
key='example_inpaint_prompts',
default_value=[

View File

@ -481,7 +481,8 @@ with shared.gradio_root:
minimum=-1, maximum=1.0, step=0.001, value=-1,
info='Set as negative number to disable. For developer debugging.')
overwrite_upscale_strength = gr.Slider(label='Forced Overwrite of Denoising Strength of "Upscale"',
minimum=-1, maximum=1.0, step=0.001, value=-1,
minimum=-1, maximum=1.0, step=0.001,
value=modules.config.default_overwrite_upscale,
info='Set as negative number to disable. For developer debugging.')
disable_preview = gr.Checkbox(label='Disable Preview', value=modules.config.default_black_out_nsfw,
@ -620,7 +621,7 @@ with shared.gradio_root:
state_is_generating = gr.State(False)
load_data_outputs = [advanced_checkbox, image_number, prompt, negative_prompt, style_selections,
performance_selection, overwrite_step, overwrite_switch, aspect_ratios_selection,
performance_selection, overwrite_step, overwrite_upscale_strength, overwrite_switch, aspect_ratios_selection,
overwrite_width, overwrite_height, guidance_scale, sharpness, adm_scaler_positive,
adm_scaler_negative, adm_scaler_end, refiner_swap_method, adaptive_cfg, base_model,
refiner_model, refiner_switch, sampler_name, scheduler_name, seed_random, image_seed,