From fff39eac3b06d4ed45fc7406dda33a94858b34ff Mon Sep 17 00:00:00 2001 From: huchenlei Date: Sun, 5 May 2024 10:06:42 -0400 Subject: [PATCH] Quickfix Enum Issue 2 --- scripts/controlnet.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/controlnet.py b/scripts/controlnet.py index 72dbddb7a..9bea442be 100644 --- a/scripts/controlnet.py +++ b/scripts/controlnet.py @@ -1216,7 +1216,12 @@ def recolor_intensity_post_processing(x, i): weight = param.weight h, w, hr_y, hr_x = Script.get_target_dimensions(p) - pulid_mode = PuLIDMode(unit.pulid_mode) if isinstance(unit.pulid_mode, str) else unit.pulid_mode + # TODO: Fix all enum issue + if unit.pulid_mode == "PuLIDMode.FIDELITY": + pulid_mode = PuLIDMode.FIDELITY + else: + pulid_mode = PuLIDMode(unit.pulid_mode) + if pulid_mode == PuLIDMode.STYLE: pulid_attn_setting = PULID_SETTING_STYLE else: