Skip to main content
QUICK REVIEW

[Paper Review] StrassenNets: Deep Learning with a Multiplication Budget

Michael Tschannen, Aran Khanna|arXiv (Cornell University)|Dec 11, 2017
Advanced Neural Network ApplicationsComputer Science40 references11 citations
TL;DR

This paper proposes StrassenNets, a framework that replaces matrix multiplications in deep neural networks with learnable, low-multiplication arithmetic circuits based on sum-product networks (SPNs), enabling end-to-end training with a strict budget on multiplications. It achieves over 99.5% reduction in multiplications while maintaining full-precision model accuracy through joint optimization and knowledge distillation, and rediscoveries Strassen’s algorithm for 2×2 matrix multiplication using only 7 multiplications instead of 8.

ABSTRACT

A large fraction of the arithmetic operations required to evaluate deep neural networks (DNNs) consists of matrix multiplications, in both convolution and fully connected layers. We perform end-to-end learning of low-cost approximations of matrix multiplications in DNN layers by casting matrix multiplications as 2-layer sum-product networks (SPNs) (arithmetic circuits) and learning their (ternary) edge weights from data. The SPNs disentangle multiplication and addition operations and enable us to impose a budget on the number of multiplication operations. Combining our method with knowledge distillation and applying it to image classification DNNs (trained on ImageNet) and language modeling DNNs (using LSTMs), we obtain a first-of-a-kind reduction in number of multiplications (over 99.5%) while maintaining the predictive performance of the full-precision models. Finally, we demonstrate that the proposed framework is able to rediscover Strassen's matrix multiplication algorithm, learning to multiply $2 imes 2$ matrices using only 7 multiplications instead of 8.

Motivation & Objective

  • To reduce the number of multiplications in deep neural networks (DNNs) for efficient deployment on resource-constrained hardware.
  • To enable fine-grained control over the trade-off between arithmetic complexity and model accuracy by imposing a multiplication budget.
  • To learn approximate matrix multiplication transforms end-to-end from data, rather than relying on handcrafted algorithms like Strassen’s or Winograd.
  • To maintain predictive performance of full-precision models despite drastic reductions in multiplication count.
  • To demonstrate that the framework can rediscover known fast algorithms such as Strassen’s matrix multiplication.

Proposed method

  • Casting matrix multiplication in DNN layers as a 2-layer sum-product network (SPN), which disentangles multiplication and addition operations.
  • Representing SPN edge weights as ternary matrices in {−1, 0, 1}, enabling explicit control over the number of multiplications via the number of non-zero weights.
  • Performing end-to-end stochastic gradient descent to jointly optimize SPN weights and network parameters using data-driven learning.
  • Applying knowledge distillation to transfer knowledge from full-precision teacher models to compressed student models with minimal accuracy degradation.
  • Applying the framework to both convolutional and recurrent layers, including ResNets and LSTM-based language models, by reformulating convolutions and fully connected layers as SPN-based transforms.
  • Using a parameterization strategy where the number of hidden units in the SPN (r) controls the multiplication budget, with r set to the number of output channels or hidden units.

Experimental results

Research questions

  • RQ1Can a learnable, differentiable framework reduce the number of multiplications in DNNs more effectively than handcrafted algorithms like Strassen’s or Winograd?
  • RQ2To what extent can end-to-end learning of SPN-based transforms maintain model accuracy while reducing multiplications by over 99%?
  • RQ3Can knowledge distillation restore predictive performance in models with drastically reduced multiplication counts?
  • RQ4Does the framework rediscover known fast algorithms such as Strassen’s 2×2 matrix multiplication using only 7 multiplications?
  • RQ5How does the proposed method compare to existing quantization and compression techniques in terms of multiplication reduction and accuracy?

Key findings

  • StrassenNets reduced the number of multiplications by 99.63% in ResNet-18 on ImageNet while incurring only a 2.0% top-1 accuracy drop compared to the full-precision model.
  • For language modeling, the method achieved a 99.69% reduction in multiplications with only a 3.3% increase in perplexity on the PTB dataset.
  • With knowledge distillation, the framework achieved over 99.5% reduction in multiplications while maintaining the predictive performance of full-precision models for both image classification and language modeling.
  • The distilled StrassenNets outperformed the teacher model for r ≥ n_out in the language model setting, indicating that knowledge distillation enhances compressed model performance.
  • The framework successfully rediscovered Strassen’s 2×2 matrix multiplication algorithm, learning to multiply 2×2 matrices with only 7 multiplications instead of 8.
  • The method achieved a 7.4% lower perplexity than a comparable TWN quantization baseline with similar multiplication counts, demonstrating superior efficiency-accuracy trade-offs.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.