XLabs-AI / x-flux-comfyui

Apache License 2.0
1.1k stars 72 forks source link

Error occurred when executing LoadFluxControlNet: #30

Closed kakachiex2 closed 3 months ago

kakachiex2 commented 3 months ago

I'm getting this error wen executing controlnet.

Error occurred when executing LoadFluxControlNet:

Error(s) in loading state_dict for ControlNetFlux: Unexpected key(s) in state_dict: "guidance_in.in_layer.bias", "guidance_in.in_layer.weight", "guidance_in.out_layer.bias", "guidance_in.out_layer.weight".

File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 316, 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 "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 191, 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 "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 168, in _map_node_over_list process_inputs(input_dict, i) File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 157, in process_inputs results.append(getattr(obj, func)(**inputs)) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\custom_nodes\x-flux-comfyui\nodes.py", line 203, in loadmodel controlnet.load_state_dict(checkpoint) File "K:\ComfyUI\ComfyUI_Ex\python_miniconda_env\ComfyUI\Lib\site-packages\torch\nn\modules\module.py", line 2153, in load_state_dict raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format(

kakachiex2 commented 3 months ago

New errors wen executing xlabsSampler

Error occurred when executing XlabsSampler:

'NoneType' object is not subscriptable

File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 316, 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 "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 191, 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 "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 168, in _map_node_over_list process_inputs(input_dict, i) File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 157, in process_inputs results.append(getattr(obj, func)(**inputs)) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\custom_nodes\x-flux-comfyui\nodes.py", line 294, in sampling bc, c, h, w = latent_image['samples'].shape

kakachiex2 commented 3 months ago

Ok fixed I forgot to add empty latent image node.

kakachiex2 commented 3 months ago

Another one

Error occurred when executing XlabsSampler:

No operator found for memory_efficient_attention_forward with inputs: query : shape=(24, 4352, 1, 128) (torch.bfloat16) key : shape=(24, 4352, 1, 128) (torch.bfloat16) value : shape=(24, 4352, 1, 128) (torch.bfloat16) attn_bias : p : 0.0 decoderF is not supported because: attn_bias type is bf16 is only supported on A100+ GPUs flshattF@v2.5.6 is not supported because: requires device with capability > (8, 0) but your GPU has capability (7, 5) (too old) bf16 is only supported on A100+ GPUs cutlassF is not supported because: bf16 is only supported on A100+ GPUs smallkF is not supported because: max(query.shape[-1] != value.shape[-1]) > 32 dtype=torch.bfloat16 (supported: {torch.float32}) bf16 is only supported on A100+ GPUs unsupported embed per head: 128

File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 316, 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 "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 191, 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 "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 168, in _map_node_over_list process_inputs(input_dict, i) File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\execution.py", line 157, in process_inputs results.append(getattr(obj, func)(inputs)) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\custom_nodes\x-flux-comfyui\nodes.py", line 348, in sampling x = denoise_controlnet( ^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\custom_nodes\x-flux-comfyui\sampling.py", line 264, in denoise_controlnet pred = model_forward( ^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\custom_nodes\x-flux-comfyui\sampling.py", line 41, in model_forward img, txt = block(img=img, txt=txt, vec=vec, pe=pe) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\python_miniconda_env\ComfyUI\Lib\site-packages\torch\nn\modules\module.py", line 1511, in _wrapped_call_impl return self._call_impl(*args, *kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\python_miniconda_env\ComfyUI\Lib\site-packages\torch\nn\modules\module.py", line 1520, in _call_impl return forward_call(args, kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\comfy\ldm\flux\layers.py", line 166, in forward attn = attention(torch.cat((txt_q, img_q), dim=2), ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\comfy\ldm\flux\math.py", line 11, in attention x = optimized_attention(q, k, v, heads, skip_reshape=True) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\ComfyUI\comfy\ldm\modules\attention.py", line 380, in attention_xformers out = xformers.ops.memory_efficient_attention(q, k, v, attn_bias=mask) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\python_miniconda_env\ComfyUI\Lib\site-packages\xformers\ops\fmha__init.py", line 247, in memory_efficient_attention return _memory_efficient_attention( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\python_miniconda_env\ComfyUI\Lib\site-packages\xformers\ops\fmha\init.py", line 365, in _memory_efficient_attention return _memory_efficient_attention_forward( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\python_miniconda_env\ComfyUI\Lib\site-packages\xformers\ops\fmha\init__.py", line 381, in _memory_efficient_attention_forward op = _dispatch_fw(inp, False) ^^^^^^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\python_miniconda_env\ComfyUI\Lib\site-packages\xformers\ops\fmha\dispatch.py", line 125, in _dispatch_fw return _run_priority_list( ^^^^^^^^^^^^^^^^^^^ File "K:\ComfyUI\ComfyUI_Ex\python_miniconda_env\ComfyUI\Lib\site-packages\xformers\ops\fmha\dispatch.py", line 65, in _run_priority_list raise NotImplementedError(msg)

Vovanm88 commented 3 months ago

fixed, update (via git pull for example or remove dir and clone again)

kakachiex2 commented 2 months ago

Thanks, is working