Abstract
Deep convolutional neural networks (CNNs) are often limited by their massive parameter counts and high computational costs. This paper introduces the Kronecker Layer, a novel compression technique that approximates large weight matrices as a sum of Kronecker products of smaller matrices. By exploiting local structures and redundancies across multiple dimensions, this approach achieves up to a 3.6x reduction in parameters or a 3.3x speedup with minimal accuracy loss, even setting new state-of-the-art results on several benchmarks.
Introduction
As deep learning models grow in complexity, deploying them on resource-constrained hardware like mobile devices becomes increasingly difficult. Standard compression methods, such as Singular Value Decomposition (SVD), treat weight matrices as collections of 1D vectors. However, this fails to capture the inherent 2D or multi-dimensional "local structures" present in CNN weights. The authors propose the Kronecker Layer to address this limitation, providing a more efficient way to represent high-dimensional tensors.
Methods: The Kronecker Layer
The core proposal involves replacing standard layers with Kronecker-based alternatives:
- KFC (Kronecker Fully-Connected) Layer: A large weight matrix $W$ is approximated as $W \approx \sum_{i=1}^{r} A_i \otimes B_i$, where $A$ and $B$ are significantly smaller matrices and $\otimes$ denotes the Kronecker product.
- The "Vec-Trick": Computational efficiency is achieved via the property $(A \otimes B) \text{vec}(X) = \text{vec}(BXA^T)$. This allows the layer to be computed using two small matrix multiplications and a reshape operation, avoiding the need to ever explicitly form the massive Kronecker product matrix.
- KConv (Kronecker Convolutional) Layer: This logic extends to 4D convolutional tensors, where a KConv layer is implemented as two consecutive, smaller convolutional layers with an intermediate reshape.
Key Insights: Exploiting Local Structure
A primary advantage of the Kronecker product is its ability to generalize the outer product to matrices, allowing the model to exploit redundancy between local patches of any shape.
This intuition is best demonstrated through image reconstruction. When using the same number of parameters, a Kronecker-based approximation preserves significantly more detail than an SVD-based one. While SVD captures 1D vector redundancies, the Kronecker approach captures 2D local structures, leading to a much higher fidelity reconstruction of the original data.
Experimental Results
The authors evaluated the Kronecker Layer across several diverse computer vision benchmarks:
- SVHN (Street View House Numbers): The KFC layer reduced parameters by 20x with only a 0.25% drop in accuracy. For sequence recognition, they achieved a new state-of-the-art error rate of 3.4% using only 12% of the original parameters.
- CASIA-HWDB: In handwritten Chinese character recognition, the method set a new state-of-the-art error rate of 3.37%. Interestingly, the efficiency of Kronecker layers allowed the authors to use larger feature maps, which actually improved accuracy over the baseline.
- Scene Text Recognition: The KConv layer provided a 3.3x speedup for the entire model with less than 1% accuracy loss.
- ImageNet (ILSVRC12): On AlexNet, the method achieved a 10x parameter reduction in the fully-connected layers while maintaining performance comparable to or better than SVD-based methods.
Conclusion
The Kronecker Layer offers a powerful alternative to standard low-rank approximations by specifically targeting the local structures inherent in convolutional networks. By enabling significant compression and speedups without sacrificing accuracy—and in some cases, improving it by allowing for larger feature maps—this technique provides a robust path for deploying state-of-the-art models on limited hardware. Future work includes automating the selection of sub-matrix shapes and further optimizing the rank-selection process.
Summary updated