mirror of
https://github.com/Sygil-Dev/sygil-webui.git
synced 2024-12-15 14:31:44 +03:00
slider_steps and slider_bounds in defaults config
slider_steps and slider_bounds in defaults config
This commit is contained in:
parent
74fd533077
commit
6f4a1d8a41
@ -62,6 +62,15 @@ txt2img:
|
||||
variant_amount: 0.0
|
||||
variant_seed: ""
|
||||
write_info_files: True
|
||||
slider_steps: {
|
||||
sampling: 1
|
||||
}
|
||||
slider_bounds: {
|
||||
sampling: {
|
||||
lower: 1,
|
||||
upper: 150
|
||||
}
|
||||
}
|
||||
|
||||
txt2vid:
|
||||
default_model: "CompVis/stable-diffusion-v1-4"
|
||||
@ -97,6 +106,15 @@ txt2vid:
|
||||
beta_end: 0.012
|
||||
beta_scheduler_type: "linear"
|
||||
max_frames: 1000
|
||||
slider_steps: {
|
||||
sampling: 1
|
||||
}
|
||||
slider_bounds: {
|
||||
sampling: {
|
||||
lower: 1,
|
||||
upper: 150
|
||||
}
|
||||
}
|
||||
|
||||
img2img:
|
||||
prompt:
|
||||
@ -149,6 +167,15 @@ img2img:
|
||||
variant_amount: 0.0
|
||||
variant_seed: ""
|
||||
write_info_files: True
|
||||
slider_steps: {
|
||||
sampling: 1
|
||||
}
|
||||
slider_bounds: {
|
||||
sampling: {
|
||||
lower: 1,
|
||||
upper: 150
|
||||
}
|
||||
}
|
||||
|
||||
gfpgan:
|
||||
strength: 100
|
||||
|
@ -383,7 +383,11 @@ def layout():
|
||||
st.session_state["custom_model"] = "Stable Diffusion v1.4"
|
||||
|
||||
|
||||
st.session_state["sampling_steps"] = st.slider("Sampling Steps", value=st.session_state['defaults'].img2img.sampling_steps, min_value=1, max_value=500)
|
||||
st.session_state["sampling_steps"] = st.slider("Sampling Steps",
|
||||
value=st.session_state['defaults'].img2img.sampling_steps,
|
||||
min_value=st.session_state['defaults'].img2img.slider_bounds.sampling.lower,
|
||||
max_value=st.session_state['defaults'].img2img.slider_bounds.sampling.upper,
|
||||
step=st.session_state['defaults'].img2img.slider_steps.sampling)
|
||||
|
||||
sampler_name_list = ["k_lms", "k_euler", "k_euler_a", "k_dpm_2", "k_dpm_2_a", "k_heun", "PLMS", "DDIM"]
|
||||
st.session_state["sampler_name"] = st.selectbox("Sampling method",sampler_name_list,
|
||||
|
@ -217,7 +217,11 @@ def layout():
|
||||
the file for the model has on said folder, it is recommended to give the .ckpt file a name that \
|
||||
will make it easier for you to distinguish it from other models. Default: Stable Diffusion v1.4")
|
||||
|
||||
st.session_state.sampling_steps = st.slider("Sampling Steps", value=st.session_state['defaults'].txt2img.sampling_steps, min_value=10, max_value=500, step=10)
|
||||
st.session_state.sampling_steps = st.slider("Sampling Steps",
|
||||
value=st.session_state['defaults'].txt2img.sampling_steps,
|
||||
min_value=st.session_state['defaults'].txt2img.slider_bounds.sampling.lower,
|
||||
max_value=st.session_state['defaults'].txt2img.slider_bounds.sampling.upper,
|
||||
step=st.session_state['defaults'].txt2img.slider_steps.sampling)
|
||||
|
||||
sampler_name_list = ["k_lms", "k_euler", "k_euler_a", "k_dpm_2", "k_dpm_2_a", "k_heun", "PLMS", "DDIM"]
|
||||
sampler_name = st.selectbox("Sampling method", sampler_name_list,
|
||||
|
@ -650,7 +650,11 @@ def layout():
|
||||
#custom_model = "CompVis/stable-diffusion-v1-4"
|
||||
#st.session_state["weights_path"] = f"CompVis/{slugify(custom_model.lower())}"
|
||||
|
||||
st.session_state.sampling_steps = st.slider("Sampling Steps", value=st.session_state['defaults'].txt2vid.sampling_steps, min_value=10, step=10, max_value=500,
|
||||
st.session_state.sampling_steps = st.slider("Sampling Steps",
|
||||
value=st.session_state['defaults'].txt2vid.sampling_steps,
|
||||
min_value=st.session_state['defaults'].txt2vid.slider_bounds.sampling.lower,
|
||||
max_value=st.session_state['defaults'].txt2vid.slider_bounds.sampling.upper,
|
||||
step=st.session_state['defaults'].txt2vid.slider_steps.sampling,
|
||||
help="Number of steps between each pair of sampled points")
|
||||
st.session_state.num_inference_steps = st.slider("Inference Steps:", value=st.session_state['defaults'].txt2vid.num_inference_steps, min_value=10,step=10, max_value=500,
|
||||
help="Higher values (e.g. 100, 200 etc) can create better images.")
|
||||
|
Loading…
Reference in New Issue
Block a user