Resolutions, remove flux.1
This commit is contained in:
parent
ca33869007
commit
689cd1244c
@ -13,21 +13,7 @@ Detailed Prompting Guide:
|
|||||||
- Settings: Keep CFG between 5.0 and 7.0; higher values can cause color burn.
|
- Settings: Keep CFG between 5.0 and 7.0; higher values can cause color burn.
|
||||||
- Sampler: Works well with DPM++ 2M SDE.
|
- Sampler: Works well with DPM++ 2M SDE.
|
||||||
"""
|
"""
|
||||||
"Resolution Set" = "anime_xl"
|
"Resolution Set" = "sdxl"
|
||||||
"CFG Scale" = 6.0
|
"CFG Scale" = 6.0
|
||||||
"Sampling Steps" = 28
|
"Sampling Steps" = 28
|
||||||
"Sampling Method" = "DPM++ 2M SDE"
|
"Sampling Method" = "DPM++ 2M SDE"
|
||||||
|
|
||||||
["flux1-dev"]
|
|
||||||
description = "State-of-the-art general purpose model, takes natural language."
|
|
||||||
guide = """
|
|
||||||
Detailed Prompting Guide:
|
|
||||||
- Style: Natural Language. Describe the scene as you would to a human.
|
|
||||||
- Negatives: Generally doesn't require a negative prompt.
|
|
||||||
- Settings: Works best with higher resolutions (1024+).
|
|
||||||
- Sampler: Flux Realistic or Euler.
|
|
||||||
"""
|
|
||||||
"Resolution Set" = "flux_standard"
|
|
||||||
"CFG Scale" = 3.5
|
|
||||||
"Sampling Steps" = 20
|
|
||||||
"Sampling Method" = "Flux Realistic"
|
|
||||||
|
|||||||
@ -1,15 +1,9 @@
|
|||||||
# Resolution Presets
|
# Resolution Presets
|
||||||
# Format: [preset_name]
|
# Format: [preset_name]
|
||||||
# width and height are mandatory.
|
# Values: "WidthxHeight"
|
||||||
|
|
||||||
[anime_xl]
|
[sdxl]
|
||||||
square = { width = 1024, height = 1024 }
|
widescreen = "1344x768"
|
||||||
portrait = { width = 832, height = 1216 }
|
landscape = "1152x896"
|
||||||
landscape = { width = 1216, height = 832 }
|
square = "1024x1024"
|
||||||
widescreen = { width = 1536, height = 640 }
|
portrait = "896x1152"
|
||||||
|
|
||||||
[flux_standard]
|
|
||||||
square = { width = 1024, height = 1024 }
|
|
||||||
portrait = { width = 896, height = 1152 }
|
|
||||||
landscape = { width = 1152, height = 896 }
|
|
||||||
widescreen = { width = 1344, height = 768 }
|
|
||||||
|
|||||||
@ -75,11 +75,15 @@ async def handle(args: Dict[str, Any]) -> List[Dict[str, Any]]:
|
|||||||
if res_set_name and res_set_name in res_cfg:
|
if res_set_name and res_set_name in res_cfg:
|
||||||
res_set = res_cfg[res_set_name]
|
res_set = res_cfg[res_set_name]
|
||||||
if res_preset_name in res_set:
|
if res_preset_name in res_set:
|
||||||
res_vals = res_set[res_preset_name]
|
res_val_str = res_set[res_preset_name]
|
||||||
if "Width" in label_map:
|
try:
|
||||||
payload[label_map["Width"]] = res_vals["width"]
|
w, h = map(int, res_val_str.split('x'))
|
||||||
if "Height" in label_map:
|
if "Width" in label_map:
|
||||||
payload[label_map["Height"]] = res_vals["height"]
|
payload[label_map["Width"]] = w
|
||||||
|
if "Height" in label_map:
|
||||||
|
payload[label_map["Height"]] = h
|
||||||
|
except (ValueError, AttributeError):
|
||||||
|
raise ToolError(f"Invalid resolution format for preset '{res_preset_name}': {res_val_str}. Expected 'WidthxHeight'.")
|
||||||
else:
|
else:
|
||||||
raise ToolError(f"Resolution preset '{res_preset_name}' not found for this model. Available: {', '.join(res_set.keys())}")
|
raise ToolError(f"Resolution preset '{res_preset_name}' not found for this model. Available: {', '.join(res_set.keys())}")
|
||||||
else:
|
else:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user