"src/vscode:/vscode.git/clone" did not exist on "bc2d5632b753b79564ad1194af4ed3d659e6446e"
Unverified Commit 2800bf3a authored by Kai Chen's avatar Kai Chen Committed by GitHub
Browse files

Merge pull request #464 from yhcao6/dcn_cpp_extension

solve deformable_col2im: invalid argument by increasing channel
parents 058e27d6 7307e40b
......@@ -73,10 +73,11 @@ using namespace at;
i += blockDim.x * gridDim.x)
const int CUDA_NUM_THREADS = 1024;
const int kMaxGridNum = 65535;
inline int GET_BLOCKS(const int N)
{
return (N + CUDA_NUM_THREADS - 1) / CUDA_NUM_THREADS;
return std::min(kMaxGridNum, (N + CUDA_NUM_THREADS - 1) / CUDA_NUM_THREADS);
}
template <typename scalar_t>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment