FASTER CNNS WITH DIRECT SPARSE CONVOLUTIONS AND GUIDED PRUNING(1)

ICLR 2017的文章

题目:faster cnns with direct sparse convolutions and guided pruning ,直接稀疏卷积和指导剪枝  能让cnn变faster?直接稀疏卷积是个什么东西?指导剪枝应该是提出了一种剪枝的方式。

Introduction:

网络参数是变少了,inference speed却没有上去。为什么?主要是本来全连接层占所有参数就多;剪掉的全连接层的参数占的比例多,cnn层剪掉的占的比例少,那么inference speed自然上不去。可参考这篇博客:http://www.cnblogs.com/mengmengmiaomiao/p/7512230.html

Han的文章主要就是减小网络的大小(fc层连接去掉的多),但是计算量没有考虑

所以,如何提高速度,关键就在稀疏核和feature map相乘这一步。

所以,提出一个direct sparse convolution

 


为了实现sparse convolution,规划一个performance model。
 
 
在剪枝算法GSL的指导下,结合sparse convolution design和performance model可以让我们以co-design的方式剪CNN。
  

 

 

看看本文的效果:

卷积层的速度提高了!很了不起。

 

DIRECT SPARSE CONVOLUTION

 以往卷积计算都是input->im2col->im2col*weight矩阵(http://www.cnblogs.com/mengmengmiaomiao/p/7587448.html,看第四部分)。weight矩阵要么是csr表示,要么是dense matric。将input复制多次,计算强度会增加

direct convolution做法, In order to save bandwidth usage, we operate with a virtual dense matrix, Ivirtual, where its columns are generated on the fly by adjusting indices through which we access vec(I ).

其实direct convolution,如上图星号表示,增加了weight的长度。如果增加的星号用0填充,那么就要看看这多出来的10个相乘是不是比im2col把每个通道相应滑动窗口中的数据提出来转换为行用的时间更少了。实验中,他是跟dense convolution-----im2col*dense matric(weight)比。

 

 

ANALYTICAL PERFORMANCE MODELING

 The performance of sparse convolution depends highly on the sparsity level of the weight tensor.

 

posted on 2017-09-13 23:02  MissSimple  阅读(1021)  评论(0编辑  收藏  举报

导航