pointops update
Opened this issue · 1 comments
Hi,
To support pointops installation for the latest pytorch version (>=1.11). You can do the following updating:
(1)
Replace the following 3 lines
#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)
with the following 3 lines
#define CHECK_CUDA(x) AT_ASSERTM(x.type().is_cuda(), #x " must be a CUDA tensor")
#define CHECK_CONTIGUOUS(x) AT_ASSERTM(x.is_contiguous(), #x " must be contiguous")
#define CHECK_INPUT(x) CHECK_CUDA(x); CHECK_CONTIGUOUS(x)
(2)
Uncomment the following 2 lines
// #include <THC/THC.h>
// extern THCState *state;
(3)
Replace
cudaStream_t stream = THCState_getCurrentStream(state);
with
cudaStream_t stream = c10::cuda::getCurrentCUDAStream();
Thanks!
Thanks for your solution!