Abstract
Deep Convolutional Neural Networks (CNNs) are often limited by high computational and memory requirements. While group convolutions offer a path toward efficiency, traditional implementations rely on rigid, data-independent partitioning. We introduce Self-grouping Convolutional Neural Networks (SG-CNN), a framework that allows filters to automatically organize into groups based on learned importance vectors. By applying k-means clustering and centroid-based pruning, SG-CNN creates diverse, sparse architectures that outperform standard group convolution baselines. Our results demonstrate up to a 4.5x speedup with negligible accuracy loss on ImageNet and MS COCO.
Introduction
The deployment of state-of-the-art CNNs on resource-constrained devices remains a significant challenge. Group convolutions, popularized by architectures like ResNeXt and ShuffleNet, reduce FLOPs by dividing input channels into independent groups. However, these methods typically use uniform, predefined group sizes. This "one-size-fits-all" approach ignores the fact that different filters may rely on overlapping or distinct sets of input features. SG-CNN addresses this limitation by making the grouping process data-driven, allowing the network's structure to reflect its learned representational needs.
Methodology: The SG-CNN Pipeline
The transformation of a dense network into a self-grouped architecture follows a systematic pipeline designed to identify and exploit redundancy:
- Importance Vector Evaluation: For each filter, an importance vector is calculated based on the $\ell_1$-norm of its connections to each input channel. This quantifies which input features are most critical for each filter.
- Filter Grouping via Clustering: Instead of manual partitioning, the method uses k-means clustering to group filters with similar importance vectors. This ensures that filters relying on similar input features are co-located within the same group.
- Centroid-based Pruning: The algorithm evaluates the cluster centroids to identify and prune the weakest connections across the group. Because groups are data-dependent, they can end up with varying numbers of input channels, creating a diverse sparse architecture.
- Fine-tuning: To recover any accuracy lost during pruning, the model undergoes both local (per-step) and global fine-tuning.
This approach is applicable to both convolutional and fully-connected (FC) layers. FC layers, which often contain the bulk of a model's parameters, exhibit high redundancy and can be pruned by up to 85% on datasets like CIFAR-10 before accuracy begins to drop significantly.
Experimental Results
The effectiveness of SG-CNN was validated across multiple benchmarks, including CIFAR-10/100, ImageNet, CUB-200, and MS COCO.
Image Classification
On ImageNet, an SG-CNN version of ResNet50 achieved a 3.5x reduction in FLOPs and a 3x compression ratio while maintaining a top-1 accuracy of 73.38%. When applied to DenseNet201, the method achieved over a 4x reduction in FLOPs, delivering higher accuracy than comparable versions of ShuffleNet and MobileNet.
Object Detection and Transfer Learning
The compressed models also generalized well to downstream tasks. In object detection on MS COCO using the Faster R-CNN framework, self-grouped models achieved over 3x reduction in model size and ~3.5x lower FLOPs compared to the ResNet50 baseline, while maintaining or even slightly improving mean Average Precision (mAP).
Discussion and Key Insights
The primary advantage of SG-CNN lies in its embrace of diversity over homogeneity. By allowing groups to vary in size and composition, the network better exploits its representational capacity. Furthermore, because the pruning is data-dependent, the resulting architecture is a direct reflection of the features learned during initial training.
While the current implementation relies on k-means clustering and requires hyperparameter tuning for the number of groups ($g$) and pruning steps ($s$), the results suggest that data-driven grouping is a powerful paradigm for model compression. Future work may explore alternative clustering methods and hardware-level optimizations for non-uniform group structures.
Conclusion
SG-CNN provides a robust framework for automating the design of efficient neural networks. By letting filters "choose their own teammates," the method moves beyond the constraints of manual architectural design, delivering high-performance models suitable for deployment on mobile and embedded systems.
Summary updated