diff --git a/modules/processing_args.py b/modules/processing_args.py index 565022428..fe3d623ad 100644 --- a/modules/processing_args.py +++ b/modules/processing_args.py @@ -127,7 +127,7 @@ def task_specific_kwargs(p, model): 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 ('QwenImageLayeredPipeline' in model_cls) and (p.init_control is not None) and (len(p.init_images) > 0): + 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] if ('Flux2' in model_cls) and (p.init_control is not None) and (len(p.init_control) > 0): task_args['image'] += p.init_control diff --git a/pipelines/model_qwen.py b/pipelines/model_qwen.py index 0e3a21525..627b5d6da 100644 --- a/pipelines/model_qwen.py +++ b/pipelines/model_qwen.py @@ -27,9 +27,9 @@ def load_qwen(checkpoint_info, diffusers_load_config=None): diffusers.pipelines.auto_pipeline.AUTO_INPAINT_PIPELINES_MAPPING["qwen-image"] = diffusers.QwenImageEditPipeline elif 'Layered' in repo_id: cls_name = diffusers.QwenImageLayeredPipeline - diffusers.pipelines.auto_pipeline.AUTO_TEXT2IMAGE_PIPELINES_MAPPING["qwen-layered"] = diffusers.QwenImageEditPipeline - diffusers.pipelines.auto_pipeline.AUTO_IMAGE2IMAGE_PIPELINES_MAPPING["qwen-layered"] = diffusers.QwenImageEditPipeline - diffusers.pipelines.auto_pipeline.AUTO_INPAINT_PIPELINES_MAPPING["qwen-layered"] = diffusers.QwenImageEditPipeline + diffusers.pipelines.auto_pipeline.AUTO_TEXT2IMAGE_PIPELINES_MAPPING["qwen-layered"] = diffusers.QwenImageLayeredPipeline + diffusers.pipelines.auto_pipeline.AUTO_IMAGE2IMAGE_PIPELINES_MAPPING["qwen-layered"] = diffusers.QwenImageLayeredPipeline + diffusers.pipelines.auto_pipeline.AUTO_INPAINT_PIPELINES_MAPPING["qwen-layered"] = diffusers.QwenImageLayeredPipeline else: cls_name = diffusers.QwenImagePipeline diffusers.pipelines.auto_pipeline.AUTO_TEXT2IMAGE_PIPELINES_MAPPING["qwen-image"] = diffusers.QwenImagePipeline