Skip to main content
QUICK REVIEW

[Paper Review] DepGraph: Towards Any Structural Pruning

Gongfan Fang, Xinyin Ma|arXiv (Cornell University)|Jan 30, 2023
Advanced Neural Network ApplicationsComputer Science6 citations
TL;DR

This paper proposes DepGraph, a general and fully automatic method for structural pruning across diverse neural network architectures—including CNNs, Transformers, RNNs, and GNNs—by modeling inter-layer dependencies via a dependency graph to enable simultaneous, consistent pruning of coupled layers. Using a simple norm-based criterion within the graph-structured grouping, DepGraph achieves state-of-the-art or competitive performance across multiple benchmarks without architecture-specific design.

ABSTRACT

Structural pruning enables model acceleration by removing structurally-grouped parameters from neural networks. However, the parameter-grouping patterns vary widely across different models, making architecture-specific pruners, which rely on manually-designed grouping schemes, non-generalizable to new architectures. In this work, we study a highly-challenging yet barely-explored task, any structural pruning, to tackle general structural pruning of arbitrary architecture like CNNs, RNNs, GNNs and Transformers. The most prominent obstacle towards this goal lies in the structural coupling, which not only forces different layers to be pruned simultaneously, but also expects all removed parameters to be consistently unimportant, thereby avoiding structural issues and significant performance degradation after pruning. To address this problem, we propose a general and {fully automatic} method, \emph{Dependency Graph} (DepGraph), to explicitly model the dependency between layers and comprehensively group coupled parameters for pruning. In this work, we extensively evaluate our method on several architectures and tasks, including ResNe(X)t, DenseNet, MobileNet and Vision transformer for images, GAT for graph, DGCNN for 3D point cloud, alongside LSTM for language, and demonstrate that, even with a simple norm-based criterion, the proposed method consistently yields gratifying performances.

Motivation & Objective

  • To address the challenge of generalizing structural pruning across diverse neural network architectures such as CNNs, Transformers, RNNs, and GNNs.
  • To overcome the limitations of architecture-specific, manually designed pruning schemes that lack transferability.
  • To model structural coupling between layers—where pruning one layer necessitates pruning others due to architectural constraints—using a unified framework.
  • To develop a group-level importance criterion that ensures consistent unimportance across coupled layers, minimizing performance degradation.
  • To enable fully automatic, architecture-agnostic structural pruning without requiring task-specific or network-specific tuning.

Proposed method

  • Construct a Dependency Graph (DepGraph) that explicitly models inter-layer dependencies across all layers in a neural network, capturing structural couplings such as skip connections and batch normalization.
  • Use graph traversal to identify maximal connected components in the dependency graph, which define the groups of layers that must be pruned together.
  • Derive grouping matrices from the dependency graph to map each layer to its coupled group, ensuring structural consistency during pruning.
  • Design a group-level importance criterion that evaluates the collective importance of parameters within each group, enabling consistent sparsity across coupled layers.
  • Apply a simple norm-based importance score to each group, avoiding reliance on complex training or architecture-specific metrics.
  • Perform structural pruning by removing entire groups of parameters simultaneously, preserving network integrity and enabling efficient inference.

Experimental results

Research questions

  • RQ1Can a general-purpose method be developed to enable structural pruning across diverse neural network architectures without architectural prior knowledge?
  • RQ2How can inter-layer dependencies in complex architectures (e.g., residual blocks, attention mechanisms) be systematically modeled to enable safe, simultaneous pruning?
  • RQ3Can a group-level importance criterion outperform layer-wise criteria in maintaining model accuracy during structural pruning?
  • RQ4To what extent can a simple norm-based criterion, when combined with dependency modeling, achieve performance comparable to state-of-the-art methods using complex criteria?
  • RQ5Is the proposed method generalizable to non-CNN architectures such as Transformers, RNNs, GNNs, and models for 3D point clouds and graphs?

Key findings

  • DepGraph achieves a 2.57× speedup on ResNet-56 with 93.64% accuracy on CIFAR-10, outperforming the unpruned model (93.53%).
  • On ImageNet-1k, DepGraph achieves 71.87% top-1 accuracy on ResNeXt-50 with a 1.14% accuracy drop and 2.09× speedup, outperforming prior methods in terms of accuracy retention.
  • For Vision Transformers (ViT-B/16), DepGraph+EMA maintains 81.07% top-1 accuracy with only a 1.39% drop and achieves 10.4× speedup.
  • On non-image tasks, DepGraph achieves 11.98× speedup on DGCNN for 3D point cloud classification with only 0.08% accuracy drop, demonstrating strong generalization.
  • In graph learning (PPI), DepGraph achieves 8.43× speedup with a 0.025 micro-F1 score drop, showing effectiveness on GNNs.
  • The method generalizes well across architectures: it achieves competitive results on LSTM (AGNews), DGCNN (ModelNet40), and GAT (PPI), even with a basic norm-based criterion.

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.