Added Firstpass width/height

firstphase_width and firstphase_height are now recognized values in config.json
This commit is contained in:
Zyin055
2022-12-13 13:26:05 -06:00
parent 0fe5fc5383
commit 1992e1eed7
2 changed files with 16 additions and 8 deletions

View File

@@ -6,8 +6,6 @@
"sampler_index": "DPM++ 2M Karras",
"width": 512,
"height": 512,
"enable_hr": false,
"denoising_strength": 0.7,
"batch_count": 1,
"batch_size": 8,
"cfg_scale": 7
@@ -17,8 +15,6 @@
"sampler_index": "DPM++ 2S a Karras",
"width": 512,
"height": 512,
"enable_hr": false,
"denoising_strength": 0.7,
"batch_count": 1,
"batch_size": 8,
"cfg_scale": 7
@@ -28,29 +24,31 @@
"sampler_index": "DPM++ 2S a Karras",
"width": 512,
"height": 512,
"enable_hr": false,
"denoising_strength": 0.7,
"batch_count": 1,
"batch_size": 8,
"cfg_scale": 7
},
"High res -------- 1024x1024, steps: 30, batch size: 1, DPM++ 2M Karras, Highres fix, Denoising: 0.4" : {
"High res -------- 1024x1024, steps: 30, batch size: 1, DPM++ 2M Karras, [Highres fix: 512x512, Denoising: 0.4]" : {
"steps": 30,
"sampler_index": "DPM++ 2M Karras",
"width": 1024,
"height": 1024,
"enable_hr": true,
"firstphase_width": 512,
"firstphase_height": 512,
"denoising_strength": 0.4,
"batch_count": 1,
"batch_size": 1,
"cfg_scale": 7
},
"Wallpaper ----- 1920x1088, steps: 30, batch size: 1, DPM++ 2M Karras, Highres fix, Denoising: 0.3" : {
"Wallpaper ----- 1920x1088, steps: 30, batch size: 1, DPM++ 2M Karras, [Highres fix: 768x448, Denoising: 0.3]" : {
"steps": 30,
"sampler_index": "DPM++ 2M Karras",
"width": 1920,
"height": 1088,
"enable_hr": true,
"firstphase_width": 768,
"firstphase_height": 448,
"denoising_strength": 0.3,
"batch_count": 1,
"batch_size": 1,

View File

@@ -22,6 +22,8 @@ class Script(scripts.Script):
"Width",
"Height",
"Highres. fix",
"Firstpass width",
"Firstpass height",
"Denoising strength",
"Batch count",
"Batch size",
@@ -70,6 +72,8 @@ class Script(scripts.Script):
config_preset["width"] if "width" in config_preset else self.component_map["Width"].value,
config_preset["height"] if "height" in config_preset else self.component_map["Height"].value,
config_preset["enable_hr"] if "enable_hr" in config_preset else self.component_map["Highres. fix"].value,
config_preset["firstphase_width"] if "firstphase_width" in config_preset else self.component_map["Firstpass width"].value,
config_preset["firstphase_height"] if "firstphase_height" in config_preset else self.component_map["Firstpass height"].value,
config_preset["denoising_strength"] if "denoising_strength" in config_preset else self.component_map["Denoising strength"].value,
config_preset["batch_count"] if "batch_count" in config_preset else self.component_map["Batch count"].value,
config_preset["batch_size"] if "batch_size" in config_preset else self.component_map["Batch size"].value,
@@ -83,6 +87,8 @@ class Script(scripts.Script):
config_preset["width"] if "width" in config_preset else self.component_map["Width"].value,
config_preset["height"] if "height" in config_preset else self.component_map["Height"].value,
#config_preset["enable_hr"] if "enable_hr" in config_preset else self.component_map["Highres. fix"].value,
#config_preset["firstphase_width"] if "firstphase_width" in config_preset else self.component_map["Firstpass width"].value,
#config_preset["firstphase_height"] if "firstphase_height" in config_preset else self.component_map["Firstpass height"].value,
config_preset["denoising_strength"] if "denoising_strength" in config_preset else self.component_map["Denoising strength"].value,
config_preset["batch_count"] if "batch_count" in config_preset else self.component_map["Batch count"].value,
config_preset["batch_size"] if "batch_size" in config_preset else self.component_map["Batch size"].value,
@@ -107,6 +113,8 @@ class Script(scripts.Script):
self.component_map["Width"],
self.component_map["Height"],
self.component_map["Highres. fix"],
self.component_map["Firstpass width"],
self.component_map["Firstpass height"],
self.component_map["Denoising strength"],
self.component_map["Batch count"],
self.component_map["Batch size"],
@@ -123,6 +131,8 @@ class Script(scripts.Script):
self.component_map["Width"],
self.component_map["Height"],
#self.component_map["Highres. fix"], no highres fix in img2img
#self.component_map["Firstpass width"],
#self.component_map["Firstpass height"],
self.component_map["Denoising strength"],
self.component_map["Batch count"],
self.component_map["Batch size"],