tiny-cuda-nn icon indicating copy to clipboard operation
tiny-cuda-nn copied to clipboard

subprocess-exited-with-error

Open mohit-choithwani opened this issue 1 year ago • 0 comments

I am getting the following error while installing this on Ubuntu. Can anyone help me to fix this issue?

Collecting git+https://github.com/NVlabs/tiny-cuda-nn/#subdirectory=bindings/torch
Cloning https://github.com/NVlabs/tiny-cuda-nn/ to /tmp/pip-req-build-6lu3vmud
Running command git clone --filter=blob:none --quiet https://github.com/NVlabs/tiny-cuda-nn/ /tmp/pip-req-build-6lu3vmud
Resolved https://github.com/NVlabs/tiny-cuda-nn/ to commit c12645dfbac707ccd82907a209edff9b258f1e3d
Running command git submodule update --init --recursive -q
Preparing metadata (setup.py) ... done
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
╰─> [79 lines of output]
/tmp/pip-req-build-6lu3vmud/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 75 from PyTorch
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2021 NVIDIA Corporation
Built on Mon_Sep_13_19:13:29_PDT_2021
Cuda compilation tools, release 11.5, V11.5.50
Build cuda_11.5.r11.5/compiler.30411180_0
Detected CUDA version 11.5
Targeting C++ standard 17
running bdist_wheel
/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/utils/cpp_extension.py:411: 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.linux-x86_64-cpython-38
creating build/lib.linux-x86_64-cpython-38/tinycudann
copying tinycudann/init.py -> build/lib.linux-x86_64-cpython-38/tinycudann
copying tinycudann/modules.py -> build/lib.linux-x86_64-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.linux-x86_64-cpython-38/tinycudann running build_ext /home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/utils/cpp_extension.py:813: UserWarning: The detected CUDA version (11.5) has a minor version mismatch with the version that was used to compile PyTorch (11.3). Most likely this shouldn't be a problem. warnings.warn(CUDA_MISMATCH_WARN.format(cuda_str_version, torch.version.cuda)) /home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/utils/cpp_extension.py:820: UserWarning: There are no g++ version bounds defined for CUDA version 11.5 warnings.warn(f'There are no {compiler_name} version bounds defined for CUDA version {cuda_str_version}') building 'tinycudann_bindings.75_C' extension creating dependencies creating dependencies/fmt creating dependencies/fmt/src creating src creating build/temp.linux-x86_64-cpython-38 creating build/temp.linux-x86_64-cpython-38/tinycudann gcc -pthread -B /home/ew38upaq/anaconda3/envs/new_sdfstudio/compiler_compat -Wno-unused-result -Wsign-compare -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /home/ew38upaq/anaconda3/envs/new_sdfstudio/include -fPIC -O2 -isystem /home/ew38upaq/anaconda3/envs/new_sdfstudio/include -fPIC -I/tmp/pip-req-build-6lu3vmud/include -I/tmp/pip-req-build-6lu3vmud/dependencies -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/include -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/tools/util/include -I/tmp/pip-req-build-6lu3vmud/dependencies/fmt/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/torch/csrc/api/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/TH -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/THC -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include/python3.8 -c ../../dependencies/fmt/src/format.cc -o build/temp.linux-x86_64-cpython-38/../../dependencies/fmt/src/format.o -std=c++17 -DTCNN_PARAMS_UNALIGNED -DTCNN_MIN_GPU_ARCH=75 -DTORCH_API_INCLUDE_EXTENSION_H -DPYBIND11_COMPILER_TYPE="gcc" -DPYBIND11_STDLIB="libstdcpp" -DPYBIND11_BUILD_ABI="cxxabi1011" -DTORCH_EXTENSION_NAME=75_C -D_GLIBCXX_USE_CXX11_ABI=0 gcc -pthread -B /home/ew38upaq/anaconda3/envs/new_sdfstudio/compiler_compat -Wno-unused-result -Wsign-compare -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /home/ew38upaq/anaconda3/envs/new_sdfstudio/include -fPIC -O2 -isystem /home/ew38upaq/anaconda3/envs/new_sdfstudio/include -fPIC -I/tmp/pip-req-build-6lu3vmud/include -I/tmp/pip-req-build-6lu3vmud/dependencies -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/include -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/tools/util/include -I/tmp/pip-req-build-6lu3vmud/dependencies/fmt/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/torch/csrc/api/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/TH -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/THC -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include/python3.8 -c ../../dependencies/fmt/src/os.cc -o build/temp.linux-x86_64-cpython-38/../../dependencies/fmt/src/os.o -std=c++17 -DTCNN_PARAMS_UNALIGNED -DTCNN_MIN_GPU_ARCH=75 -DTORCH_API_INCLUDE_EXTENSION_H -DPYBIND11_COMPILER_TYPE="gcc" -DPYBIND11_STDLIB="libstdcpp" -DPYBIND11_BUILD_ABI="cxxabi1011" -DTORCH_EXTENSION_NAME=75_C -D_GLIBCXX_USE_CXX11_ABI=0 /home/ew38upaq/anaconda3/envs/new_sdfstudio/bin/nvcc -I/tmp/pip-req-build-6lu3vmud/include -I/tmp/pip-req-build-6lu3vmud/dependencies -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/include -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/tools/util/include -I/tmp/pip-req-build-6lu3vmud/dependencies/fmt/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/torch/csrc/api/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/TH -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/THC -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include/python3.8 -c ../../src/common_host.cu -o build/temp.linux-x86_64-cpython-38/../../src/common_host.o -D__CUDA_NO_HALF_OPERATORS -D__CUDA_NO_HALF_CONVERSIONS -D__CUDA_NO_BFLOAT16_CONVERSIONS -D__CUDA_NO_HALF2_OPERATORS --expt-relaxed-constexpr --compiler-options '-fPIC' -std=c++17 --extended-lambda --expt-relaxed-constexpr -U__CUDA_NO_HALF_OPERATORS_ -U__CUDA_NO_HALF_CONVERSIONS__ -U__CUDA_NO_HALF2_OPERATORS__ -Xcompiler=-Wno-float-conversion -Xcompiler=-fno-strict-aliasing -gencode=arch=compute_75,code=compute_75 -gencode=arch=compute_75,code=sm_75 -DTCNN_PARAMS_UNALIGNED -DTCNN_MIN_GPU_ARCH=75 -DTORCH_API_INCLUDE_EXTENSION_H -DPYBIND11_COMPILER_TYPE="_gcc" -DPYBIND11_STDLIB="_libstdcpp" -DPYBIND11_BUILD_ABI="_cxxabi1011" -DTORCH_EXTENSION_NAME=_75_C -D_GLIBCXX_USE_CXX11_ABI=0 /usr/include/stdio.h(189): error: attribute "malloc" does not take arguments

  /usr/include/stdio.h(201): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(223): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(260): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(285): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(294): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(303): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(309): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(315): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(830): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdlib.h(566): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdlib.h(570): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdlib.h(799): error: attribute "__malloc__" does not take arguments
  
  /usr/include/wchar.h(155): error: attribute "__malloc__" does not take arguments
  
  /usr/include/wchar.h(582): error: attribute "__malloc__" does not take arguments
  
  /tmp/pip-req-build-6lu3vmud/dependencies/fmt/include/fmt/core.h(288): warning #1675-D: unrecognized GCC pragma
  
  15 errors detected in the compilation of "../../src/common_host.cu".
  error: command '/home/ew38upaq/anaconda3/envs/new_sdfstudio/bin/nvcc' failed with exit code 1
  [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 Installing collected packages: tinycudann Running setup.py install for tinycudann ... error error: subprocess-exited-with-error

× Running setup.py install for tinycudann did not run successfully. │ exit code: 1 ╰─> [81 lines of output] /tmp/pip-req-build-6lu3vmud/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 75 from PyTorch nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2021 NVIDIA Corporation Built on Mon_Sep_13_19:13:29_PDT_2021 Cuda compilation tools, release 11.5, V11.5.50 Build cuda_11.5.r11.5/compiler.30411180_0 Detected CUDA version 11.5 Targeting C++ standard 17 running install /home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/setuptools/_distutils/cmd.py:66: SetuptoolsDeprecationWarning: setup.py install is deprecated. !!

          ********************************************************************************
          Please avoid running ``setup.py`` directly.
          Instead, use pypa/build, pypa/installer or other
          standards-based tools.
  
          See https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html for details.
          ********************************************************************************
  
  !!
    self.initialize_options()
  running build
  running build_py
  copying tinycudann/__init__.py -> build/lib.linux-x86_64-cpython-38/tinycudann
  copying tinycudann/modules.py -> build/lib.linux-x86_64-cpython-38/tinycudann
  running 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
  /home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/utils/cpp_extension.py:411: 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.'))
  reading manifest file 'tinycudann.egg-info/SOURCES.txt'
  writing manifest file 'tinycudann.egg-info/SOURCES.txt'
  copying tinycudann/bindings.cpp -> build/lib.linux-x86_64-cpython-38/tinycudann
  running build_ext
  /home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/utils/cpp_extension.py:813: UserWarning: The detected CUDA version (11.5) has a minor version mismatch with the version that was used to compile PyTorch (11.3). Most likely this shouldn't be a problem.
    warnings.warn(CUDA_MISMATCH_WARN.format(cuda_str_version, torch.version.cuda))
  /home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/utils/cpp_extension.py:820: UserWarning: There are no g++ version bounds defined for CUDA version 11.5
    warnings.warn(f'There are no {compiler_name} version bounds defined for CUDA version {cuda_str_version}')
  building 'tinycudann_bindings._75_C' extension
  gcc -pthread -B /home/ew38upaq/anaconda3/envs/new_sdfstudio/compiler_compat -Wno-unused-result -Wsign-compare -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /home/ew38upaq/anaconda3/envs/new_sdfstudio/include -fPIC -O2 -isystem /home/ew38upaq/anaconda3/envs/new_sdfstudio/include -fPIC -I/tmp/pip-req-build-6lu3vmud/include -I/tmp/pip-req-build-6lu3vmud/dependencies -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/include -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/tools/util/include -I/tmp/pip-req-build-6lu3vmud/dependencies/fmt/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/torch/csrc/api/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/TH -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/THC -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include/python3.8 -c ../../dependencies/fmt/src/format.cc -o build/temp.linux-x86_64-cpython-38/../../dependencies/fmt/src/format.o -std=c++17 -DTCNN_PARAMS_UNALIGNED -DTCNN_MIN_GPU_ARCH=75 -DTORCH_API_INCLUDE_EXTENSION_H -DPYBIND11_COMPILER_TYPE=\"_gcc\" -DPYBIND11_STDLIB=\"_libstdcpp\" -DPYBIND11_BUILD_ABI=\"_cxxabi1011\" -DTORCH_EXTENSION_NAME=_75_C -D_GLIBCXX_USE_CXX11_ABI=0
  gcc -pthread -B /home/ew38upaq/anaconda3/envs/new_sdfstudio/compiler_compat -Wno-unused-result -Wsign-compare -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /home/ew38upaq/anaconda3/envs/new_sdfstudio/include -fPIC -O2 -isystem /home/ew38upaq/anaconda3/envs/new_sdfstudio/include -fPIC -I/tmp/pip-req-build-6lu3vmud/include -I/tmp/pip-req-build-6lu3vmud/dependencies -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/include -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/tools/util/include -I/tmp/pip-req-build-6lu3vmud/dependencies/fmt/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/torch/csrc/api/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/TH -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/THC -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include/python3.8 -c ../../dependencies/fmt/src/os.cc -o build/temp.linux-x86_64-cpython-38/../../dependencies/fmt/src/os.o -std=c++17 -DTCNN_PARAMS_UNALIGNED -DTCNN_MIN_GPU_ARCH=75 -DTORCH_API_INCLUDE_EXTENSION_H -DPYBIND11_COMPILER_TYPE=\"_gcc\" -DPYBIND11_STDLIB=\"_libstdcpp\" -DPYBIND11_BUILD_ABI=\"_cxxabi1011\" -DTORCH_EXTENSION_NAME=_75_C -D_GLIBCXX_USE_CXX11_ABI=0
  /home/ew38upaq/anaconda3/envs/new_sdfstudio/bin/nvcc -I/tmp/pip-req-build-6lu3vmud/include -I/tmp/pip-req-build-6lu3vmud/dependencies -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/include -I/tmp/pip-req-build-6lu3vmud/dependencies/cutlass/tools/util/include -I/tmp/pip-req-build-6lu3vmud/dependencies/fmt/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/torch/csrc/api/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/TH -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/lib/python3.8/site-packages/torch/include/THC -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include -I/home/ew38upaq/anaconda3/envs/new_sdfstudio/include/python3.8 -c ../../src/common_host.cu -o build/temp.linux-x86_64-cpython-38/../../src/common_host.o -D__CUDA_NO_HALF_OPERATORS__ -D__CUDA_NO_HALF_CONVERSIONS__ -D__CUDA_NO_BFLOAT16_CONVERSIONS__ -D__CUDA_NO_HALF2_OPERATORS__ --expt-relaxed-constexpr --compiler-options '-fPIC' -std=c++17 --extended-lambda --expt-relaxed-constexpr -U__CUDA_NO_HALF_OPERATORS__ -U__CUDA_NO_HALF_CONVERSIONS__ -U__CUDA_NO_HALF2_OPERATORS__ -Xcompiler=-Wno-float-conversion -Xcompiler=-fno-strict-aliasing -gencode=arch=compute_75,code=compute_75 -gencode=arch=compute_75,code=sm_75 -DTCNN_PARAMS_UNALIGNED -DTCNN_MIN_GPU_ARCH=75 -DTORCH_API_INCLUDE_EXTENSION_H -DPYBIND11_COMPILER_TYPE=\"_gcc\" -DPYBIND11_STDLIB=\"_libstdcpp\" -DPYBIND11_BUILD_ABI=\"_cxxabi1011\" -DTORCH_EXTENSION_NAME=_75_C -D_GLIBCXX_USE_CXX11_ABI=0
  /usr/include/stdio.h(189): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(201): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(223): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(260): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(285): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(294): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(303): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(309): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(315): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdio.h(830): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdlib.h(566): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdlib.h(570): error: attribute "__malloc__" does not take arguments
  
  /usr/include/stdlib.h(799): error: attribute "__malloc__" does not take arguments
  
  /usr/include/wchar.h(155): error: attribute "__malloc__" does not take arguments
  
  /usr/include/wchar.h(582): error: attribute "__malloc__" does not take arguments
  
  /tmp/pip-req-build-6lu3vmud/dependencies/fmt/include/fmt/core.h(288): warning #1675-D: unrecognized GCC pragma
  
  15 errors detected in the compilation of "../../src/common_host.cu".
  error: command '/home/ew38upaq/anaconda3/envs/new_sdfstudio/bin/nvcc' failed with exit code 1
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. error: legacy-install-failure

× Encountered error while trying to install package. ╰─> tinycudann

note: This is an issue with the package mentioned above, not pip. hint: See above for output from the failure.

mohit-choithwani avatar Jan 12 '24 17:01 mohit-choithwani