cv2.error: OpenCV(4.9.0) D:\a\opencv-python\opencv-python\opencv\modules\imgproc\src\resize.cpp:3789: error: (-215:Assertion failed) !dsize.empty() in function 'cv::hal::resize'
Cokeheart opened this issue · 16 comments
!!! Exception during processing !!!
Traceback (most recent call last):
File "D:\Blender_ComfyUI\ComfyUI\execution.py", line 151, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Blender_ComfyUI\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:\Blender_ComfyUI\ComfyUI\execution.py", line 74, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Blender_ComfyUI\ComfyUI\custom_nodes\clipseg.py", line 154, in segment_image
heatmap_resized = resize_image(heatmap, dimensions)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Blender_ComfyUI\ComfyUI\custom_nodes\clipseg.py", line 44, in resize_image
return cv2.resize(image, dimensions, interpolation=cv2.INTER_LINEAR)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
i got this error too...
I'm recieving this error too
same here, So is it due to some node upgrades?
me too!
重装插件,然后和3699错误一样的步骤改代码,再试试
重装插件,然后和3699错误一样的步骤改代码,再试试
怎么改
Try installing transformers up to 4.36.0 if you can!or lower。使用较低版本的 transformers可以解决这个问题。
https://blog.csdn.net/JuMengXiaoKeTang/article/details/137383951
Thank you, this resolved it for me! :)
https://blog.csdn.net/JuMengXiaoKeTang/article/details/137383951
I tried this solution but it doesn't work. Has anyone found another solution?
Try installing transformers up to 4.36.0 if you can! or lower. Using lower versions of transformers can solve this problem.
How can I do this?
https://blog.csdn.net/JuMengXiaoKeTang/article/details/137383951
I tried this solution but it doesn't work. Has anyone found another solution?
Try installing transformers up to 4.36.0 if you can! or lower. Using lower versions of transformers can solve this problem.
How can I do this?
The only change I needed to make was to the clipseg.py file. Just make that change and it should work.
低级的错误,作者怎么 能用绝对路径?
OpenCV(4.9.0) D:\a\opencv-python\opencv-python\opencv\modules\imgproc\src\resize.cpp:3789: error: (-215:Assertion failed) !dsize.empty() in function 'cv::hal::resize'
!!! Exception during processing!!! OpenCV(4.8.0) D:\a\opencv-python\opencv-python\opencv\modules\imgproc\src\resize.cpp:3699: error: (-215:Assertion failed) !dsize.empty() in function 'cv::hal::resize'
Traceback (most recent call last):
File "E:\ComfyUI_WIN\ComfyUI\execution.py", line 151, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_WIN\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 "E:\ComfyUI_WIN\ComfyUI\execution.py", line 74, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_WIN\ComfyUI\custom_nodes\clipseg.py", line 154, in segment_image
heatmap_resized = resize_image(heatmap, dimensions)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\ComfyUI_WIN\ComfyUI\custom_nodes\clipseg.py", line 44, in resize_image
return cv2.resize(image, dimensions, interpolation=cv2.INTER_LINEAR)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
cv2.error: OpenCV(4.8.0) D:\a\opencv-python\opencv-python\opencv\modules\imgproc\src\resize.cpp:3699: error: (-215:Assertion failed) !dsize.empty() in function 'cv::hal::resize'
how to fix??
https://blog.csdn.net/JuMengXiaoKeTang/article/details/137383951
thanks, it worked!!!
https://blog.csdn.net/JuMengXiaoKeTang/article/details/137383951
new problem after changed
Error occurred when executing Bounded Image Crop with Mask:
index is out of bounds for dimension with size 0
Looks like this PR fixes it: https://github.com/biegert/ComfyUI-CLIPSeg/pull/18/files