Closed jags111 closed 2 weeks ago
Hmm the error here seems to be nvcc fatal : Could not set up the environment for Microsoft Visual Studio...
.
Looking at this SO post, looks like this might have to do with the silly issue of having double quotes in any of your environment variables.
Could you please check and see if this is the case?
okay will check it on same and come back on it .. but the error is not nvcc but like here RuntimeError: Error building extension 'inplace_abn': [1/5] C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v12.3\bin\nvcc --generate-dependencies-with-compile --dependency-output inplace_abn_cuda.cuda.o.d -Xcudafe --diag_suppress=dll_interface_conflict_dllexport_assumed -Xcudafe --diag_suppress=dll_interface_conflict_none_assumed -Xcudafe --diag_suppress=field_without_dll_interface -Xcudafe --diag_suppress=base_class_has_different_dll_interface -Xcompiler /EHsc -Xcompiler /wd4068 -Xcompiler /wd4067 -Xcompiler /wd4624 -Xcompiler /wd4190 -Xcompiler /wd4018 -Xcompiler /wd4275 -Xcompiler /wd4267 -Xcompiler /wd4244 -Xcompiler /wd4251 -Xcompiler /wd4819 -Xcompiler /MD -DTORCH_EXTENSION_NAME=inplace_abn -DTORCH_API_INCLUDE_EXTENSION_H -ID:\AI\comfyUI\venv\Lib\site-packages\torch\include -ID:\AI\comfyUI\venv\Lib\site-packages\torch\include\torch\csrc\api\include -ID:\AI\comfyUI\venv\Lib\site-packages\torch\include\TH -ID:\AI\comfyUI\venv\Lib\site-packages\torch\include\THC "-IC:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v12.3\include" -IC:\Python311\Include -D_GLIBCXX_USE_CXX11_ABI=0 -DCUDA_NO_HALF_OPERATORS -DCUDA_NO_HALF_CONVERSIONS -DCUDA_NO_BFLOAT16_CONVERSIONS -DCUDA_NO_HALF2_OPERATORS --expt-relaxed-constexpr -gencode=arch=compute_86,code=compute_86 -gencode=arch=compute_86,code=sm_86 -std=c++17 --expt-extended-lambda -c D:\AI\ComfyUI\custom_nodes\human-parser-comfyui-node\schp\modules\src\inplace_abn_cuda.cu -o inplace_abn_cuda.cuda.o FAILED: inplace_abn_cuda.cuda.o
(IMPORT FAILED): ...\Portable\ComfyUI\ComfyUI\custom_nodes\human-parser-comfyui-node
if torch.cuda.is_available():
_backend = load(name="inplace_abn",
extra_cflags=["-O3"],
sources=[path.join(_src_path, f) for f in [
"inplace_abn.cpp",
"inplace_abn_cpu.cpp",
"inplace_abn_cuda.cu",
"inplace_abn_cuda_half.cu"
]],
extra_cuda_cflags=["--expt-extended-lambda"])
Visual Studio -> Command '['where', 'cl']' returned non-zero exit status 1.
@jags111 I got the nvcc
error from the logs you posted initially, I think that might be the root cause of the error, let me know!
@Aljnk see this issue: https://github.com/cozymantis/human-parser-comfyui-node/issues/6
I add cl.exe to the PATH - Thanks - it work.
I read your messages and think about nvcc - I can't find it. I'm trying to reinstall "NVIDIA GPU Computing Toolkit" - and found strange thing - it install some drivers then reboot system but nvcc not installed.
Solution - install only install ONLY missing libraries - nvcc work (tested in cmd)
Then I found a problem - error building extension 'inplace_abn'. Found - subprocess.CalledProcessError: Command '['ninja', '-v']' returned non-zero exit status 1. I add ninja.exe to my PATH (python_embeded\lib\site-packages\ninja\data\bin) - ninja work (tested in cmd) Not help - log.txt
(IMPORT FAILED): ...\Portable\ComfyUI\ComfyUI\custom_nodes\human-parser-comfyui-node
if torch.cuda.is_available(): _backend = load(name="inplace_abn", extra_cflags=["-O3"], sources=[path.join(_src_path, f) for f in [ "inplace_abn.cpp", "inplace_abn_cpu.cpp", "inplace_abn_cuda.cu", "inplace_abn_cuda_half.cu" ]], extra_cuda_cflags=["--expt-extended-lambda"])
Visual Studio -> Command '['where', 'cl']' returned non-zero exit status 1.
Can't you just remove the flag that is causing the issue?
@Aljnk from your logs, it looks like your issue is:
C1083: Cannot open include file: 'Python.h': No such file or directory
I think you need to add that header file to your Python's "include" folder - see https://stackoverflow.com/questions/62003710/include-python-h-no-such-file-or-directory-for-windows-10-fix
cl : Command line warning D9002 : ignoring unknown option '-O3' ninja: build stopped: subcommand failed.