fofr / cog-comfyui

Run ComfyUI with an API
https://replicate.com/fofr/any-comfyui-workflow
MIT License
543 stars 124 forks source link

Broken InstantID - Insightface | Fail to initialize even for default workflow #166

Closed Takyon236 closed 1 month ago

Takyon236 commented 2 months ago

InstantID Workflow - Null insightface output

Issue Description

The workflow for InstantID appears to be broken. Regardless of the configuration used with the latest version, the following error is consistently encountered:

"insightface": [
  null
],
"exception_type": "ValueError",

Error Traceback

Traceback (most recent call last):
  File "/src/ComfyUI/execution.py", line 378, in execute
    output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
  File "/src/ComfyUI/execution.py", line 225, in get_output_data
    return_values = *map*node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
  File "/src/ComfyUI/execution.py", line 177, in *map*node_over_list
    process_inputs(input_dict, i)
  File "/src/ComfyUI/execution.py", line 166, in process_inputs
    results.append(getattr(obj, func)(**inputs))
ValueError: [Error details not provided in the original report]

Here is the result of me digging in the code to find out that the insightface wasn't working properly even out of the box with a default workflow, while it work perfectly in normal Comfy.

I tried to fix myself without much success, thank you.