CodeFormer icon indicating copy to clipboard operation
CodeFormer copied to clipboard

how to fix CUDNN_STATUS_EXECUTION_FAILED

Open ezhouyang opened this issue 2 years ago • 0 comments

Error cuDNN error: CUDNN_STATUS_EXECUTION_FAILED Failed inference for RealESRGAN: CUDA error: unknown error CUDA kernel errors might be asynchronously reported at some other API call, so the stacktrace below might be incorrect. For debugging consider passing CUDA_LAUNCH_BLOCKING=1. Compile with TORCH_USE_CUDA_DSA to enable device-side assertions.

Traceback (most recent call last): File "inference_codeformer.py", line 221, in bg_img = bg_upsampler.enhance(img, outscale=args.upscale)[0] File "D:\conda\envs\codeformer\lib\site-packages\torch\utils_contextlib.py", line 115, in decorate_context return func(*args, **kwargs) File "D:\project\CodeFormer\basicsr\utils\realesrgan_utils.py", line 243, in enhance output = (output_img * 255.0).round().astype(np.uint8) UnboundLocalError: local variable 'output_img' referenced before assignment

ezhouyang avatar Sep 09 '23 03:09 ezhouyang