Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

example regional-ipadapter workflow error #37

Open
j2l opened this issue Mar 27, 2024 · 7 comments
Open

example regional-ipadapter workflow error #37

j2l opened this issue Mar 27, 2024 · 7 comments

Comments

@j2l
Copy link

j2l commented Mar 27, 2024

Thank you for your nodes and examples. I downloaded regional-ipadapter.png and since it's also a workflow, I try to run it locally.
I only added photos, changed prompt and model to SD1.5:

Error occurred when executing ApplyRegionalIPAdapters //Inspire:

'NoneType' object has no attribute 'patcher'

  File "/mnt/phil/ComfyUI/execution.py", line 152, in recursive_execute
    output_data, output_ui = get_output_data(obj, input_data_all)
  File "/mnt/phil/ComfyUI/execution.py", line 82, in get_output_data
    return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
  File "/mnt/phil/ComfyUI/execution.py", line 75, in map_node_over_list
    results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
  File "/mnt/phil/ComfyUI/custom_nodes/ComfyUI-Inspire-Pack/inspire/regional_nodes.py", line 383, in doit
    model = v.doit(ipadapter_pipe)
  File "/mnt/phil/ComfyUI/custom_nodes/ComfyUI-Inspire-Pack/inspire/regional_nodes.py", line 235, in doit
    model = obj().apply_ipadapter(ipadapter, model, self.weight, clip_vision=clip_vision, image=self.image,
  File "/mnt/phil/ComfyUI/custom_nodes/ComfyUI_IPAdapter_plus/IPAdapterPlus.py", line 751, in apply_ipadapter
    clip_embed = encode_image_masked(clip_vision, image, clip_vision_mask)
  File "/mnt/phil/ComfyUI/custom_nodes/ComfyUI_IPAdapter_plus/IPAdapterPlus.py", line 270, in encode_image_masked
    comfy.model_management.load_model_gpu(clip_vision.patcher)

If I try with SDXL (JuggernautXL), I get another error:

Error occurred when executing ApplyRegionalIPAdapters //Inspire:

'NoneType' object is not subscriptable

  File "/mnt/phil/ComfyUI/execution.py", line 152, in recursive_execute
    output_data, output_ui = get_output_data(obj, input_data_all)
  File "/mnt/phil/ComfyUI/execution.py", line 82, in get_output_data
    return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
  File "/mnt/phil/ComfyUI/execution.py", line 75, in map_node_over_list
    results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
  File "/mnt/phil/ComfyUI/custom_nodes/ComfyUI-Inspire-Pack/inspire/regional_nodes.py", line 383, in doit
    model = v.doit(ipadapter_pipe)
  File "/mnt/phil/ComfyUI/custom_nodes/ComfyUI-Inspire-Pack/inspire/regional_nodes.py", line 235, in doit
    model = obj().apply_ipadapter(ipadapter, model, self.weight, clip_vision=clip_vision, image=self.image,
  File "/mnt/phil/ComfyUI/custom_nodes/ComfyUI_IPAdapter_plus/IPAdapterPlus.py", line 688, in apply_ipadapter
    self.is_full = "proj.3.weight" in ipadapter["image_proj"]

Screenshot from 2024-03-27 14-06-38

Any idea what am I doing wrong?

@ltdrdata
Copy link
Owner

image

Make sure model helper preset.
And make sure IPAdapter Plus and Inspire Pack both up to date.

@j2l
Copy link
Author

j2l commented Mar 27, 2024

Thank you @ltdrdata
Redoing from scratch:

  • Updating IPAdapter Plus and Inspire
    • Restart, re-import original workflow:
      image
      image
  • Staying on SDXL, new error argument of type 'NoneType' is not iterable:
    image

Here's the workflow (using sdxl base & example.png):
workflow.json

I'm using Ubuntu 22.04, Driver Version: 550.54.14, CUDA Version: 12.4, RTX 3060 12GB

@ltdrdata
Copy link
Owner

Thank you @ltdrdata
Redoing from scratch:

  • Updating IPAdapter Plus and Inspire
    • Restart, re-import original workflow:
      image
      image
  • Staying on SDXL, new error argument of type 'NoneType' is not iterable:
    image

Here's the workflow (using sdxl base & example.png):
workflow.json

I'm using Ubuntu 22.04, Driver Version: 550.54.14, CUDA Version: 12.4, RTX 3060 12GB

You need to download missing model filed.
https://youtu.be/FeeIHjt64SY?feature=shared

@j2l
Copy link
Author

j2l commented Mar 28, 2024

OK @ltdrdata I downloaded IPadapter and CLIPVision models (many).
No more error, but crappy result (all images are 512x512):
image
checkpoint is a XL, but not SDXL base.

@ltdrdata
Copy link
Owner

See the mask preview; it's not being generated correctly. This indicates that the image passed through color_mask is not composed of accurate RGB values.

@j2l
Copy link
Author

j2l commented Mar 28, 2024

@ltdrdata thank you.
When resizing it was saved as jpg, Red and Blue were #FE, not #FF anymore and a lot of compression artifacts were messing around.
It works:
image

@j2l
Copy link
Author

j2l commented Mar 28, 2024

BTW, the checkpoint + IPAdapter + CLIPVision models are heavy on my 3060 (12GB) and I had to reboot multiple times because it freezes the PC.
Do you know which combo of models is enough to make it work?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants