arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2105.12686cs.LGcs.CV
收藏

动态概率剪枝:一种不同粒度的硬件约束剪枝通用框架

Dynamic Probabilistic Pruning: A general framework for hardware-constrained pruning at different granularities

Lizeth Gonzalez-Carabarin, Iris A. M. Huijben, Bastiaan S. Veeling, Alexandre Schmid, Ruud J. G. van Sloun

摘要:

非结构化神经网络剪枝算法已经取得了令人印象深刻的压缩率。然而,所得到的通常不规则的稀疏矩阵妨碍了有效的硬件实现,导致额外的存储器使用和复杂的控制逻辑,这减少了非结构化修剪的好处。这刺激了结构化粗粒度修剪解决方案,修剪整个过滤器甚至层,以降低灵活性为代价实现高效实现。在这里,我们提出了一种灵活的新的修剪机制,便于在不同的粒度(权重,内核,过滤器/特征映射)修剪,同时保持有效的内存组织(例如,修剪每个输出神经元的k-out-of-n权重,或修剪每个特征映射的k-out-of-n内核)。我们将该算法称为动态概率剪枝(DPP)。DPP利用Gumbel-softmax松弛进行可微的n取k采样,促进端到端优化。我们表明,DPP在修剪在不同基准数据集上训练的用于图像分类的常见深度学习模型时,可以实现具有竞争力的压缩率和分类准确性。相关地,DPP的非基于幅度的性质允许修剪和权重量化的联合优化,以便进一步压缩网络,我们也展示了这一点。最后,我们提出了新的信息理论指标,显示了一个层内的修剪掩模的信心和修剪多样性。

英文摘要:

Unstructured neural network pruning algorithms have achieved impressive compression rates. However, the resulting - typically irregular - sparse matrices hamper efficient hardware implementations, leading to additional memory usage and complex control logic that diminishes the benefits of unstructured pruning. This has spurred structured coarse-grained pruning solutions that prune entire filters or even layers, enabling efficient implementation at the expense of reduced flexibility. Here we propose a flexible new pruning mechanism that facilitates pruning at different granularities (weights, kernels, filters/feature maps), while retaining efficient memory organization (e.g. pruning exactly k-out-of-n weights for every output neuron, or pruning exactly k-out-of-n kernels for every feature map). We refer to this algorithm as Dynamic Probabilistic Pruning (DPP). DPP leverages the Gumbel-softmax relaxation for differentiable k-out-of-n sampling, facilitating end-to-end optimization. We show that DPP achieves competitive compression rates and classification accuracy when pruning common deep learning models trained on different benchmark datasets for image classification. Relevantly, the non-magnitude-based nature of DPP allows for joint optimization of pruning and weight quantization in order to even further compress the network, which we show as well. Finally, we propose novel information theoretic metrics that show the confidence and pruning diversity of pruning masks within a layer.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑