toyxyz / ComfyUI_toyxyz_test_nodes

Custom node and script for sending webcam to ComfyUI
GNU General Public License v3.0
521 stars 36 forks source link

import failed after update #51

Open lzhfdwu007 opened 3 weeks ago

lzhfdwu007 commented 3 weeks ago

Error message is as follows

Traceback (most recent call last): File "D:\ComfyUI\ComfyUI\nodes.py", line 2012, in load_custom_node module_spec.loader.exec_module(module) File "", line 940, in exec_module File "", line 241, in _call_with_frames_removed File "D:\ComfyUI\ComfyUI\custom_nodes\ComfyUI_toyxyz_test_nodes__init__.py", line 12, in imported_module = importlib.import_module(".{}".format(module_name), name) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "importlib__init__.py", line 126, in import_module File "", line 1204, in _gcd_import File "", line 1176, in _find_and_load File "", line 1147, in _find_and_load_unlocked File "", line 690, in _load_unlocked File "", line 940, in exec_module File "", line 241, in _call_with_frames_removed File "D:\ComfyUI\ComfyUI\custom_nodes\ComfyUI_toyxyz_test_nodes\toyxyz_test_nodes.py", line 13, in from cv2.ximgproc import guidedFilter ImportError: cannot import name 'guidedFilter' from 'cv2.ximgproc' (unknown location)

Cannot import D:\ComfyUI\ComfyUI\custom_nodes\ComfyUI_toyxyz_test_nodes module for custom nodes: cannot import name 'guidedFilter' from 'cv2.ximgproc' (unknown location)

toyxyz commented 3 weeks ago

Seems like OpenCV problem. If you are using the portable version, go to the path where 'Python_embeded' is located on the cmd and then run:

python_embeded/python.exe -s -m pip install opencv-contrib-python