cubiq / ComfyUI_IPAdapter_plus

GNU General Public License v3.0
3.2k stars 240 forks source link

Unified Loader FaceIDdoesn't want to use yaml path #425

Closed koppimashin closed 2 months ago

koppimashin commented 3 months ago

Works fine when using SDXL models, then decided to try with SD1.5 so I made minor adjustment until it doesn't want to read the yaml anymore but as you can see clip vision was perfectly loaded from the yaml path.

INFO: Clip Vision model loaded from E:/comfyuimodels/models/clip_vision/CLIP-ViT-H-14-laion2B-s32B-b79K.safetensors !!! Exception during processing !!! Traceback (most recent call last): File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 151, in recursive_execute output_data, output_ui = get_output_data(obj, input_data_all) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 81, in get_output_data return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 74, in map_node_over_list results.append(getattr(obj, func)(**slice_dict(input_data_all, i))) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI_IPAdapter_plus\IPAdapterPlus.py", line 422, in load_models raise Exception("IPAdapter model not found.") Exception: IPAdapter model not found. image

lovisdotio commented 3 months ago

Same error here

cubiq commented 3 months ago

the models are all loaded from the same location, if one works they should all work. it's probably a file name issue

koppimashin commented 3 months ago

I actually first tried it on the sd15 and it worked perfectly then spent most of the time on the sdxl lightning models then tried going back to the sd15, and this happened.

koppimashin commented 3 months ago

It works with the other model, turns out when I try to use "faceid plus sd1.5" that's where it can't find the model. So what I did was just avoid using that model and after a while of experimenting with other faceid models, I got this error.

!!! Exception during processing !!! Traceback (most recent call last): File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 151, in recursive_execute output_data, output_ui = get_output_data(obj, input_data_all) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 81, in get_output_data return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 74, in map_node_over_list results.append(getattr(obj, func)(**slice_dict(input_data_all, i))) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI_IPAdapter_plus\IPAdapterPlus.py", line 420, in load_models ipadapter_file, is_insightface, lora_pattern = get_ipadapter_file(preset, is_sdxl) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI_IPAdapter_plus\utils.py", line 29, in get_ipadapter_file ipadapter_list = folder_paths.get_filename_list("ipadapter") ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\folder_paths.py", line 221, in get_filename_list out = cached_filenamelist(folder_name) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\folder_paths.py", line 209, in cached_filenamelist if os.path.getmtime(folder) != time_modified: ^^^^^^^^^^^^^^^^^^^^^^^^ File "", line 55, in getmtime FileNotFoundError: [WinError 2] The system cannot find the file specified: 'E:/comfyuimodels/models/ipadapter/'

Prompt executed in 0.06 seconds got prompt [rgthree] Using rgthree's optimized recursive execution. !!! Exception during processing !!! Traceback (most recent call last): File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 151, in recursive_execute output_data, output_ui = get_output_data(obj, input_data_all) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 81, in get_output_data return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 74, in map_node_over_list results.append(getattr(obj, func)(**slice_dict(input_data_all, i))) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI_IPAdapter_plus\IPAdapterPlus.py", line 420, in load_models ipadapter_file, is_insightface, lora_pattern = get_ipadapter_file(preset, is_sdxl) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI_IPAdapter_plus\utils.py", line 29, in get_ipadapter_file ipadapter_list = folder_paths.get_filename_list("ipadapter") ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\folder_paths.py", line 221, in get_filename_list out = cached_filenamelist(folder_name) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\folder_paths.py", line 209, in cached_filenamelist if os.path.getmtime(folder) != time_modified: ^^^^^^^^^^^^^^^^^^^^^^^^ File "", line 55, in getmtime FileNotFoundError: [WinError 2] The system cannot find the file specified: 'E:/comfyuimodels/models/ipadapter/'

Mozoloa commented 3 months ago

I have the same problem, clearly got "G:\AI\Image\Stable Diffusion\Data\Models\IpAdapter" in my extra paths, and all of its content is detected by other nodes (before the update, it's where I loaded the adapters from, for my faceid workflow), the models are at the root of it, I even copied all the name from the readme to make sure they matched, still :

Error occurred when executing IPAdapterUnifiedLoaderFaceID:

IPAdapter model not found.
koppimashin commented 3 months ago

Is uninstalling IPAdapter nodes the culprit? I checked the IPAdapter models folder, but it seems like the entire folder vanished. It feels like it self-deleted somehow.

BTW when I tried redownloading the models for the second time, it said the file already existed, even though I couldn't see it anywhere. When the FaceID Plus SD1.5 issue first occurred, I verified its presence, and then I redownloaded everything just to be safe. But it still couldn't find the model.

Screenshot_46 Screenshot_1

green-anger commented 2 months ago

the models are all loaded from the same location, if one works they should all work. it's probably a file name issue

@cubiq Can you elaborate what this from the description mean, The models can be placed into sub-directories?

I thought it'd scan all the sub-directories, track all files and then pick the first one found when the name matches. I kept the same relative structure as in h94 huggingface repo, so it has two directories sd15 and sdxl and each has directory image_encoder with relative clip vision model. Plus both main directories are nested in couple of other dirs for convenience.

How does it search for the models? Should it all be in one single directory?

UPD: I moved clip vision models to {Comfy}/models/clip_vision and it worked, so I assume those goes separately. I'm wondering if it can be moved with extra_model_paths.yaml parameter like it works with undocumented ipadapter option now.

sanane-ulan commented 2 months ago

I have the same problem, clearly got "G:\AI\Image\Stable Diffusion\Data\Models\IpAdapter" in my extra paths, and all of its content is detected by other nodes (before the update, it's where I loaded the adapters from, for my faceid workflow), the models are at the root of it, I even copied all the name from the readme to make sure they matched, still :

Error occurred when executing IPAdapterUnifiedLoaderFaceID:

IPAdapter model not found.

Same problem here

rajinipreethajohn commented 2 months ago

Same problem here!

Error occurred when executing IPAdapterUnifiedLoader:

IPAdapter model not found.

escalate007 commented 2 months ago

Works fine when using SDXL models, then decided to try with SD1.5 so I made minor adjustment until it doesn't want to read the yaml anymore but as you can see clip vision was perfectly loaded from the yaml path.

INFO: Clip Vision model loaded from E:/comfyuimodels/models/clip_vision/CLIP-ViT-H-14-laion2B-s32B-b79K.safetensors !!! Exception during processing !!! Traceback (most recent call last): File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 151, in recursive_execute output_data, output_ui = get_output_data(obj, input_data_all) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 81, in get_output_data return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\execution.py", line 74, in map_node_over_list results.append(getattr(obj, func)(**slice_dict(input_data_all, i))) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI_IPAdapter_plus\IPAdapterPlus.py", line 422, in load_models raise Exception("IPAdapter model not found.") Exception: IPAdapter model not found. image

it happened to me

escalate007 commented 2 months ago

图片 All file names were checked carefully.But whenI ran 'faceid plus sd1.5 only'with SD15 Model,this error occoured as same as @koppimashin.

At the same time,the other three preset method 'faceid', 'face plusV2' and'faceid portrait' went smoothly without problem. Only this one are out of work. 图片

By the way,I found 5 preset methods below in the ipadapterunifiedloader are OK. 图片

escalate007 commented 2 months ago

aha,I found it. ip-adapter-faceid-plus_sd15.bin and faceid-plus_sd15_lora.safetensors are for 'faceid plus sd1.5 only',I put them back to models/ipadapter folder. It works now!

koppimashin commented 2 months ago

aha,I found it. ip-adapter-faceid-plus_sd15.bin and faceid-plus_sd15_lora.safetensors are for 'faceid plus sd1.5 only',I put them back to models/ipadapter folder. It works now

@escalate007 did you fix it so we can close this? we have the same exact problem.

escalate007 commented 2 months ago

aha,I found it. ip-adapter-faceid-plus_sd15.bin and faceid-plus_sd15_lora.safetensors are for 'faceid plus sd1.5 only',I put them back to models/ipadapter folder. It works now

@escalate007 did you fix it so we can close this? we have the same exact problem.

Ok if you solved it too.