Update presets.py
Browse files- presets.py +134 -134
presets.py
CHANGED
@@ -1,134 +1,134 @@
|
|
1 |
-
from sdutils import get_dtypes, SCHEDULER_CONFIG_MAP
|
2 |
-
|
3 |
-
|
4 |
-
DEFAULT_DTYPE = get_dtypes()[0]
|
5 |
-
schedulers = list(SCHEDULER_CONFIG_MAP.keys())
|
6 |
-
|
7 |
-
|
8 |
-
clips = [
|
9 |
-
"",
|
10 |
-
"openai/clip-vit-large-patch14",
|
11 |
-
]
|
12 |
-
|
13 |
-
|
14 |
-
t5s = [
|
15 |
-
"",
|
16 |
-
"https://huggingface.co/camenduru/FLUX.1-dev/blob/main/t5xxl_fp8_e4m3fn.safetensors",
|
17 |
-
]
|
18 |
-
|
19 |
-
|
20 |
-
sdxl_vaes = [
|
21 |
-
"",
|
22 |
-
"https://huggingface.co/madebyollin/sdxl-vae-fp16-fix/blob/main/sdxl.vae.safetensors",
|
23 |
-
"https://huggingface.co/nubby/blessed-sdxl-vae-fp16-fix/blob/main/sdxl_vae-fp16fix-blessed.safetensors",
|
24 |
-
"https://huggingface.co/John6666/safetensors_converting_test/blob/main/xlVAEC_e7.safetensors",
|
25 |
-
"https://huggingface.co/John6666/safetensors_converting_test/blob/main/xlVAEC_f1.safetensors",
|
26 |
-
]
|
27 |
-
|
28 |
-
|
29 |
-
sdxl_loras = [
|
30 |
-
"",
|
31 |
-
"https://huggingface.co/SPO-Diffusion-Models/SPO-SDXL_4k-p_10ep_LoRA/blob/main/spo_sdxl_10ep_4k-data_lora_diffusers.safetensors",
|
32 |
-
"https://huggingface.co/wangfuyun/PCM_Weights/blob/main/sdxl/pcm_sdxl_smallcfg_2step_converted.safetensors",
|
33 |
-
"https://huggingface.co/wangfuyun/PCM_Weights/blob/main/sdxl/pcm_sdxl_smallcfg_4step_converted.safetensors",
|
34 |
-
"https://huggingface.co/wangfuyun/PCM_Weights/blob/main/sdxl/pcm_sdxl_smallcfg_8step_converted.safetensors",
|
35 |
-
"https://huggingface.co/wangfuyun/PCM_Weights/blob/main/sdxl/pcm_sdxl_normalcfg_8step_converted.safetensors",
|
36 |
-
"https://huggingface.co/wangfuyun/PCM_Weights/blob/main/sdxl/pcm_sdxl_normalcfg_16step_converted.safetensors",
|
37 |
-
"https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-1step-lora.safetensors",
|
38 |
-
"https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-2steps-lora.safetensors",
|
39 |
-
"https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-4steps-lora.safetensors",
|
40 |
-
"https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-8steps-CFG-lora.safetensors",
|
41 |
-
"https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-12steps-CFG-lora.safetensors",
|
42 |
-
"https://huggingface.co/latent-consistency/lcm-lora-sdxl/blob/main/pytorch_lora_weights.safetensors",
|
43 |
-
]
|
44 |
-
|
45 |
-
|
46 |
-
sdxl_preset_dict = {
|
47 |
-
"Default": [DEFAULT_DTYPE, "", "Euler a", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0],
|
48 |
-
"Bake in standard VAE": [DEFAULT_DTYPE, "https://huggingface.co/madebyollin/sdxl-vae-fp16-fix/blob/main/sdxl.vae.safetensors",
|
49 |
-
"Euler a", "",
|
50 |
-
"Hyper-SDXL / SPO": [DEFAULT_DTYPE, "https://huggingface.co/madebyollin/sdxl-vae-fp16-fix/blob/main/sdxl.vae.safetensors",
|
51 |
-
"TCD", "https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-8steps-CFG-lora.safetensors", 1.0,
|
52 |
-
"https://huggingface.co/SPO-Diffusion-Models/SPO-SDXL_4k-p_10ep_LoRA/blob/main/spo_sdxl_10ep_4k-data_lora_diffusers.safetensors",
|
53 |
-
1.0, "", 1.0, "", 1.0, "", 1.0],
|
54 |
-
}
|
55 |
-
|
56 |
-
|
57 |
-
def sdxl_set_presets(preset: str="Default"):
|
58 |
-
p = []
|
59 |
-
if preset in sdxl_preset_dict.keys(): p = sdxl_preset_dict[preset]
|
60 |
-
else: p = sdxl_preset_dict["Default"]
|
61 |
-
return p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7], p[8], p[9], p[10], p[11], p[12]
|
62 |
-
|
63 |
-
|
64 |
-
sd15_vaes = [
|
65 |
-
"",
|
66 |
-
"https://huggingface.co/stabilityai/sd-vae-ft-mse-original/resolve/main/vae-ft-mse-840000-ema-pruned.ckpt",
|
67 |
-
"https://huggingface.co/stabilityai/sd-vae-ft-ema-original/resolve/main/vae-ft-ema-560000-ema-pruned.ckpt",
|
68 |
-
]
|
69 |
-
|
70 |
-
|
71 |
-
sd15_loras = [
|
72 |
-
"",
|
73 |
-
"https://huggingface.co/SPO-Diffusion-Models/SPO-SD-v1-5_4k-p_10ep_LoRA/blob/main/spo-sd-v1-5_4k-p_10ep_lora_diffusers.safetensors",
|
74 |
-
]
|
75 |
-
|
76 |
-
|
77 |
-
sd15_preset_dict = {
|
78 |
-
"Default": [DEFAULT_DTYPE, "", "Euler", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0, True],
|
79 |
-
"Bake in standard VAE": [DEFAULT_DTYPE, "https://huggingface.co/stabilityai/sd-vae-ft-mse-original/resolve/main/vae-ft-mse-840000-ema-pruned.ckpt",
|
80 |
-
"Euler", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0, True],
|
81 |
-
}
|
82 |
-
|
83 |
-
|
84 |
-
def sd15_set_presets(preset: str="Default"):
|
85 |
-
p = []
|
86 |
-
if preset in sd15_preset_dict.keys(): p = sd15_preset_dict[preset]
|
87 |
-
else: p = sd15_preset_dict["Default"]
|
88 |
-
return p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7], p[8], p[9], p[10], p[11], p[12], p[13]
|
89 |
-
|
90 |
-
|
91 |
-
flux_vaes = [
|
92 |
-
"",
|
93 |
-
]
|
94 |
-
|
95 |
-
|
96 |
-
flux_loras = [
|
97 |
-
"",
|
98 |
-
]
|
99 |
-
|
100 |
-
|
101 |
-
flux_preset_dict = {
|
102 |
-
"dev": ["bf16", "", "", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0, "camenduru/FLUX.1-dev-diffusers"],
|
103 |
-
"schnell": ["bf16", "", "", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0, "black-forest-labs/FLUX.1-schnell"],
|
104 |
-
}
|
105 |
-
|
106 |
-
|
107 |
-
def flux_set_presets(preset: str="dev"):
|
108 |
-
p = []
|
109 |
-
if preset in flux_preset_dict.keys(): p = flux_preset_dict[preset]
|
110 |
-
else: p = flux_preset_dict["dev"]
|
111 |
-
return p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7], p[8], p[9], p[10], p[11], p[12], p[13]
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
sd35_vaes = [
|
116 |
-
"",
|
117 |
-
]
|
118 |
-
|
119 |
-
|
120 |
-
sd35_loras = [
|
121 |
-
"",
|
122 |
-
]
|
123 |
-
|
124 |
-
|
125 |
-
sd35_preset_dict = {
|
126 |
-
"Default": ["bf16", "", "", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0, "adamo1139/stable-diffusion-3.5-large-ungated"],
|
127 |
-
}
|
128 |
-
|
129 |
-
|
130 |
-
def sd35_set_presets(preset: str="dev"):
|
131 |
-
p = []
|
132 |
-
if preset in sd35_preset_dict.keys(): p = sd35_preset_dict[preset]
|
133 |
-
else: p = sd35_preset_dict["Default"]
|
134 |
-
return p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7], p[8], p[9], p[10], p[11], p[12], p[13]
|
|
|
1 |
+
from sdutils import get_dtypes, SCHEDULER_CONFIG_MAP
|
2 |
+
|
3 |
+
|
4 |
+
DEFAULT_DTYPE = get_dtypes()[0]
|
5 |
+
schedulers = list(SCHEDULER_CONFIG_MAP.keys())
|
6 |
+
|
7 |
+
|
8 |
+
clips = [
|
9 |
+
"",
|
10 |
+
"openai/clip-vit-large-patch14",
|
11 |
+
]
|
12 |
+
|
13 |
+
|
14 |
+
t5s = [
|
15 |
+
"",
|
16 |
+
"https://huggingface.co/camenduru/FLUX.1-dev/blob/main/t5xxl_fp8_e4m3fn.safetensors",
|
17 |
+
]
|
18 |
+
|
19 |
+
|
20 |
+
sdxl_vaes = [
|
21 |
+
"",
|
22 |
+
"https://huggingface.co/madebyollin/sdxl-vae-fp16-fix/blob/main/sdxl.vae.safetensors",
|
23 |
+
"https://huggingface.co/nubby/blessed-sdxl-vae-fp16-fix/blob/main/sdxl_vae-fp16fix-blessed.safetensors",
|
24 |
+
"https://huggingface.co/John6666/safetensors_converting_test/blob/main/xlVAEC_e7.safetensors",
|
25 |
+
"https://huggingface.co/John6666/safetensors_converting_test/blob/main/xlVAEC_f1.safetensors",
|
26 |
+
]
|
27 |
+
|
28 |
+
|
29 |
+
sdxl_loras = [
|
30 |
+
"",
|
31 |
+
"https://huggingface.co/SPO-Diffusion-Models/SPO-SDXL_4k-p_10ep_LoRA/blob/main/spo_sdxl_10ep_4k-data_lora_diffusers.safetensors",
|
32 |
+
"https://huggingface.co/wangfuyun/PCM_Weights/blob/main/sdxl/pcm_sdxl_smallcfg_2step_converted.safetensors",
|
33 |
+
"https://huggingface.co/wangfuyun/PCM_Weights/blob/main/sdxl/pcm_sdxl_smallcfg_4step_converted.safetensors",
|
34 |
+
"https://huggingface.co/wangfuyun/PCM_Weights/blob/main/sdxl/pcm_sdxl_smallcfg_8step_converted.safetensors",
|
35 |
+
"https://huggingface.co/wangfuyun/PCM_Weights/blob/main/sdxl/pcm_sdxl_normalcfg_8step_converted.safetensors",
|
36 |
+
"https://huggingface.co/wangfuyun/PCM_Weights/blob/main/sdxl/pcm_sdxl_normalcfg_16step_converted.safetensors",
|
37 |
+
"https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-1step-lora.safetensors",
|
38 |
+
"https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-2steps-lora.safetensors",
|
39 |
+
"https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-4steps-lora.safetensors",
|
40 |
+
"https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-8steps-CFG-lora.safetensors",
|
41 |
+
"https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-12steps-CFG-lora.safetensors",
|
42 |
+
"https://huggingface.co/latent-consistency/lcm-lora-sdxl/blob/main/pytorch_lora_weights.safetensors",
|
43 |
+
]
|
44 |
+
|
45 |
+
|
46 |
+
sdxl_preset_dict = {
|
47 |
+
"Default": [DEFAULT_DTYPE, "", "Euler a", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0],
|
48 |
+
"Bake in standard VAE": [DEFAULT_DTYPE, "https://huggingface.co/madebyollin/sdxl-vae-fp16-fix/blob/main/sdxl.vae.safetensors",
|
49 |
+
"Euler a", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0],
|
50 |
+
"Hyper-SDXL / SPO": [DEFAULT_DTYPE, "https://huggingface.co/madebyollin/sdxl-vae-fp16-fix/blob/main/sdxl.vae.safetensors",
|
51 |
+
"TCD", "https://huggingface.co/ByteDance/Hyper-SD/blob/main/Hyper-SDXL-8steps-CFG-lora.safetensors", 1.0,
|
52 |
+
"https://huggingface.co/SPO-Diffusion-Models/SPO-SDXL_4k-p_10ep_LoRA/blob/main/spo_sdxl_10ep_4k-data_lora_diffusers.safetensors",
|
53 |
+
1.0, "", 1.0, "", 1.0, "", 1.0],
|
54 |
+
}
|
55 |
+
|
56 |
+
|
57 |
+
def sdxl_set_presets(preset: str="Default"):
|
58 |
+
p = []
|
59 |
+
if preset in sdxl_preset_dict.keys(): p = sdxl_preset_dict[preset]
|
60 |
+
else: p = sdxl_preset_dict["Default"]
|
61 |
+
return p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7], p[8], p[9], p[10], p[11], p[12]
|
62 |
+
|
63 |
+
|
64 |
+
sd15_vaes = [
|
65 |
+
"",
|
66 |
+
"https://huggingface.co/stabilityai/sd-vae-ft-mse-original/resolve/main/vae-ft-mse-840000-ema-pruned.ckpt",
|
67 |
+
"https://huggingface.co/stabilityai/sd-vae-ft-ema-original/resolve/main/vae-ft-ema-560000-ema-pruned.ckpt",
|
68 |
+
]
|
69 |
+
|
70 |
+
|
71 |
+
sd15_loras = [
|
72 |
+
"",
|
73 |
+
"https://huggingface.co/SPO-Diffusion-Models/SPO-SD-v1-5_4k-p_10ep_LoRA/blob/main/spo-sd-v1-5_4k-p_10ep_lora_diffusers.safetensors",
|
74 |
+
]
|
75 |
+
|
76 |
+
|
77 |
+
sd15_preset_dict = {
|
78 |
+
"Default": [DEFAULT_DTYPE, "", "Euler", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0, True],
|
79 |
+
"Bake in standard VAE": [DEFAULT_DTYPE, "https://huggingface.co/stabilityai/sd-vae-ft-mse-original/resolve/main/vae-ft-mse-840000-ema-pruned.ckpt",
|
80 |
+
"Euler", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0, True],
|
81 |
+
}
|
82 |
+
|
83 |
+
|
84 |
+
def sd15_set_presets(preset: str="Default"):
|
85 |
+
p = []
|
86 |
+
if preset in sd15_preset_dict.keys(): p = sd15_preset_dict[preset]
|
87 |
+
else: p = sd15_preset_dict["Default"]
|
88 |
+
return p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7], p[8], p[9], p[10], p[11], p[12], p[13]
|
89 |
+
|
90 |
+
|
91 |
+
flux_vaes = [
|
92 |
+
"",
|
93 |
+
]
|
94 |
+
|
95 |
+
|
96 |
+
flux_loras = [
|
97 |
+
"",
|
98 |
+
]
|
99 |
+
|
100 |
+
|
101 |
+
flux_preset_dict = {
|
102 |
+
"dev": ["bf16", "", "", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0, "camenduru/FLUX.1-dev-diffusers"],
|
103 |
+
"schnell": ["bf16", "", "", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0, "black-forest-labs/FLUX.1-schnell"],
|
104 |
+
}
|
105 |
+
|
106 |
+
|
107 |
+
def flux_set_presets(preset: str="dev"):
|
108 |
+
p = []
|
109 |
+
if preset in flux_preset_dict.keys(): p = flux_preset_dict[preset]
|
110 |
+
else: p = flux_preset_dict["dev"]
|
111 |
+
return p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7], p[8], p[9], p[10], p[11], p[12], p[13]
|
112 |
+
|
113 |
+
|
114 |
+
|
115 |
+
sd35_vaes = [
|
116 |
+
"",
|
117 |
+
]
|
118 |
+
|
119 |
+
|
120 |
+
sd35_loras = [
|
121 |
+
"",
|
122 |
+
]
|
123 |
+
|
124 |
+
|
125 |
+
sd35_preset_dict = {
|
126 |
+
"Default": ["bf16", "", "", "", 1.0, "", 1.0, "", 1.0, "", 1.0, "", 1.0, "adamo1139/stable-diffusion-3.5-large-ungated"],
|
127 |
+
}
|
128 |
+
|
129 |
+
|
130 |
+
def sd35_set_presets(preset: str="dev"):
|
131 |
+
p = []
|
132 |
+
if preset in sd35_preset_dict.keys(): p = sd35_preset_dict[preset]
|
133 |
+
else: p = sd35_preset_dict["Default"]
|
134 |
+
return p[0], p[1], p[2], p[3], p[4], p[5], p[6], p[7], p[8], p[9], p[10], p[11], p[12], p[13]
|