Cant get tiny cuda installed (failed building wheel)
BeyerSEO opened this issue · comments
Hey I am trying to follow the installation guide to install nerfstudio on windows 11: https://docs.nerf.studio/quickstart/installation.html. Whenever I get to the installation of tinycuda I get this error:
(nerfstudio) C:\Users\beyer>pip install ninja git+https://github.com/NVlabs/tiny-cuda-nn/#subdirectory=bindings/torch
Collecting git+https://github.com/NVlabs/tiny-cuda-nn/#subdirectory=bindings/torch
Cloning https://github.com/NVlabs/tiny-cuda-nn/ to c:\users\beyer\appdata\local\temp\pip-req-build-vujdk1s_
Running command git clone --filter=blob:none --quiet https://github.com/NVlabs/tiny-cuda-nn/ 'C:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_'
Resolved https://github.com/NVlabs/tiny-cuda-nn/ to commit 4892659
Running command git submodule update --init --recursive -q
Preparing metadata (setup.py) ... done
Collecting ninja
Using cached ninja-1.11.1.1-py2.py3-none-win_amd64.whl.metadata (5.4 kB)
Using cached ninja-1.11.1.1-py2.py3-none-win_amd64.whl (312 kB)
Building wheels for collected packages: tinycudann
Building wheel for tinycudann (setup.py) ... error
error: subprocess-exited-with-error
× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> [51 lines of output]
C:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_\bindings/torch\setup.py:5: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
from pkg_resources import parse_version
Building PyTorch extension for tiny-cuda-nn version 1.7
Obtained compute capability 86 from PyTorch
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2022 NVIDIA Corporation
Built on Wed_Sep_21_10:41:10_Pacific_Daylight_Time_2022
Cuda compilation tools, release 11.8, V11.8.89
Build cuda_11.8.r11.8/compiler.31833905_0
Detected CUDA version 11.8
Targeting C++ standard 17
running bdist_wheel
C:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\utils\cpp_extension.py:502: UserWarning: Attempted to use ninja as the BuildExtension backend but we could not find ninja.. Falling back to using the slow distutils backend.
warnings.warn(msg.format('we could not find ninja.'))
running build
running build_py
creating build
creating build\lib.win-amd64-cpython-38
creating build\lib.win-amd64-cpython-38\tinycudann
copying tinycudann\modules.py -> build\lib.win-amd64-cpython-38\tinycudann
copying tinycudann_init_.py -> build\lib.win-amd64-cpython-38\tinycudann
running egg_info
creating tinycudann.egg-info
writing tinycudann.egg-info\PKG-INFO
writing dependency_links to tinycudann.egg-info\dependency_links.txt
writing top-level names to tinycudann.egg-info\top_level.txt
writing manifest file 'tinycudann.egg-info\SOURCES.txt'
reading manifest file 'tinycudann.egg-info\SOURCES.txt'
writing manifest file 'tinycudann.egg-info\SOURCES.txt'
copying tinycudann\bindings.cpp -> build\lib.win-amd64-cpython-38\tinycudann
running build_ext
building 'tinycudann_bindings.86_C' extension
creating build\dependencies
creating build\dependencies\fmt
creating build\dependencies\fmt\src
creating build\src
creating build\temp.win-amd64-cpython-38
creating build\temp.win-amd64-cpython-38\Release
creating build\temp.win-amd64-cpython-38\Release\tinycudann
"C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\bin\HostX86\x64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s/include -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies/cutlass/include -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies/cutlass/tools/util/include -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies/fmt/include -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include\torch\csrc\api\include -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include\TH -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include\THC "-IC:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.8\include" -IC:\Users\beyer\anaconda3\envs\nerfstudio\include -IC:\Users\beyer\anaconda3\envs\nerfstudio\Include "-IC:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\include" "-IC:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\ATLMFC\include" "-IC:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\VS\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\cppwinrt" /EHsc /Tp../../dependencies/fmt/src/format.cc /Fobuild\temp.win-amd64-cpython-38\Release../../dependencies/fmt/src/format.obj /MD /wd4819 /wd4251 /wd4244 /wd4267 /wd4275 /wd4018 /wd4190 /wd4624 /wd4067 /wd4068 /EHsc /std:c++17 -DTCNN_PARAMS_UNALIGNED -DTCNN_MIN_GPU_ARCH=86 -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=86_C -D_GLIBCXX_USE_CXX11_ABI=0
format.cc
"C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\bin\HostX86\x64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s/include -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies/cutlass/include -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies/cutlass/tools/util/include -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies/fmt/include -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include\torch\csrc\api\include -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include\TH -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include\THC "-IC:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.8\include" -IC:\Users\beyer\anaconda3\envs\nerfstudio\include -IC:\Users\beyer\anaconda3\envs\nerfstudio\Include "-IC:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\include" "-IC:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\ATLMFC\include" "-IC:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\VS\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\cppwinrt" /EHsc /Tp../../dependencies/fmt/src/os.cc /Fobuild\temp.win-amd64-cpython-38\Release../../dependencies/fmt/src/os.obj /MD /wd4819 /wd4251 /wd4244 /wd4267 /wd4275 /wd4018 /wd4190 /wd4624 /wd4067 /wd4068 /EHsc /std:c++17 -DTCNN_PARAMS_UNALIGNED -DTCNN_MIN_GPU_ARCH=86 -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=86_C -D_GLIBCXX_USE_CXX11_ABI=0
os.cc
"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.8\bin\nvcc" -c ../../src/common_host.cu -o build\temp.win-amd64-cpython-38\Release../../src/common_host.obj -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s/include -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies/cutlass/include -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies/cutlass/tools/util/include -IC:\Users\beyer\AppData\Local\Temp\pip-req-build-vujdk1s_/dependencies/fmt/include -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include\torch\csrc\api\include -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include\TH -IC:\Users\beyer\anaconda3\envs\nerfstudio\lib\site-packages\torch\include\THC "-IC:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.8\include" -IC:\Users\beyer\anaconda3\envs\nerfstudio\include -IC:\Users\beyer\anaconda3\envs\nerfstudio\Include "-IC:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\include" "-IC:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\ATLMFC\include" "-IC:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\VS\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\cppwinrt" -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 -D__CUDA_NO_HALF_OPERATORS__ -D__CUDA_NO_HALF_CONVERSIONS__ -D__CUDA_NO_BFLOAT16_CONVERSIONS__ -D__CUDA_NO_HALF2_OPERATORS__ --expt-relaxed-constexpr -std=c++17 --extended-lambda --expt-relaxed-constexpr -U__CUDA_NO_HALF_OPERATORS__ -U__CUDA_NO_HALF_CONVERSIONS__ -U__CUDA_NO_HALF2_OPERATORS__ -gencode=arch=compute_86,code=compute_86 -gencode=arch=compute_86,code=sm_86 -DTCNN_PARAMS_UNALIGNED -DTCNN_MIN_GPU_ARCH=86 -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=86_C -D_GLIBCXX_USE_CXX11_ABI=0 -std=c++17 --use-local-env
cl : Befehlszeile warning D9025 : "/D__CUDA_NO_HALF_OPERATORS_" wird durch "/U__CUDA_NO_HALF_OPERATORS__" \x81berschrieben
cl : Befehlszeile warning D9025 : "/D__CUDA_NO_HALF_CONVERSIONS__" wird durch "/U__CUDA_NO_HALF_CONVERSIONS__" \x81berschrieben
cl : Befehlszeile warning D9025 : "/D__CUDA_NO_HALF2_OPERATORS__" wird durch "/U__CUDA_NO_HALF2_OPERATORS__" \x81berschrieben
common_host.cu
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.8\include\crt/host_config.h(153): fatal error C1189: #error: -- unsupported Microsoft Visual Studio version! Only the versions between 2017 and 2022 (inclusive) are supported! The nvcc flag '-allow-unsupported-compiler' can be used to override this version check; however, using an unsupported host compiler may cause compilation failure or incorrect run time execution. Use at your own risk.
common_host.cu
error: command 'C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.8\bin\nvcc.exe' failed with exit code 2
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for tinycudann
Running setup.py clean for tinycudann
Failed to build tinycudann
ERROR: Could not build wheels for tinycudann, which is required to install pyproject.toml-based projects
Have you resolved it? I also encountered this problem
Have been facing this same issue. Has anybody solved it?
(nerfstudio) C:\Users\yakov>pip install ninja git+https://github.com/NVlabs/tiny-cuda-nn/#subdirectory=bindings/torch
Collecting git+https://github.com/NVlabs/tiny-cuda-nn/#subdirectory=bindings/torch
Cloning https://github.com/NVlabs/tiny-cuda-nn/ to c:\users\yakov\appdata\local\temp\pip-req-build-3q6itie5
Running command git clone --filter=blob:none --quiet https://github.com/NVlabs/tiny-cuda-nn/ 'C:\Users\yakov\AppData\Local\Temp\pip-req-build-3q6itie5'
error: RPC failed; curl 92 HTTP/2 stream 3 was not closed cleanly: CANCEL (err 8)
error: 6367 bytes of body are still expected
fetch-pack: unexpected disconnect while reading sideband packet
fatal: early EOF
fatal: fetch-pack: invalid index-pack output
fatal: could not fetch 63576553f0c4a64f6d564498a0f32dbbecb7b0ea from promisor remote
warning: Clone succeeded, but checkout failed.
You can inspect what was checked out with 'git status'
and retry with 'git restore --source=HEAD :/'
error: subprocess-exited-with-error
× git clone --filter=blob:none --quiet https://github.com/NVlabs/tiny-cuda-nn/ 'C:\Users\yakov\AppData\Local\Temp\pip-req-build-3q6itie5' did not run successfully.
│ exit code: 128
╰─> See above for output.
i have the same