traveller59 / second.pytorch

SECOND for KITTI/NuScenes object detection
MIT License
1.72k stars 722 forks source link

sparse_rpn #29

Open Benzlxs opened 5 years ago

Benzlxs commented 5 years ago

https://github.com/traveller59/second.pytorch/blob/fb28d7b606dc0dcfbe73b78df285b9d8cd3df34a/second/pytorch/models/voxelnet.py#L685

Hi, many thanks for sharing meaningful work.

The self.sparse_rpn, 673 lines in voxelnet.py, is still not implemented. Do you have the plan to finish this function, self.sparse_rpn, in the near future?

Regards,

traveller59 commented 5 years ago

I have implemented the sparse rpn but the running speed is greatly decreased. for 2D RPN you can try SBNet, the SparseConvNet is slow when the sparsity grows ( the normal sparse conv increase sparsity rapidly).

roma-goodok commented 5 years ago

SparseConvNet is slow when the sparsity grows ( the normal sparse conv increase sparsity rapidly).

Just to be sure, sparsity (share of empty voxels) or density (share of non empty voxels) ? May be I am wrong, but my undesrtanding that SparseConvNet is slow when sparsity becomes low (as it mentioned in the SBNet papers) and normal sparse conv without submanifold/blocks decrease sparsity rapidly.

traveller59 commented 5 years ago

@roma-goodok you are right, that's my mistake... One of the major reason why SparseConvNet conv performance is rule generation (used for gather-gemm-scatter algorithm of sparse conv) is very slow (run on CPU). less sparsity of data, more rule generation time.