Skip to main content
QUICK REVIEW

[论文解读] Faster CNNs with Direct Sparse Convolutions and Guided Pruning

Jongsoo Park, Sheng Li|arXiv (Cornell University)|Aug 4, 2016
Advanced Neural Network Applications参考文献 24被引用 120
一句话总结

本文 소개了一种具有任意稀疏模式的直接稀疏卷积方法、用于预测加速比的性能模型,以及用于在速度、大小和准确性方面剪枝网络的 Guided Sparsity Learning,在跨平台上实现显著的加速。

ABSTRACT

Phenomenally successful in practical inference problems, convolutional neural networks (CNN) are widely deployed in mobile devices, data centers, and even supercomputers. The number of parameters needed in CNNs, however, are often large and undesirable. Consequently, various methods have been developed to prune a CNN once it is trained. Nevertheless, the resulting CNNs offer limited benefits. While pruning the fully connected layers reduces a CNN's size considerably, it does not improve inference speed noticeably as the compute heavy parts lie in convolutions. Pruning CNNs in a way that increase inference speed often imposes specific sparsity structures, thus limiting the achievable sparsity levels. We present a method to realize simultaneously size economy and speed improvement while pruning CNNs. Paramount to our success is an efficient general sparse-with-dense matrix multiplication implementation that is applicable to convolution of feature maps with kernels of arbitrary sparsity patterns. Complementing this, we developed a performance model that predicts sweet spots of sparsity levels for different layers and on different computer architectures. Together, these two allow us to demonstrate 3.1--7.3$ imes$ convolution speedups over dense convolution in AlexNet, on Intel Atom, Xeon, and Xeon Phi processors, spanning the spectrum from mobile devices to supercomputers. We also open source our project at https://github.com/IntelLabs/SkimCaffe.

研究动机与目标

  • 推动在简单参数剪枝之外进一步减少 CNN 推理时间和模型大小。
  • 开发一种高效的稀疏卷积,能够处理内核中的任意稀疏模式。
  • 创建一个性能模型,用于预测跨架构的加速并指导剪枝。
  • 提出 Guided Sparsity Learning,以针对性地对层进行速度优化剪枝而不损失准确性。
  • 在多种硬件上展示 AlexNet 和 GoogLeNet 的显著加速。

提出的方法

  • 将直接稀疏卷积表述为稀疏矩阵-密集矩阵乘法,并在运行时创建一个虚拟的密集输入(不进行降低)。
  • 在卷积核中启用任意稀疏模式(逐元素稀疏性),以最大化剪枝潜力。
  • 使用 roofline 框架开发性能模型,以界定稀疏卷积的加速上限并识别有用的稀疏性范围。
  • 引入 Guided Sparsity Learning (GSL),根据预测的加速潜力对层进行剪枝,包含如 GESL 和 GDNS 的变体。
  • 使用元素级正则化辅助速度模型训练网络,以在准确性、速度和大小之间取得平衡。

实验结果

研究问题

  • RQ1在不同稀疏模式下,直接稀疏卷积如何超过传统基于降低的稀疏方法?
  • RQ2哪些稀疏度水平和层的目标在保持准确性的同时能最大化推理加速?
  • RQ3性能模型是否能对不同架构(Atom、Xeon、Xeon Phi)和 CNN 层准确预测加速?
  • RQ4Guided Sparsity Learning 能否有效剪枝网络以实现加速而不牺牲准确性?
  • RQ5在多平台上,AlexNet 和 GoogLeNet 的可实现加速和稀疏度极限是多少?

主要发现

  • 直接稀疏卷积在 Atom、Xeon 和 Xeon Phi 处理器上的 AlexNet 相对于密集卷积实现了 3.1–7.3× 的加速。
  • 一个通用的性能模型预测在不同架构上实现有意义加速的加速幅度及稀疏性的上/下界。
  • Guided Sparsity Learning (GSL) 通过针对具备加速潜力的层进行剪枝,在不显著或不损失准确性的情况下实现显著的稀疏化。
  • 应用引导剪枝时,GoogLeNet 在卷积和全连接层可损失超过 80% 的参数且不出现精度下降。
  • 在 AlexNet 上,BDW 在非零密度 x = 0.09 时实现 3.4× 加速;Atom 在 x = 0.09 时实现 7.3× 加速;KNL 在 x = 0.09 时达到 13.9× 有效 TF/s。
  • 作者在 https://github.com/IntelLabs/SkimCaffe 提供了开源实现。

更好的研究,从现在开始

从论文设计到论文写作,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。