Comfy-Org / Comfy-Org/ComfyUI

ImageBlur node breaks at blur_radius above 6

Open
#3,011 5 comments 0 reactions 0 assignees View on GitHub
User Support
Dominant language
Python
Stars
133k
Forks
15.7k
Avg merge
1d 7h
Merged PRs (30d)
158

Description

Running it with no custom nodes.

Running a simple blur like this:
![blur](https://github.com/comfyanonymous/ComfyUI/assets/150616709/b6e2ead4-3864-4637-ab38-d6c3fbbcbd40)
Works up to a blur_radius of 6.
At 7, ComfyUI simply crashes without an error message.
At 8 and above, the execution is stuck at the node for minutes, then errors out:
```
ERROR:root:!!! Exception during processing !!!
ERROR:root:Traceback (most recent call last):
File "D:\ComfyUI_windows_portable_nightly_pytorch\ComfyUI\execution.py", line 152, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\ComfyUI_windows_portable_nightly_pytorch\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 "D:\ComfyUI_windows_portable_nightly_pytorch\ComfyUI\execution.py", line 75, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\ComfyUI_windows_portable_nightly_pytorch\ComfyUI\comfy_extras\nodes_post_processing.py", line 112, in blur
blurred = F.conv2d(padded_image, kernel, padding=kernel_size // 2, groups=channels)[:,:,blur_radius:-blur_radius, blur_radius:-blur_radius]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: vector too long
```
Afterwards, ImageBlur is broken with any value until a restart.
Strangely, the node works perfectly with the output from the "Convert Mask to Image" node.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.