Skip to content

dvlab-research/spconv-plus

Repository files navigation

spconv-plus

This project is based on the original spconv. We integrate several new sparse convolution types and operators that might be useful into this library.

1. Operators

Focals Conv

This is introduced in our CVPR 2022 (oral) paper. In this paper, we introduce a new type of sparse convolution that makes feature sparsity learnable with position-wise importance prediction.

The source code for this operator in this library is Focals Conv. The example for use this work is shown in its repo.

(left - submanifold sparse conv, mid - regular sparse conv, right - focal sparse conv)

Spatial Pruned Conv

This is introduced in our NeurIPS 2022 paper. In this paper, we propose two new convolution operators, spatial pruned submanifold sparse convolution (SPSS-Conv) and spatial pruned regular sparse convolution (SPRS-Conv), both of which are based on the idea of dynamically determining crucial areas for redundancy reduction.

The source codes for these two operators in this library are shown in SPSSConv3d and SPRSConv3d. The example for them can be found in this file and its repo.

Spatial-wise Group Conv

This is introduced in our Arxiv paper. In this paper, we introduce spatial-wise group (partition) convolution, that enables an efficient way to implement 3D large kernels.

The source code for this operators in this library is shown in SpatialGroupConv3d. The example for it is shown in this file.

Channel-wise Group Conv

This is the commonly-used group convolution. We implement this operator into this library. You can directly set "groups" in SparseConvolution.

Submanifold Sparse Max Pooling

We enable the submanifold version of sparse max pooling in this library. You can directly set "subm=True" when using SparseMaxPool3d. For example,

spconv.SparseMaxPool3d(3, 1, 1, subm=True, algo=ConvAlgo.Native, indice_key='max_pool')

2. Installation

This repo is based on cumm==0.2.8, pccm==0.3.4 This repo should be built from source. Following the readme file in the spconv library,

  • install build-essential, install CUDA
  • run export SPCONV_DISABLE_JIT="1"
  • run pip install pccm cumm wheel
  • run python setup.py bdist_wheel+pip install dists/xxx.whl

3. Citation

Please consider to cite our papers if this repo is helpful.

@inproceedings{focalsconv-chen,
  title={Focal Sparse Convolutional Networks for 3D Object Detection},
  author={Chen, Yukang and Li, Yanwei and Zhang, Xiangyu and Sun, Jian and Jia, Jiaya},
  booktitle={Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition},
  year={2022}
}
@inproceedings{liu2022spatial,
  title={Spatial Pruned Sparse Convolution for Efficient 3D Object Detection},
  author={Liu, Jianhui and Chen, Yukang and Ye, Xiaoqing and Tian, Zhuotao and Tan, Xiao and Qi, Xiaojuan},
  booktitle={Advances in Neural Information Processing Systems},
  year={2022}
}
@article{largekernel3d-chen,
  author    = {Chen, Yukang and Liu, Jianhui and Qi, Xiaojuan and Zhang, Xiangyu and Sun, Jian and Jia, Jiaya},
  title     = {Scaling up Kernels in 3D CNNs},
  journal   = {arxiv},
  year      = {2022},
}

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages