comfyanonymous / ComfyUI

The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface.
https://www.comfy.org/
GNU General Public License v3.0
57.91k stars 6.14k forks source link

KSampler 'NoneType' object has no attribute 'shape' #5356

Open ghost opened 1 month ago

ghost commented 1 month ago

Expected Behavior

fix the issue

Actual Behavior

1

Steps to Reproduce

ipiv-Morph-img2vid-AnimateDiff-HyperSD.json

the workflow i used.

Debug Logs

# ComfyUI Error Report
## Error Details
- **Node Type:** KSampler
- **Exception Type:** AttributeError
- **Exception Message:** 'NoneType' object has no attribute 'shape'
## Stack Trace

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\execution.py", line 323, 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 "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\execution.py", line 198, 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 "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\execution.py", line 169, in _map_node_over_list
    process_inputs(input_dict, i)

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\execution.py", line 158, in process_inputs
    results.append(getattr(obj, func)(**inputs))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\nodes.py", line 1437, in sample
    return common_ksampler(model, seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, denoise=denoise)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\nodes.py", line 1404, in common_ksampler
    samples = comfy.sample.sample(model, noise, steps, cfg, sampler_name, scheduler, positive, negative, latent_image,
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 526, in motion_sample
    latents = orig_comfy_sample(model, noise, *args, **kwargs)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\adv_control\sampling.py", line 116, in acn_sample
    return orig_comfy_sample(model, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\adv_control\utils.py", line 117, in uncond_multiplier_check_cn_sample
    return orig_comfy_sample(model, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\sample.py", line 43, in sample
    samples = sampler.sample(noise, positive, negative, cfg=cfg, latent_image=latent_image, start_step=start_step, last_step=last_step, force_full_denoise=force_full_denoise, denoise_mask=noise_mask, sigmas=sigmas, callback=callback, disable_pbar=disable_pbar, seed=seed)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 832, in sample
    return sample(self.model, noise, positive, negative, cfg, self.device, sampler, sigmas, self.model_options, latent_image=latent_image, denoise_mask=denoise_mask, callback=callback, disable_pbar=disable_pbar, seed=seed)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 732, in sample
    return cfg_guider.sample(noise, latent_image, sampler, sigmas, denoise_mask, callback, disable_pbar, seed)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 719, in sample
    output = self.inner_sample(noise, latent_image, device, sampler, sigmas, denoise_mask, callback, disable_pbar, seed)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 698, in inner_sample
    samples = sampler.sample(self, sigmas, extra_args, callback, noise, latent_image, denoise_mask, disable_pbar)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 603, in sample
    samples = self.sampler_function(model_k, noise, sigmas, extra_args=extra_args, callback=k_callback, disable=disable_pbar, **self.extra_options)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\python_embeded\Lib\site-packages\torch\utils\_contextlib.py", line 115, in decorate_context
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\k_diffusion\sampling.py", line 305, in sample_lms
    denoised = model(x, sigmas[i] * s_in, **extra_args)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 299, in __call__
    out = self.inner_model(x, sigma, model_options=model_options, seed=seed)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 685, in __call__
    return self.predict_noise(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 688, in predict_noise
    return sampling_function(self.inner_model, x, timestep, self.conds.get("negative", None), self.conds.get("positive", None), self.cfg, model_options=model_options, seed=seed)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 635, in evolved_sampling_function
    cond_pred, uncond_pred = sliding_calc_conds_batch(model, [cond, uncond_], x, timestep, model_options)
                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 887, in sliding_calc_conds_batch
    sub_conds_out = calc_conds_batch_wrapper(model, sub_conds, sub_x, sub_timestep, model_options)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 993, in calc_conds_batch_wrapper
    return comfy.samplers.calc_cond_batch(model, conds, x_in, timestep, model_options)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 202, in calc_cond_batch
    c['control'] = control.get_control(input_x, timestep_, c, len(cond_or_uncond))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\adv_control\utils.py", line 762, in get_control_inject
    return self.get_control_advanced(x_noisy, t, cond, batched_number)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\adv_control\control.py", line 44, in get_control_advanced
    return self.sliding_get_control(x_noisy, t, cond, batched_number)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\adv_control\control.py", line 102, in sliding_get_control
    control = self.control_model(x=x_noisy.to(dtype), hint=self.cond_hint, timesteps=timestep.to(dtype), context=context.to(dtype), **extra)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1532, in _wrapped_call_impl
    return self._call_impl(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1541, in _call_impl
    return forward_call(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\cldm\cldm.py", line 420, in forward
    assert y.shape[0] == x.shape[0]
           ^^^^^^^

System Information

Logs

2024-10-25 11:13:06,683 - root - INFO - Total VRAM 8188 MB, total RAM 64663 MB
2024-10-25 11:13:06,683 - root - INFO - pytorch version: 2.3.0+cu121
2024-10-25 11:13:06,684 - root - INFO - Set vram state to: NORMAL_VRAM
2024-10-25 11:13:06,684 - root - INFO - Device: cuda:0 NVIDIA GeForce RTX 4060 : cudaMallocAsync
2024-10-25 11:13:07,457 - root - INFO - Using pytorch cross attention
2024-10-25 11:13:07,929 - root - INFO - [Prompt Server] web root: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\web
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path checkpoints D:\Learning & Experiment\Stable Diffusion\models/Stable-diffusion
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path configs D:\Learning & Experiment\Stable Diffusion\models/Stable-diffusion
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path vae D:\Learning & Experiment\Stable Diffusion\models/VAE
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path loras D:\Learning & Experiment\Stable Diffusion\models/Lora
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path loras D:\Learning & Experiment\Stable Diffusion\models/LyCORIS
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path upscale_models D:\Learning & Experiment\Stable Diffusion\models/ESRGAN
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path upscale_models D:\Learning & Experiment\Stable Diffusion\models/RealESRGAN
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path upscale_models D:\Learning & Experiment\Stable Diffusion\models/SwinIR
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path embeddings D:\Learning & Experiment\Stable Diffusion\embeddings
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path hypernetworks D:\Learning & Experiment\Stable Diffusion\models/hypernetworks
2024-10-25 11:13:07,931 - root - INFO - Adding extra search path controlnet D:\Learning & Experiment\Stable Diffusion\extensions\sd-webui-controlnet\models
2024-10-25 11:13:08,279 - root - WARNING - Traceback (most recent call last):
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\nodes.py", line 2001, in load_custom_node
    module_spec.loader.exec_module(module)
  File "<frozen importlib._bootstrap_external>", line 936, in exec_module
  File "<frozen importlib._bootstrap_external>", line 1073, in get_code
  File "<frozen importlib._bootstrap_external>", line 1130, in get_data
FileNotFoundError: [Errno 2] No such file or directory: 'F:\\Learning & Experiment\\Stable Diffusion\\ComfyUI_windows\\ComfyUI\\custom_nodes\\animatediff\\__init__.py'

2024-10-25 11:13:08,279 - root - WARNING - Cannot import F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\animatediff module for custom nodes: [Errno 2] No such file or directory: 'F:\\Learning & Experiment\\Stable Diffusion\\ComfyUI_windows\\ComfyUI\\custom_nodes\\animatediff\\__init__.py'
2024-10-25 11:13:08,325 - root - INFO - Total VRAM 8188 MB, total RAM 64663 MB
2024-10-25 11:13:08,326 - root - INFO - pytorch version: 2.3.0+cu121
2024-10-25 11:13:08,326 - root - INFO - Set vram state to: NORMAL_VRAM
2024-10-25 11:13:08,326 - root - INFO - Device: cuda:0 NVIDIA GeForce RTX 4060 : cudaMallocAsync
2024-10-25 11:13:14,371 - numexpr.utils - INFO - Note: NumExpr detected 16 cores but "NUMEXPR_MAX_THREADS" not set, so enforcing safe limit of 8.
2024-10-25 11:13:14,371 - numexpr.utils - INFO - NumExpr defaulting to 8 threads.
2024-10-25 11:13:15,201 - root - INFO - 
Import times for custom nodes:
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\websocket_image_save.py
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\AIGODLIKE-COMFYUI-TRANSLATION
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI_SimpleMath
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds (IMPORT FAILED): F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\animatediff
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\cg-use-everywhere
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-StableDiffusion3-API
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI_IPAdapter_plus
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Custom-Scripts-main
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Frame-Interpolation
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\comfyui-workspace-manager
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\efficiency-nodes-comfyui
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI_essentials
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved
2024-10-25 11:13:15,201 - root - INFO -    0.0 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\OneButtonPrompt
2024-10-25 11:13:15,201 - root - INFO -    0.1 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-VideoHelperSuite
2024-10-25 11:13:15,201 - root - INFO -    0.1 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-KJNodes
2024-10-25 11:13:15,201 - root - INFO -    0.2 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI_FizzNodes
2024-10-25 11:13:15,201 - root - INFO -    0.2 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Manager
2024-10-25 11:13:15,201 - root - INFO -    0.6 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\comfy_mtb
2024-10-25 11:13:15,201 - root - INFO -    5.6 seconds: F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI_Custom_Nodes_AlekPet-master
2024-10-25 11:13:15,201 - root - INFO - 
2024-10-25 11:13:15,210 - root - INFO - Starting server

2024-10-25 11:13:15,210 - root - INFO - To see the GUI go to: http://127.0.0.1:8188
2024-10-25 11:13:18,366 - root - INFO - got prompt
2024-10-25 11:13:20,491 - root - INFO - Using pytorch attention in VAE
2024-10-25 11:13:20,492 - root - INFO - Using pytorch attention in VAE
2024-10-25 11:13:24,394 - root - INFO - model weight dtype torch.float16, manual cast: None
2024-10-25 11:13:24,395 - root - INFO - model_type EPS
2024-10-25 11:13:24,592 - root - INFO - Using pytorch attention in VAE
2024-10-25 11:13:24,592 - root - INFO - Using pytorch attention in VAE
2024-10-25 11:13:24,908 - root - INFO - Requested to load SD1ClipModel
2024-10-25 11:13:24,908 - root - INFO - Loading 1 new model
2024-10-25 11:13:25,055 - root - INFO - loaded completely 0.0 235.84423828125 True
2024-10-25 11:13:27,161 - root - INFO - Requested to load CLIPVisionModelProjection
2024-10-25 11:13:27,161 - root - INFO - Loading 1 new model
2024-10-25 11:13:27,878 - root - INFO - loaded completely 0.0 3522.953369140625 True
2024-10-25 11:13:29,329 - root - INFO - Requested to load BaseModel
2024-10-25 11:13:29,329 - root - INFO - Requested to load ControlNet
2024-10-25 11:13:29,329 - root - INFO - Requested to load AnimateDiffModel
2024-10-25 11:13:29,330 - root - INFO - Loading 3 new models
2024-10-25 11:13:31,271 - root - INFO - loaded completely 0.0 1639.406135559082 True
2024-10-25 11:13:31,494 - root - INFO - loaded partially 1805.7649368286134 1805.76416015625 0
2024-10-25 11:13:31,611 - root - INFO - loaded completely 0.0 795.6268310546875 True
2024-10-25 11:13:31,735 - root - ERROR - !!! Exception during processing !!! 'NoneType' object has no attribute 'shape'
2024-10-25 11:13:31,738 - root - ERROR - Traceback (most recent call last):
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\execution.py", line 323, 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 "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\execution.py", line 198, 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 "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\execution.py", line 169, in _map_node_over_list
    process_inputs(input_dict, i)
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\execution.py", line 158, in process_inputs
    results.append(getattr(obj, func)(**inputs))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\nodes.py", line 1437, in sample
    return common_ksampler(model, seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, denoise=denoise)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\nodes.py", line 1404, in common_ksampler
    samples = comfy.sample.sample(model, noise, steps, cfg, sampler_name, scheduler, positive, negative, latent_image,
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 526, in motion_sample
    latents = orig_comfy_sample(model, noise, *args, **kwargs)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\adv_control\sampling.py", line 116, in acn_sample
    return orig_comfy_sample(model, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\adv_control\utils.py", line 117, in uncond_multiplier_check_cn_sample
    return orig_comfy_sample(model, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\sample.py", line 43, in sample
    samples = sampler.sample(noise, positive, negative, cfg=cfg, latent_image=latent_image, start_step=start_step, last_step=last_step, force_full_denoise=force_full_denoise, denoise_mask=noise_mask, sigmas=sigmas, callback=callback, disable_pbar=disable_pbar, seed=seed)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 832, in sample
    return sample(self.model, noise, positive, negative, cfg, self.device, sampler, sigmas, self.model_options, latent_image=latent_image, denoise_mask=denoise_mask, callback=callback, disable_pbar=disable_pbar, seed=seed)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 732, in sample
    return cfg_guider.sample(noise, latent_image, sampler, sigmas, denoise_mask, callback, disable_pbar, seed)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 719, in sample
    output = self.inner_sample(noise, latent_image, device, sampler, sigmas, denoise_mask, callback, disable_pbar, seed)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 698, in inner_sample
    samples = sampler.sample(self, sigmas, extra_args, callback, noise, latent_image, denoise_mask, disable_pbar)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 603, in sample
    samples = self.sampler_function(model_k, noise, sigmas, extra_args=extra_args, callback=k_callback, disable=disable_pbar, **self.extra_options)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\python_embeded\Lib\site-packages\torch\utils\_contextlib.py", line 115, in decorate_context
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\k_diffusion\sampling.py", line 305, in sample_lms
    denoised = model(x, sigmas[i] * s_in, **extra_args)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 299, in __call__
    out = self.inner_model(x, sigma, model_options=model_options, seed=seed)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 685, in __call__
    return self.predict_noise(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 688, in predict_noise
    return sampling_function(self.inner_model, x, timestep, self.conds.get("negative", None), self.conds.get("positive", None), self.cfg, model_options=model_options, seed=seed)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 635, in evolved_sampling_function
    cond_pred, uncond_pred = sliding_calc_conds_batch(model, [cond, uncond_], x, timestep, model_options)
                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 887, in sliding_calc_conds_batch
    sub_conds_out = calc_conds_batch_wrapper(model, sub_conds, sub_x, sub_timestep, model_options)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-AnimateDiff-Evolved\animatediff\sampling.py", line 993, in calc_conds_batch_wrapper
    return comfy.samplers.calc_cond_batch(model, conds, x_in, timestep, model_options)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\samplers.py", line 202, in calc_cond_batch
    c['control'] = control.get_control(input_x, timestep_, c, len(cond_or_uncond))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\adv_control\utils.py", line 762, in get_control_inject
    return self.get_control_advanced(x_noisy, t, cond, batched_number)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\adv_control\control.py", line 44, in get_control_advanced
    return self.sliding_get_control(x_noisy, t, cond, batched_number)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\custom_nodes\ComfyUI-Advanced-ControlNet\adv_control\control.py", line 102, in sliding_get_control
    control = self.control_model(x=x_noisy.to(dtype), hint=self.cond_hint, timesteps=timestep.to(dtype), context=context.to(dtype), **extra)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1532, in _wrapped_call_impl
    return self._call_impl(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1541, in _call_impl
    return forward_call(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "F:\Learning & Experiment\Stable Diffusion\ComfyUI_windows\ComfyUI\comfy\cldm\cldm.py", line 420, in forward
    assert y.shape[0] == x.shape[0]
           ^^^^^^^
AttributeError: 'NoneType' object has no attribute 'shape'

2024-10-25 11:13:31,739 - root - INFO - Prompt executed in 13.35 seconds

Attached Workflow

Please make sure that workflow does not contain any sensitive information such as API keys or passwords.

Workflow too large. Please manually upload the workflow from local file system.

Additional Context

(Please add any additional context or steps to reproduce the error here)



### Other

_No response_
LukeG89 commented 1 month ago

This error is due to a model mismatch. Check if you used the correct model types in your Controlnet and AnimateDiff loaders (if the Checkpoint is SD1.5, ControlNet and AnimateDiff models must be for SD1.5)

ltdrdata commented 1 month ago

The workflow you provided runs without any issues in my environment. I only reset the checkpoint and image. There's no problem since the original workflow's checkpoint is also SD1.5.

Check if your custom nodes and ComfyUI version are up to date. And check if the model files you are using in the workflow are not corrupted.