lshiwjx / deform_conv3d_pytorch_op

An Operation for 3D Deformable Convolution in Pytorch 0.3

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

An Operation for 3D Deformable Convolution in Pytorch 0.3

Realize the 2D convolution, 2D and 3D deformable convolution in Pytorch 0.3.0. Did not check the 0.4.

Support the group convolution, dilate convolution, group deformable convolution, which split the channels of the input to several splits, each use the independent offset fields.

The official implementation of 2D deformable convolution

An implementation of 2D deformable convolution in Pytorch

Requirements

Pytorch = 0.3.0

Usage

Change the path in make.sh to your own path (The path of torch). Compile the op by:

bash make.sh

The .so is in xx_xx_op dir.

Use the test_function.py to test the results of the forward and the backward function.

Use the test_gradient to check the gradient of the backward. NOTE that only the double-precision version can pass the gradient check, i.e. deform2d_double. The double version is slower, so is just used for checking.

Use the test_model to check the whole model.

About

An Operation for 3D Deformable Convolution in Pytorch 0.3

License:Other


Languages

Language:Python 34.4%Language:Cuda 32.1%Language:C++ 28.3%Language:C 4.2%Language:Shell 0.8%Language:CMake 0.2%