From 61a273236ffd1366456cac7040e30972ca65dc2c Mon Sep 17 00:00:00 2001 From: Allen Benz Date: Sat, 24 Dec 2022 20:23:12 -0800 Subject: [PATCH] Fix clip interrogate from the webui A recent change made the image RGBA, which makes the clip interrogator unhappy. deepbooru and calling the interrogator from the api already do the conversion so this is the only place that needed it. --- modules/ui.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/ui.py b/modules/ui.py index 9dec61d5..7bf5abd9 100644 --- a/modules/ui.py +++ b/modules/ui.py @@ -270,7 +270,7 @@ def apply_styles(prompt, prompt_neg, style1_name, style2_name): def interrogate(image): - prompt = shared.interrogator.interrogate(image) + prompt = shared.interrogator.interrogate(image.convert("RGB")) return gr_show(True) if prompt is None else prompt