huangtinglin / PyTorch-extension-Convolution

An example of C++ extension for PyTorch.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

#define CHECK_CUDA needs to be updated

SevenBlocks opened this issue · comments

The definitions at the top of conv_cuda.cpp should be changed to avoid errors:

#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)