Gourieff / comfyui-reactor-node

Fast and Simple Face Swap Extension Node for ComfyUI
GNU General Public License v3.0
1.08k stars 114 forks source link

Error when queue prompt of reactor workflow on ComfyUI-ZLUDA #341

Open duybt1 opened 1 week ago

duybt1 commented 1 week ago

First, confirm

What happened?

I tried installing reactor node with ComfyUI-ZLUDA, the installation process was ok, however after creating reactor node and loading img, I performed queue prompt and the comfyui manager reported the following error:

Does anyone know what this error is and how to fix it?

Error occurred when executing ReActorFaceSwap:

[ONNXRuntimeError] : 6 : RUNTIME_EXCEPTION : Exception during initialization: C:\a_work\1\s\onnxruntime\core\providers\cuda\cuda_call.cc:123 onnxruntime::CudaCall C:\a_work\1\s\onnxruntime\core\providers\cuda\cuda_call.cc:116 onnxruntime::CudaCall CUDNN failure 4: CUDNN_STATUS_INTERNAL_ERROR ; GPU=0 ; hostname=ADMIN-PC ; file=C:\a_work\1\s\onnxruntime\core\providers\cuda\cuda_execution_provider.cc ; line=182 ; expr=cudnnSetStream(cudnnhandle, stream);

File "D:\ComfyUI-ZLUDA\execution.py", line 151, in recursive_execute output_data, output_ui = get_output_data(obj, input_data_all) File "D:\ComfyUI-ZLUDA\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:\ComfyUI-ZLUDA\execution.py", line 74, in map_node_over_list results.append(getattr(obj, func)(slice_dict(input_data_all, i))) File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\nodes.py", line 335, in execute script.process( File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\scripts\reactor_faceswap.py", line 91, in process result = swap_face( File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\scripts\reactor_swapper.py", line 230, in swap_face source_faces = analyze_faces(source_img) File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\scripts\reactor_swapper.py", line 147, in analyze_faces face_analyser = getAnalysisModel(det_size) File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\scripts\reactor_swapper.py", line 77, in getAnalysisModel ANALYSIS_MODEL = insightface.app.FaceAnalysis( File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\reactor_patcher.py", line 48, in patched_faceanalysis_init model = model_zoo.get_model(onnx_file, kwargs) File "D:\ComfyUI-ZLUDA\venv\lib\site-packages\insightface\model_zoo\model_zoo.py", line 96, in get_model model = router.get_model(providers=providers, provider_options=provider_options) File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\reactor_patcher.py", line 21, in patched_get_model session = PickableInferenceSession(self.onnx_file, kwargs) File "D:\ComfyUI-ZLUDA\venv\lib\site-packages\insightface\model_zoo\model_zoo.py", line 25, in init super().init(model_path, kwargs) File "D:\ComfyUI-ZLUDA\venv\lib\site-packages\onnxruntime\capi\onnxruntime_inference_collection.py", line 419, in init self._create_inference_session(providers, provider_options, disabled_optimizers) File "D:\ComfyUI-ZLUDA\venv\lib\site-packages\onnxruntime\capi\onnxruntime_inference_collection.py", line 483, in _create_inference_session sess.initialize_session(providers, provider_options, disabled_optimizers)

Steps to reproduce the problem

1 2

Sysinfo

Windows 10, Firefox, RX6600, I5 12400k

Relevant console log

[ReActor] 21:41:08 - STATUS - Working: source face index [0], target face index [0]
[ReActor] 21:41:08 - STATUS - Analyzing Source Image...
2024-06-23 21:41:08.9141174 [E:onnxruntime:, inference_session.cc:2045 onnxruntime::InferenceSession::Initialize::<lambda_d4e0caa0782683b2ee97e3859f73dc9c>::operator ()] Exception during initialization: C:\a\_work\1\s\onnxruntime\core\providers\cuda\cuda_call.cc:123 onnxruntime::CudaCall C:\a\_work\1\s\onnxruntime\core\providers\cuda\cuda_call.cc:116 onnxruntime::CudaCall CUDNN failure 4: CUDNN_STATUS_INTERNAL_ERROR ; GPU=0 ; hostname=ADMIN-PC ; file=C:\a\_work\1\s\onnxruntime\core\providers\cuda\cuda_execution_provider.cc ; line=182 ; expr=cudnnSetStream(cudnn_handle_, stream);

!!! Exception during processing!!! [ONNXRuntimeError] : 6 : RUNTIME_EXCEPTION : Exception during initialization: C:\a\_work\1\s\onnxruntime\core\providers\cuda\cuda_call.cc:123 onnxruntime::CudaCall C:\a\_work\1\s\onnxruntime\core\providers\cuda\cuda_call.cc:116 onnxruntime::CudaCall CUDNN failure 4: CUDNN_STATUS_INTERNAL_ERROR ; GPU=0 ; hostname=ADMIN-PC ; file=C:\a\_work\1\s\onnxruntime\core\providers\cuda\cuda_execution_provider.cc ; line=182 ; expr=cudnnSetStream(cudnn_handle_, stream);

Traceback (most recent call last):
  File "D:\ComfyUI-ZLUDA\execution.py", line 151, in recursive_execute
    output_data, output_ui = get_output_data(obj, input_data_all)
  File "D:\ComfyUI-ZLUDA\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:\ComfyUI-ZLUDA\execution.py", line 74, in map_node_over_list
    results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
  File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\nodes.py", line 335, in execute
    script.process(
  File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\scripts\reactor_faceswap.py", line 91, in process
    result = swap_face(
  File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\scripts\reactor_swapper.py", line 230, in swap_face
    source_faces = analyze_faces(source_img)
  File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\scripts\reactor_swapper.py", line 147, in analyze_faces
    face_analyser = getAnalysisModel(det_size)
  File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\scripts\reactor_swapper.py", line 77, in getAnalysisModel
    ANALYSIS_MODEL = insightface.app.FaceAnalysis(
  File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\reactor_patcher.py", line 48, in patched_faceanalysis_init
    model = model_zoo.get_model(onnx_file, **kwargs)
  File "D:\ComfyUI-ZLUDA\venv\lib\site-packages\insightface\model_zoo\model_zoo.py", line 96, in get_model
    model = router.get_model(providers=providers, provider_options=provider_options)
  File "D:\ComfyUI-ZLUDA\custom_nodes\comfyui-reactor-node\reactor_patcher.py", line 21, in patched_get_model
    session = PickableInferenceSession(self.onnx_file, **kwargs)
  File "D:\ComfyUI-ZLUDA\venv\lib\site-packages\insightface\model_zoo\model_zoo.py", line 25, in __init__
    super().__init__(model_path, **kwargs)
  File "D:\ComfyUI-ZLUDA\venv\lib\site-packages\onnxruntime\capi\onnxruntime_inference_collection.py", line 419, in __init__
    self._create_inference_session(providers, provider_options, disabled_optimizers)
  File "D:\ComfyUI-ZLUDA\venv\lib\site-packages\onnxruntime\capi\onnxruntime_inference_collection.py", line 483, in _create_inference_session
    sess.initialize_session(providers, provider_options, disabled_optimizers)
onnxruntime.capi.onnxruntime_pybind11_state.RuntimeException: [ONNXRuntimeError] : 6 : RUNTIME_EXCEPTION : Exception during initialization: C:\a\_work\1\s\onnxruntime\core\providers\cuda\cuda_call.cc:123 onnxruntime::CudaCall C:\a\_work\1\s\onnxruntime\core\providers\cuda\cuda_call.cc:116 onnxruntime::CudaCall CUDNN failure 4: CUDNN_STATUS_INTERNAL_ERROR ; GPU=0 ; hostname=ADMIN-PC ; file=C:\a\_work\1\s\onnxruntime\core\providers\cuda\cuda_execution_provider.cc ; line=182 ; expr=cudnnSetStream(cudnn_handle_, stream);

Prompt executed in 0.46 seconds

Additional information

No response

Gourieff commented 1 week ago

As far as I know ORT-GPU doesn't work with ZLUDA from the box