Closed bennyguo closed 1 year ago
Thanks Yuancheng for reporting! I will look into it soon
Hi there! I have the same issues !
Meanwhile, if you are working with pytorch < 1.11 you could try by editing the file nerfacc/cuda/csrc/include/helpers_cuda.h
Replace this line
#include <ATen/cuda/cub_definitions.cuh>
With this block
//#include <ATen/cuda/cub_definitions.cuh>
// cub support for UniqueByKey is added to cub 1.16 in:
// https://github.com/NVIDIA/cub/pull/405
#if CUB_VERSION >= 101600
#define CUB_SUPPORTS_UNIQUE_BY_KEY() true
#else
#define CUB_SUPPORTS_UNIQUE_BY_KEY() false
#endif
// cub support for scan by key is added to cub 1.15
// in https://github.com/NVIDIA/cub/pull/376
#if CUB_VERSION >= 101500
#define CUB_SUPPORTS_SCAN_BY_KEY() 1
#else
#define CUB_SUPPORTS_SCAN_BY_KEY() 0
#endif
// cub support for cub::FutureValue is added to cub 1.15 in:
// https://github.com/NVIDIA/cub/pull/305
#if CUB_VERSION >= 101500
#define CUB_SUPPORTS_FUTURE_VALUE() true
#else
#define CUB_SUPPORTS_FUTURE_VALUE() false
#endif
PS: Doing the above I was able to run nerfacc using python 3.8 with this pytorch setup
pip install torch==1.10.1+cu111 torchvision==0.11.2+cu111 torchaudio==0.10.1 -f https://download.pytorch.org/whl/torch_stable.html
fixed now!
Could not build nerfacc cuda kernels with older PyTorch versions (<= 1.10). Error message:
It seems that
ATen/cuda/cub_definitions.cuh
only exists after PyTorch 1.11. Maybe we should alter helper functions based on the PyTorch version.