Abstract
Graph Neural Networks (GNNs) are powerful tools for relational data but suffer from high computational costs, primarily due to Sparse-Matrix Dense-Matrix Multiplication (SpMM). We present SGS-GNN, a supervised graph sparsification framework that learns to prune up to 80% of edges while improving prediction accuracy. By integrating task-specific losses and structural priors, SGS-GNN effectively filters noise in heterophilic graphs and reduces resource requirements. Our evaluation across 33 benchmark datasets shows that SGS-GNN outperforms state-of-the-art methods in both efficiency and F1-scores.
Introduction
The computational bottleneck in GNNs is often the processing of large, dense edge sets. Sparsification—the removal of non-essential edges—is a common strategy to scale these models. However, existing unsupervised methods often ignore task-specific information, while previous supervised approaches are frequently too computationally expensive for large-scale applications. SGS-GNN addresses these challenges by providing a task-aware, efficient sparsification pipeline.
Methodology
The SGS-GNN framework is composed of three primary modules designed to learn an optimal subgraph for a given downstream task.
Module I: Edge Probability Encoding
The process begins with an EdgeMLP that assigns a probability of existence to each edge based on node features. To prevent the loss of critical structural information, the model incorporates a structural prior based on node degrees, ensuring that "bridge" edges between low-degree nodes are preserved.
Module II: Sparse Subgraph Sampling
Using the learned probabilities, a subgraph of a target size (e.g., 20% of the original edges) is sampled. The framework utilizes the Gumbel-Softmax trick with temperature annealing, allowing the model to explore various subgraph configurations during the early stages of training before converging on a stable structure.
Module III: Downstream GNN
The sampled sparse subgraph is then passed to a standard GNN architecture (such as GCN or GAT) for the final task. The entire system is trained end-to-end using a composite loss function including Cross-Entropy Loss for the primary task, Assortativity Loss to encourage similarity between connected nodes, and Consistency Loss to align edge probabilities with latent embeddings.
Experimental Evaluation
SGS-GNN was evaluated on 33 benchmark datasets, including 21 heterophilic graphs (e.g., Roman-Empire, Amazon-Ratings) and 12 homophilic graphs (e.g., Cora, PubMed). This diverse set allows for a robust assessment of the model's ability to handle different graph structures.
Key Insights and Results
A core finding is that "less is more" when dealing with heterophilic graphs. In these environments, many edges connect nodes with different labels, acting as noise that degrades GNN performance. SGS-GNN learns to identify and prune these distracting connections.
As shown in the training dynamics, the edge homophily of the sampled subgraph increases significantly over time, particularly on heterophilic datasets like Roman-Empire. This indicates that the model successfully learns to retain edges that are most beneficial for the classification task.
Performance and Efficiency
- Accuracy: Retaining only 20% of edges, SGS-GNN achieved a 4% geometric mean improvement in F1-scores relative to the full graph. On certain heterophilic datasets, improvements reached up to 30%.
- Convergence: The model requires approximately half the number of epochs to converge compared to sparsifiers using fixed distributions.
- Scalability: By employing METIS partitioning for batch processing, SGS-GNN can handle large graphs that often cause memory issues for other supervised sparsification methods.
Conclusion
SGS-GNN demonstrates that supervised sparsification can simultaneously reduce the computational footprint of GNNs and improve their predictive power. By filtering task-irrelevant edges, the model provides a more efficient and accurate path for learning on complex relational data. Future work will explore the framework's robustness against adversarial attacks and further optimize training efficiency for web-scale graphs.
Summary updated