Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

installation problem #3

Open
ZheningHuang opened this issue Aug 17, 2022 · 6 comments
Open

installation problem #3

ZheningHuang opened this issue Aug 17, 2022 · 6 comments

Comments

@ZheningHuang
Copy link

Does this code support CUDA 11.X

I have tried to compile pointops with no success.

The following are the command prompts, would be really appreciated it if you could help.

running install
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
  warnings.warn(
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/setuptools/command/easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools.
  warnings.warn(
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/pkg_resources/__init__.py:123: PkgResourcesDeprecationWarning: R2020b is an invalid version and will not be supported in a future release
  warnings.warn(
running bdist_egg
running egg_info
writing pointops.egg-info/PKG-INFO
writing dependency_links to pointops.egg-info/dependency_links.txt
writing top-level names to pointops.egg-info/top_level.txt
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/utils/cpp_extension.py:381: 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 'pointops.egg-info/SOURCES.txt'
writing manifest file 'pointops.egg-info/SOURCES.txt'
installing library code to build/bdist.linux-x86_64/egg
running install_lib
running build_ext
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/utils/cpp_extension.py:782: UserWarning: The detected CUDA version (11.4) has a minor version mismatch with the version that was used to compile PyTorch (11.1). Most likely this shouldn't be a problem.
  warnings.warn(CUDA_MISMATCH_WARN.format(cuda_str_version, torch.version.cuda))
building 'pointops_cuda' extension
/usr/local/software/spack/spack-rhel8-20210927/opt/spack/linux-centos8-zen3/gcc-11.2.0/gcc-9.4.0-72sgv5z3s2sluudvrz5eefoxh6oalq6v/bin/gcc -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -fPIC -I/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include -I/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include -I/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/TH -I/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/THC -I/usr/local/software/spack/spack-rhel8-20210927/opt/spack/linux-centos8-zen2/gcc-9.4.0/cuda-11.4.0-3hnxhjt2jt4ruy75w2q4mnvkw7dty72l/include -I/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/include/python3.8 -c src/assofixp2c/assofixp2c_cuda.cpp -o build/temp.linux-x86_64-cpython-38/src/assofixp2c/assofixp2c_cuda.o -g -DTORCH_API_INCLUDE_EXTENSION_H -DPYBIND11_COMPILER_TYPE=\"_gcc\" -DPYBIND11_STDLIB=\"_libstdcpp\" -DPYBIND11_BUILD_ABI=\"_cxxabi1011\" -DTORCH_EXTENSION_NAME=pointops_cuda -D_GLIBCXX_USE_CXX11_ABI=0 -std=c++14
src/assofixp2c/assofixp2c_cuda.cpp: In function 'void assofixp2c_cuda(int, int, int, int, int, at::Tensor, at::Tensor, at::Tensor)':
src/assofixp2c/assofixp2c_cuda.cpp:10:39: warning: 'at::DeprecatedTypeProperties& at::Tensor::type() const' is deprecated: Tensor.type() is deprecated. Instead use Tensor.options(), which in many cases (e.g. in a constructor) is a drop-in replacement. If you were using data from type(), that is now available from Tensor itself, so instead of tensor.type().scalar_type(), use tensor.scalar_type() instead and instead of tensor.type().backend() use tensor.device(). [-Wdeprecated-declarations]
   10 | #define CHECK_CUDA(x) AT_CHECK(x.type().is_cuda(), #x, " must be a CUDAtensor ")
      |                                       ^
src/assofixp2c/assofixp2c_cuda.cpp:12:24: note: in expansion of macro 'CHECK_CUDA'
   12 | #define CHECK_INPUT(x) CHECK_CUDA(x);CHECK_CONTIGUOUS(x)
      |                        ^~~~~~~~~~
src/assofixp2c/assofixp2c_cuda.cpp:17:5: note: in expansion of macro 'CHECK_INPUT'
   17 |     CHECK_INPUT(idx_c_tensor);
      |     ^~~~~~~~~~~
In file included from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Tensor.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Context.h:4,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/ATen.h:9,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/types.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/input-archive.h:6,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/archive.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/tensor.h:3,
                 from src/assofixp2c/assofixp2c_cuda.cpp:1:
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/core/TensorBody.h:194:30: note: declared here
  194 |   DeprecatedTypeProperties & type() const {
      |                              ^~~~
src/assofixp2c/assofixp2c_cuda.cpp:10:23: error: 'AT_CHECK' was not declared in this scope; did you mean 'DCHECK'?
   10 | #define CHECK_CUDA(x) AT_CHECK(x.type().is_cuda(), #x, " must be a CUDAtensor ")
      |                       ^~~~~~~~
src/assofixp2c/assofixp2c_cuda.cpp:10:23: note: in definition of macro 'CHECK_CUDA'
   10 | #define CHECK_CUDA(x) AT_CHECK(x.type().is_cuda(), #x, " must be a CUDAtensor ")
      |                       ^~~~~~~~
src/assofixp2c/assofixp2c_cuda.cpp:17:5: note: in expansion of macro 'CHECK_INPUT'
   17 |     CHECK_INPUT(idx_c_tensor);
      |     ^~~~~~~~~~~
src/assofixp2c/assofixp2c_cuda.cpp:10:39: warning: 'at::DeprecatedTypeProperties& at::Tensor::type() const' is deprecated: Tensor.type() is deprecated. Instead use Tensor.options(), which in many cases (e.g. in a constructor) is a drop-in replacement. If you were using data from type(), that is now available from Tensor itself, so instead of tensor.type().scalar_type(), use tensor.scalar_type() instead and instead of tensor.type().backend() use tensor.device(). [-Wdeprecated-declarations]
   10 | #define CHECK_CUDA(x) AT_CHECK(x.type().is_cuda(), #x, " must be a CUDAtensor ")
      |                                       ^
src/assofixp2c/assofixp2c_cuda.cpp:12:24: note: in expansion of macro 'CHECK_CUDA'
   12 | #define CHECK_INPUT(x) CHECK_CUDA(x);CHECK_CONTIGUOUS(x)
      |                        ^~~~~~~~~~
src/assofixp2c/assofixp2c_cuda.cpp:18:5: note: in expansion of macro 'CHECK_INPUT'
   18 |     CHECK_INPUT(cid_tensor);
      |     ^~~~~~~~~~~
In file included from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Tensor.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Context.h:4,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/ATen.h:9,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/types.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/input-archive.h:6,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/archive.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/tensor.h:3,
                 from src/assofixp2c/assofixp2c_cuda.cpp:1:
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/core/TensorBody.h:194:30: note: declared here
  194 |   DeprecatedTypeProperties & type() const {
      |                              ^~~~
src/assofixp2c/assofixp2c_cuda.cpp:10:39: warning: 'at::DeprecatedTypeProperties& at::Tensor::type() const' is deprecated: Tensor.type() is deprecated. Instead use Tensor.options(), which in many cases (e.g. in a constructor) is a drop-in replacement. If you were using data from type(), that is now available from Tensor itself, so instead of tensor.type().scalar_type(), use tensor.scalar_type() instead and instead of tensor.type().backend() use tensor.device(). [-Wdeprecated-declarations]
   10 | #define CHECK_CUDA(x) AT_CHECK(x.type().is_cuda(), #x, " must be a CUDAtensor ")
      |                                       ^
src/assofixp2c/assofixp2c_cuda.cpp:12:24: note: in expansion of macro 'CHECK_CUDA'
   12 | #define CHECK_INPUT(x) CHECK_CUDA(x);CHECK_CONTIGUOUS(x)
      |                        ^~~~~~~~~~
src/assofixp2c/assofixp2c_cuda.cpp:19:5: note: in expansion of macro 'CHECK_INPUT'
   19 |     CHECK_INPUT(idx_tensor);
      |     ^~~~~~~~~~~
In file included from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Tensor.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Context.h:4,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/ATen.h:9,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/types.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/input-archive.h:6,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/archive.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/tensor.h:3,
                 from src/assofixp2c/assofixp2c_cuda.cpp:1:
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/core/TensorBody.h:194:30: note: declared here
  194 |   DeprecatedTypeProperties & type() const {
      |                              ^~~~
src/assofixp2c/assofixp2c_cuda.cpp:21:47: warning: 'T* at::Tensor::data() const [with T = int]' is deprecated: Tensor.data<T>() is deprecated. Please use Tensor.data_ptr<T>() instead. [-Wdeprecated-declarations]
   21 |     const int *idx_c = idx_c_tensor.data<int>();
      |                                               ^
In file included from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Tensor.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Context.h:4,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/ATen.h:9,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/types.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/input-archive.h:6,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/archive.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/tensor.h:3,
                 from src/assofixp2c/assofixp2c_cuda.cpp:1:
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/core/TensorBody.h:216:7: note: declared here
  216 |   T * data() const {
      |       ^~~~
src/assofixp2c/assofixp2c_cuda.cpp:22:43: warning: 'T* at::Tensor::data() const [with T = int]' is deprecated: Tensor.data<T>() is deprecated. Please use Tensor.data_ptr<T>() instead. [-Wdeprecated-declarations]
   22 |     const int *cid = cid_tensor.data<int>();
      |                                           ^
In file included from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Tensor.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Context.h:4,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/ATen.h:9,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/types.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/input-archive.h:6,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/archive.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/tensor.h:3,
                 from src/assofixp2c/assofixp2c_cuda.cpp:1:
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/core/TensorBody.h:216:7: note: declared here
  216 |   T * data() const {
      |       ^~~~
src/assofixp2c/assofixp2c_cuda.cpp:23:37: warning: 'T* at::Tensor::data() const [with T = int]' is deprecated: Tensor.data<T>() is deprecated. Please use Tensor.data_ptr<T>() instead. [-Wdeprecated-declarations]
   23 |     int *idx = idx_tensor.data<int>();
      |                                     ^
In file included from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Tensor.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/Context.h:4,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/ATen.h:9,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/types.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/input-archive.h:6,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/archive.h:3,
                 from /rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/torch/csrc/api/include/torch/serialize/tensor.h:3,
                 from src/assofixp2c/assofixp2c_cuda.cpp:1:
/rds/project/rds-LlrDsbHU5UM/zhening/zh_pytorch-env/lib/python3.8/site-packages/torch/include/ATen/core/TensorBody.h:216:7: note: declared here
  216 |   T * data() const {
      |       ^~~~
error: command '/usr/local/software/spack/spack-rhel8-20210927/opt/spack/linux-centos8-zen3/gcc-11.2.0/gcc-9.4.0-72sgv5z3s2sluudvrz5eefoxh6oalq6v/bin/gcc' failed with exit code 1

Best,
Zhening

@ZheningHuang
Copy link
Author

found the issue.

change all

#define CHECK_CUDA(x) AT_CHECK(x.type().is_cuda(), #x, " must be a CUDAtensor ")
#define CHECK_CONTIGUOUS(x) AT_CHECK(x.is_contiguous(), #x, " must be contiguous ")
#define CHECK_INPUT(x) CHECK_CUDA(x);CHECK_CONTIGUOUS(x)

to

#define CHECK_CUDA(x) TORCH_CHECK(x.is_cuda(), #x, " must be a CUDAtensor ")
#define CHECK_CONTIGUOUS(x) TORCH_CHECK(x.is_contiguous(), #x, " must be contiguous ")
#define CHECK_INPUT(x) CHECK_CUDA(x);CHECK_CONTIGUOUS(x)

change all

cudaStream_t stream = THCState_getCurrentStream(state);

to

cudaStream_t stream = at::cuda::getCurrentCUDAStream().stream();

@fpthink
Copy link
Owner

fpthink commented Sep 20, 2022

found the issue.

change all

#define CHECK_CUDA(x) AT_CHECK(x.type().is_cuda(), #x, " must be a CUDAtensor ")
#define CHECK_CONTIGUOUS(x) AT_CHECK(x.is_contiguous(), #x, " must be contiguous ")
#define CHECK_INPUT(x) CHECK_CUDA(x);CHECK_CONTIGUOUS(x)

to

#define CHECK_CUDA(x) TORCH_CHECK(x.is_cuda(), #x, " must be a CUDAtensor ")
#define CHECK_CONTIGUOUS(x) TORCH_CHECK(x.is_contiguous(), #x, " must be contiguous ")
#define CHECK_INPUT(x) CHECK_CUDA(x);CHECK_CONTIGUOUS(x)

change all

cudaStream_t stream = THCState_getCurrentStream(state);

to

cudaStream_t stream = at::cuda::getCurrentCUDAStream().stream();

Yes, it can be fixed in this way.

@ziwenjie
Copy link

ziwenjie commented Nov 23, 2022

Hi,@ZheningHuang
Do you finish the project? When I generate the .so file, which can not be used in the project. I used python3.8.8, cuda11.1, libboost1.73.

/workspace/SPNet-main/lib/ply_c/build# ld libply_c.so
ld: warning: cannot find entry symbol _start; not setting start address
ld pointops_cuda.cpython-38-x86_64-linux-gnu.so 
ld: warning: cannot find entry symbol _start; not setting start address
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyUnicode_InternFromString'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyInstanceMethod_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyDict_DelItemString'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `_Py_Dealloc'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_FromLong'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyModule_Create2'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_AsVoidPtr'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyExc_NotImplementedError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_FromSsize_t'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyObject_SetAttrString'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyType_IsSubtype'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyErr_Fetch'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyException_SetTraceback'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyExc_RuntimeError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyComplex_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyDict_Copy'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `_PyThreadState_UncheckedGet'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyEval_RestoreThread'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyDict_Size'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyUnicode_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyExc_MemoryError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyStaticMethod_New'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyUnicode_DecodeUTF8'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyErr_Print'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyUnicode_FromString'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyBytes_FromString'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyBaseObject_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyNumber_Check'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySlice_Type'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyList_Type'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyModule_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyThread_tss_create'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyObject_HasAttrString'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_GetBuffer'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyTuple_Pack'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyBytes_AsString'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyStructSequence_New'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyCapsule_GetContext'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `_PyObject_NextNotImplemented'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyList_SetItem'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `_PyType_Lookup'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyThreadState_Clear'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyMemoryView_FromMemory'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyErr_Clear'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyArg_ParseTupleAndKeywords'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyCallable_Check'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyNumber_Xor'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyCapsule_New'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyMem_Calloc'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_AsUnsignedLongLong'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyErr_ExceptionMatches'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyBuffer_Release'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyBytes_Size'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyNumber_Or'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_AsSsize_t'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySequence_Size'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyExc_TypeError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyComplex_RealAsDouble'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyNumber_Index'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_AsUnsignedLong'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyModule_New'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyEval_InitThreads'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyNumber_Long'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyType_Ready'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyGILState_Check'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyFloat_FromDouble'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_IsTrue'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyStructSequence_InitType'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySet_New'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyExc_DeprecationWarning'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyTuple_GetItem'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyBytes_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `_PyObject_GetDictPtr'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_Size'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_Malloc'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyUnicode_InternInPlace'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_AsLongLong'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyTuple_SetItem'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyBool_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyThread_tss_get'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyErr_Restore'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyErr_WarnEx'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyCapsule_SetName'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyErr_WarnExplicit'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_Type'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_Call'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyThread_tss_alloc'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySequence_List'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyFrozenSet_Type'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_FromSize_t'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyList_Size'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyTuple_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyCFunction_Type'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_GetIter'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyGILState_GetThisThreadState'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyDict_GetItem'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyBytes_AsStringAndSize'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyUnicode_AsEncodedString'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyMethod_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyTuple_New'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyUnicode_AsUTF8'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyImport_AddModule'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_CallFunctionObjArgs'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySlice_Unpack'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyExc_ImportError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyExc_AttributeError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySequence_Fast'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyErr_Occurred'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyThreadState_DeleteCurrent'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySequence_Tuple'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyWeakref_NewRef'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyComplex_ImagAsDouble'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyUnicode_AsUTF8String'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyEval_GetBuiltins'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyBytes_FromStringAndSize'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyExc_ValueError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyUnicode_FromFormat'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyNumber_And'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `_Py_FalseStruct'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyCapsule_GetName'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyDict_SetItemString'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyImport_ImportModule'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyExc_OverflowError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyComplex_AsCComplex'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_Type'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyDict_Type'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyExc_BufferError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyTuple_GetSlice'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySlice_AdjustIndices'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyGILState_Ensure'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyEval_AcquireThread'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyErr_SetString'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyObject_CallObject'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyThread_tss_set'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyList_GetItem'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyObject_IsInstance'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyList_Append'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyMem_Free'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyThreadState_Get'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyNumber_Invert'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyUnicode_FromStringAndSize'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyType_Type'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_FromDouble'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyArg_ParseTuple'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyThreadState_New'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyEval_GetFrame'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyObject_Repr'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyProperty_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyFrame_GetLineNumber'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyErr_NormalizeException'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyDict_Merge'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_FromUnsignedLongLong'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyObject_ClearWeakRefs'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyDict_Next'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_IsSubclass'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySet_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyCapsule_GetPointer'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `_Py_NoneStruct'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyInstanceMethod_New'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyDict_New'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyCapsule_SetPointer'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyExc_UserWarning'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyUnicode_Join'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_RichCompareBool'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyGILState_Release'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyErr_NewException'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySet_Add'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyModule_AddObject'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySequence_GetItem'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `_Py_NotImplementedStruct'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyObject_GetItem'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyFrame_FastToLocals'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyExc_RuntimeWarning'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyType_GenericNew'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyObject_SetItem'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyDict_Contains'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyExc_SystemError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyDict_Items'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `Py_BuildValue'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyCapsule_Type'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyComplex_FromDoubles'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyDict_GetItemString'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyNumber_Float'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyBool_FromLong'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyLong_AsLong'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyExc_Exception'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `_Py_TrueStruct'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyFloat_Type'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyExc_IndexError'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_AsFileDescriptor'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_AsLongLongAndOverflow'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_AsLongAndOverflow'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyComplex_FromCComplex'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyFloat_AsDouble'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_FromLongLong'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyIter_Next'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyEval_SaveThread'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyCapsule_SetContext'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyExc_StopIteration'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `Py_GetVersion'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PySequence_Check'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyType_GenericAlloc'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_GC_UnTrack'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_FromVoidPtr'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyCapsule_Import'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_CallMethod'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyObject_GetAttrString'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyList_New'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyModule_GetName'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyObject_Str'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyErr_Format'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyObject_SetAttr'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `_Py_EllipsisObject'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyCFunction_NewEx'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyLong_FromUnsignedLong'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyStaticMethod_Type'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyUnicode_AsUTF8AndSize'
ld: pointops_cuda.cpython-38-x86_64-linux-gnu.so: undefined reference to `PyTuple_Size'
ld: /opt/conda/lib/python3.8/site-packages/torch/lib/libtorch_python.so: undefined reference to `PyCode_Addr2Line'

Best
ziwenjie

@ardianumam
Copy link

ardianumam commented Mar 10, 2023

found the issue.

change all

#define CHECK_CUDA(x) AT_CHECK(x.type().is_cuda(), #x, " must be a CUDAtensor ")
#define CHECK_CONTIGUOUS(x) AT_CHECK(x.is_contiguous(), #x, " must be contiguous ")
#define CHECK_INPUT(x) CHECK_CUDA(x);CHECK_CONTIGUOUS(x)

to

#define CHECK_CUDA(x) TORCH_CHECK(x.is_cuda(), #x, " must be a CUDAtensor ")
#define CHECK_CONTIGUOUS(x) TORCH_CHECK(x.is_contiguous(), #x, " must be contiguous ")
#define CHECK_INPUT(x) CHECK_CUDA(x);CHECK_CONTIGUOUS(x)

change all

cudaStream_t stream = THCState_getCurrentStream(state);

to

cudaStream_t stream = at::cuda::getCurrentCUDAStream().stream();

I try this and still get the error below:

 File "/home/aumam/anaconda3/envs/pytorch1.4/lib/python3.6/distutils/ccompiler.py", line 574, in compile
    self._compile(obj, src, ext, cc_args, extra_postargs, pp_opts)
  File "/home/aumam/anaconda3/envs/pytorch1.4/lib/python3.6/site-packages/torch/utils/cpp_extension.py", line 288, in unix_wrap_compile
    "'-fPIC'"] + cflags + _get_cuda_arch_flags(cflags)
  File "/home/aumam/anaconda3/envs/pytorch1.4/lib/python3.6/site-packages/torch/utils/cpp_extension.py", line 1027, in _get_cuda_arch_flags
    raise ValueError("Unknown CUDA arch ({}) or GPU not supported".format(arch))
ValueError: Unknown CUDA arch (8.6) or GPU not supported

I use cuda 10.1, python 3.6.6 and pytorch 1.4.0 on Ubuntu 20.04. I already tested on 3090 and a5000 GPU and got same error messages.
Any suggestion?
Thanks!

@jing-zhao9
Copy link

@fpthink

Thank you for your excellent work!
I have tried to compile pointops with no success. When I run python setup.py install

(3.8) zhaojing@zhaojing-System-Product-Name:~/code/SPNet-main/libs/pointops$ python setup.py install
running install
/home/zhaojing/anaconda3/envs/3.8/lib/python3.8/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
/home/zhaojing/anaconda3/envs/3.8/lib/python3.8/site-packages/setuptools/command/easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
running bdist_egg
running egg_info
writing pointops.egg-info/PKG-INFO
writing dependency_links to pointops.egg-info/dependency_links.txt
writing top-level names to pointops.egg-info/top_level.txt
/home/zhaojing/anaconda3/envs/3.8/lib/python3.8/site-packages/torch/utils/cpp_extension.py:476: 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 'pointops.egg-info/SOURCES.txt'
writing manifest file 'pointops.egg-info/SOURCES.txt'
installing library code to build/bdist.linux-x86_64/egg
running install_lib
running build_ext
/home/zhaojing/anaconda3/envs/3.8/lib/python3.8/site-packages/torch/utils/cpp_extension.py:387: UserWarning: The detected CUDA version (11.8) has a minor version mismatch with the version that was used to compile PyTorch (11.7). Most likely this shouldn't be a problem.
warnings.warn(CUDA_MISMATCH_WARN.format(cuda_str_version, torch.version.cuda))
/home/zhaojing/anaconda3/envs/3.8/lib/python3.8/site-packages/torch/utils/cpp_extension.py:397: UserWarning: There are no g++ version bounds defined for CUDA version 11.8
warnings.warn(f'There are no {compiler_name} version bounds defined for CUDA version {cuda_str_version}')
building 'pointops_cuda' extension
creating build
creating build/temp.linux-x86_64-cpython-38
creating build/temp.linux-x86_64-cpython-38/src
creating build/temp.linux-x86_64-cpython-38/src/assofixp2c
creating build/temp.linux-x86_64-cpython-38/src/assofixp2c_weight
creating build/temp.linux-x86_64-cpython-38/src/assomatrix
creating build/temp.linux-x86_64-cpython-38/src/assomatrix_float
creating build/temp.linux-x86_64-cpython-38/src/assomatrix_label
creating build/temp.linux-x86_64-cpython-38/src/ballquery
creating build/temp.linux-x86_64-cpython-38/src/featuredistribute
creating build/temp.linux-x86_64-cpython-38/src/grouping
creating build/temp.linux-x86_64-cpython-38/src/grouping_int
creating build/temp.linux-x86_64-cpython-38/src/interpolation
creating build/temp.linux-x86_64-cpython-38/src/knnquery
creating build/temp.linux-x86_64-cpython-38/src/knnquerycluster
creating build/temp.linux-x86_64-cpython-38/src/knnqueryclustergt
creating build/temp.linux-x86_64-cpython-38/src/knnquerypoint
creating build/temp.linux-x86_64-cpython-38/src/labelstat
creating build/temp.linux-x86_64-cpython-38/src/sampling
gcc -pthread -B /home/zhaojing/anaconda3/envs/3.8/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/home/zhaojing/anaconda3/envs/3.8/lib/python3.8/site-packages/torch/include -I/home/zhaojing/anaconda3/envs/3.8/lib/python3.8/site-packages/torch/include/torch/csrc/api/include -I/home/zhaojing/anaconda3/envs/3.8/lib/python3.8/site-packages/torch/include/TH -I/home/zhaojing/anaconda3/envs/3.8/lib/python3.8/site-packages/torch/include/THC -I/usr/local/cuda/include -I/home/zhaojing/anaconda3/envs/3.8/include/python3.8 -c src/assofixp2c/assofixp2c_cuda.cpp -o build/temp.linux-x86_64-cpython-38/src/assofixp2c/assofixp2c_cuda.o -g -DTORCH_API_INCLUDE_EXTENSION_H -DPYBIND11_COMPILER_TYPE="_gcc" -DPYBIND11_STDLIB="_libstdcpp" -DPYBIND11_BUILD_ABI="_cxxabi1011" -DTORCH_EXTENSION_NAME=pointops_cuda -D_GLIBCXX_USE_CXX11_ABI=0 -std=c++14
cc1plus: warning: command-line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++
src/assofixp2c/assofixp2c_cuda.cpp:3:10: fatal error: THC/THC.h: 没有那个文件或目录
3 | #include <THC/THC.h>
| ^~~~~~~~~~~
compilation terminated.
error: command '/usr/bin/gcc' failed with exit code 1

@ZheningHuang
Copy link
Author

This package has been used by many other repositories as well and several changes are made to meet different versions of cuda, torch, etc.

If this doesn’t work, maybe looking into some latest repos such as https://github.com/guochengqian/PointNeXt and using their version would be helpful

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants