Update presets_to_add.py

This commit is contained in:
Extraltodeus
2025-04-24 22:28:57 +02:00
committed by GitHub
parent 8db4eaa508
commit 13a87c8e95
+30 -11
View File
@@ -1,4 +1,4 @@
from .custom_samplers import distance_wrap from .custom_samplers import distance_wrap, perp_step_wrap
extra_samplers = {} extra_samplers = {}
@@ -11,18 +11,37 @@ extra_samplers["the_name_that_you_want"] = distance_wrap(resample=3,resample_end
"resample" is the starting value, how many more inferences it will use. More is slower. "resample" is the starting value, how many more inferences it will use. More is slower.
For resample_end "-1" means constant. For resample_end "-1" means constant.
Constant resample at 0 gives Euler, 1 gives Heun. Constant resample at 0 gives Euler, 1 gives Heun.
cfgpp will determin if you want it or not. True or False. Other variables:
- use_negative: will use the negative prediction to prepare the distance scores. This tends to give images with less errors from my testing.
- cfgpp: will determin if you want it or not. True or False.
- use_slerp: will slerp the predictions instead of doing a weighted average. The difference is more obvious when using use_negative.
- use_softmax: rather than using a min/max normalization and an exponent will use a softmax instead.
- sharpen: not recommanded, attempts to sharpen the results but instead tends to make things fuzzy.
- smooth: not recommanded, will make everything brighter. Not smoother.
- perp step: experimental, not yet recommanded.
PerpStep is a test sampler, uncomment if you want to try.
""" """
extra_samplers["distance_fast"] = distance_wrap(resample=3,resample_end=1,cfgpp=False) # s3e1 # Codename is Distance_fast_slerp_n
extra_samplers["distance_s4e1"] = distance_wrap(resample=4,resample_end=1,cfgpp=False) extra_samplers["Distance"] = distance_wrap(resample=3,resample_end=1,cfgpp=False,sharpen=False,use_slerp=True,use_negative=True)
# extra_samplers["distance_step1"] = distance_wrap(resample=-1,resample_end=1,cfgpp=False)
# extra_samplers["distance_step0"] = distance_wrap(resample=-1,resample_end=1,cfgpp=False)
extra_samplers["distance_fast_cfg_pp"] = distance_wrap(resample=3,resample_end=1,cfgpp=True) # extra_samplers["PerpStep"] = perp_step_wrap(s=0.5)
extra_samplers["distance_s4e1_cfg_pp"] = distance_wrap(resample=4,resample_end=1,cfgpp=True) # extra_samplers["euler_test"] = distance_wrap(resample=0,resample_end=-1)
# extra_samplers["distance_c2_cfg_pp"] = distance_wrap(resample=2,resample_end=-1,cfgpp=True) # extra_samplers["heun_test"] = distance_wrap(resample=1,resample_end=1)
# extra_samplers["Distance_fast"] = distance_wrap(resample=3,resample_end=1,cfgpp=False,sharpen=False)
# extra_samplers["Distance_fast_n"] = distance_wrap(resample=3,resample_end=1,cfgpp=False,sharpen=False,use_negative=True)
# extra_samplers["Distance_fast_slerp"] = distance_wrap(resample=3,resample_end=1,cfgpp=False,sharpen=False,use_slerp=True)
# extra_samplers["Distance_fast_slerp_n"] = distance_wrap(resample=3,resample_end=1,cfgpp=False,sharpen=False,use_slerp=True,use_negative=True)
# extra_samplers["Distance_fast_slerp_p"] = distance_wrap(resample=3,resample_end=1,cfgpp=False,sharpen=False,use_slerp=True,perp_step=True)
# extra_samplers["Distance_fast_slerp_np"] = distance_wrap(resample=3,resample_end=1,cfgpp=False,sharpen=False,use_slerp=True,use_negative=True,perp_step=True)
# # constant
# extra_samplers["distance_c2"] = distance_wrap(resample=2,resample_end=-1,cfgpp=False,sharpen=False)
# extra_samplers["distance_c3"] = distance_wrap(resample=3,resample_end=-1,cfgpp=False,sharpen=False)
# extra_samplers["distance_c4"] = distance_wrap(resample=4,resample_end=-1,cfgpp=False,sharpen=False)
# extra_samplers["Distance_cfgpp"] = distance_wrap(resample=4,resample_end=-1,sharpen=False,cfgpp=True)
# cfgpp
# extra_samplers["distance_step_cfg_pp"] = distance_wrap(resample=-1,resample_end=1,cfgpp=True) # extra_samplers["distance_step_cfg_pp"] = distance_wrap(resample=-1,resample_end=1,cfgpp=True)
extra_samplers["euler_cfg_pp_alt"] = distance_wrap(resample=0,cfgpp=True)
extra_samplers["heun_cfg_pp"] = distance_wrap(resample=1,cfgpp=True) extra_samplers["heun_cfg_pp"] = distance_wrap(resample=1,cfgpp=True)