mirror of
https://github.com/vladmandic/automatic
synced 2026-09-20 01:31:13 +02:00
fix kandinsky detection
Co-authored-by: Copilot <copilot@github.com> Signed-off-by: Vladimir Mandic <mandic00@live.com>
This commit is contained in:
+3
-5
@@ -1,17 +1,14 @@
|
||||
# Change Log for SD.Next
|
||||
|
||||
## TODO
|
||||
|
||||
- Tag multi-image pipes with `use_images_direct` and allow UI override
|
||||
|
||||
## Update for 2026-05-02
|
||||
|
||||
- **Features**
|
||||
- **Multi-image** workflows!
|
||||
for models that support multiple images as inputs, you can now add multiple stages in Kanvas
|
||||
prompts like "*place character from first image, add background from second image, render in style from third image*" are now possible
|
||||
- option *inputs -> skip processing* to force images to passed to model as-is without any pre-processing
|
||||
examples of models that support multi-inputs: *qwen-image-edit, flux.2, google-gemini*
|
||||
- **Anima** support for *img2img* and *inpaint* workflows
|
||||
- option *inputs -> skip processing* to force images to passed to model as-is without any pre-processing
|
||||
- **UI**
|
||||
- add button to manually reorient input/output panels
|
||||
- all ui panels can be minimized/maximized by clicking on their header
|
||||
@@ -29,6 +26,7 @@
|
||||
- save handle already decoded images
|
||||
- ernie-image preview
|
||||
- lora false deactivate
|
||||
- kandinsky-5 t2i/i2i workflows
|
||||
|
||||
## Update for 2026-04-28
|
||||
|
||||
|
||||
@@ -129,14 +129,11 @@ def task_specific_kwargs(p, model):
|
||||
}
|
||||
|
||||
# model specific args
|
||||
if ('QwenImageEdit' in model_cls) and (p.init_images is None or len(p.init_images) == 0):
|
||||
task_args['image'] = [Image.new('RGB', (p.width, p.height), (0, 0, 0))] # monkey-patch so qwen-image-edit pipeline does not error-out on t2i
|
||||
if ('QwenImageEditPlusPipeline' in model_cls) and (p.init_control is not None) and (len(p.init_control) > 0):
|
||||
task_args['image'] += p.init_control
|
||||
if (('QwenImageEdit' in model_cls) or ('Kandinsky5I2IPipeline' in model_cls)) and (p.init_images is None or len(p.init_images) == 0):
|
||||
log.debug(f'Model init: cls={model_cls} image=blank')
|
||||
task_args['image'] = [Image.new('RGB', (p.width, p.height), (0, 0, 0))] # monkey-patch so i2i pipeline does not error-out on t2i
|
||||
if ('QwenImageLayeredPipeline' in model_cls) and (p.init_images is not None) and (len(p.init_images) > 0):
|
||||
task_args['image'] = p.init_images[0].convert('RGBA')
|
||||
if ('Flux2' in model_cls) and (p.init_control is not None) and (len(p.init_control) > 0):
|
||||
task_args['image'] += p.init_control
|
||||
if ('LatentConsistencyModelPipeline' in model_cls) and (len(p.init_images) > 0):
|
||||
p.ops.append('lcm')
|
||||
init_latents = [processing_vae.vae_encode(image, model=shared.sd_model, vae_type=p.vae_type).squeeze(dim=0) for image in p.init_images]
|
||||
|
||||
@@ -126,7 +126,7 @@ def guess_by_name(fn, current_guess):
|
||||
new_guess = 'Kandinsky 2.2'
|
||||
elif 'kandinsky-3' in fn.lower():
|
||||
new_guess = 'Kandinsky 3.0'
|
||||
elif 'kandinsky-5.0' in fn.lower() and '2i' not in fn.lower():
|
||||
elif 'kandinsky-5.0' in fn.lower():
|
||||
new_guess = 'Kandinsky 5.0'
|
||||
elif 'hunyuanimage3' in fn.lower() or 'hunyuanimage-3' in fn.lower():
|
||||
new_guess = 'HunyuanImage3'
|
||||
|
||||
@@ -51,6 +51,7 @@ pipe_switch_task_exclude = [
|
||||
'NucleusMoEImagePipeline',
|
||||
'AuraFlowPipeline',
|
||||
'ChronoEditPipeline',
|
||||
'Kandinsky5I2IPipeline',
|
||||
'GoogleNanoBananaPipeline',
|
||||
]
|
||||
i2i_pipes = [
|
||||
@@ -482,7 +483,7 @@ def load_diffuser_force(detected_model_type, checkpoint_info, diffusers_load_con
|
||||
from pipelines.model_kandinsky import load_kandinsky3
|
||||
sd_model = load_kandinsky3(checkpoint_info, diffusers_load_config)
|
||||
allow_post_quant = False
|
||||
elif model_type in ['Kandinsky 5.0'] and model_type:
|
||||
elif model_type in ['Kandinsky 5.0']:
|
||||
from pipelines.model_kandinsky import load_kandinsky5
|
||||
sd_model = load_kandinsky5(checkpoint_info, diffusers_load_config)
|
||||
allow_post_quant = False
|
||||
|
||||
Reference in New Issue
Block a user