Large-Scale Spectral Graph Neural Networks via Laplacian Sparsification: Technical Report

Haipeng Ding, Zhewei Wei, Yuhang Ye

Abstract

Graph Neural Networks (GNNs) play a pivotal role in graph-based tasks for their proficiency in representation learning. Among the various GNN methods, spectral GNNs employing polynomial filters have shown promising performance on tasks involving both homophilous and heterophilous graph structures. However, the scalability of spectral GNNs on large graphs is limited because they learn the polynomial coefficients through multiple forward propagation executions. Existing works have attempted to scale up spectral GNNs by eliminating the linear layers on the input node features, a change that can disrupt end-to-end training, potentially impact performance, and become impractical with high-dimensional input features. To address the above challenges, we propose "Spectral Graph Neural Networks with Laplacian Sparsification (SGNN-LS)", a novel graph spectral sparsification method to approximate the propagation patterns of spectral GNNs. We prove that our proposed method generates Laplacian sparsifiers that can approximate both fixed and learnable polynomial filters with theoretical guarantees. Our method allows the application of linear layers on the input node features, enabling end-to-end training as well as the handling of raw text features. We conduct an extensive experimental analysis on datasets spanning various graph scales and properties to demonstrate the superior efficiency and effectiveness of our method. The results show that our method yields superior results in comparison with the corresponding approximated base models, especially on dataset Ogbn-papers100M (111M nodes, 1.6B edges) and MAG-scholar-C (2.8M features).

Introduction

Spectral Graph Neural Networks (GNNs) are powerful tools for capturing complex graph patterns, but they struggle to scale to massive datasets. While standard spatial GNNs often focus on immediate neighborhoods, spectral GNNs utilize polynomial filters (e.g., ChebNet or GPR-GNN) to aggregate information from multiple hops. This capability makes them highly effective for both homophilous graphs (where neighbors are similar) and heterophilous graphs (where neighbors are different).

However, scalability remains a significant hurdle. Computing a $K$-hop filter requires $K$ full-graph matrix multiplications per forward pass, which is computationally prohibitive for graphs with millions of nodes. Previous attempts to scale these models often "detached" propagation from training, precomputing aggregations and training a simple MLP on top. While faster, this approach breaks end-to-end training and limits the model's ability to learn from raw, high-dimensional features like text.

Methodology: Laplacian Sparsification

The proposed framework, Spectral Graph Neural Networks with Laplacian Sparsification (SGNN-LS), addresses these challenges by replacing dense, multi-hop propagation matrices with "spectrally similar" sparse approximations.

The SGNN-LS pipeline: sampling and sparsification are used to approximate the dense neighbor aggregation process of standard spectral GNNs.

The core components include:

  1. Laplacian Sparsification: Instead of exact $K$-step propagation, a sampling strategy based on random walks is employed. By sampling a specific number of edges (proportional to $n \log n$), a sparse graph is constructed that behaves almost identically to the dense polynomial filter in the spectral domain.
  2. SLSGC & GLSGC Variants:
    • SLSGC (Static): Designed for models with fixed filter coefficients (e.g., APPNP).
  3. GLSGC (General/Learnable): Designed for models where coefficients are learned (e.g., GPR-GNN), using a weight adjustment mechanism to ensure proper gradient flow.
  4. Node-Wise Sampling: For semi-supervised settings, sampling paths only from training nodes further reduces memory overhead during mini-batch training.

Experimental Evaluation

The method was evaluated across a wide range of benchmarks, from small-scale datasets like Cora to massive ones like Ogbn-papers100M (111M nodes, 1.6B edges) and MAG-scholar-C (2.8M-dimensional features).

Visual comparison of the original polynomial filtered matrix and its approximations at different sampling scales (ec). As ec increases, the approximation error (difference) decreases.

Key Results

  • Scalability: On Ogbn-papers100M, where standard spectral GNNs typically fail due to memory constraints, APPNP-LS successfully achieved 62.10% accuracy.
  • End-to-End Advantage: On the high-dimensional MAG-scholar-C dataset, GPR-LS achieved 87.30% accuracy, significantly outperforming "detached" baselines like PPRGo.
  • Efficiency: SGNN-LS consistently reduced training time and GPU memory usage. For instance, on the Penn94 dataset, it improved efficiency while maintaining or exceeding vanilla model accuracy.

Discussion and Insights

A surprising finding was the "denoising" effect: sparsified models often outperformed their exact counterparts. The sampling process likely filters out noisy, low-probability connections. Furthermore, maintaining end-to-end training proved essential for handling high-dimensional features where dimensionality reduction is difficult to perform effectively outside the training loop. Theoretical proofs confirm that the relative error in the loss function remains bounded, ensuring the approximation's reliability.

Conclusion and Future Work

SGNN-LS provides a theoretically grounded and practically efficient way to scale spectral GNNs. While the method introduces a hyperparameter ec for sampling density and currently focuses on undirected graphs, it represents a major step forward in making sophisticated spectral methods viable for billion-edge graphs. Future work will explore extensions to directed graphs and further optimization of the initial sampling overhead.

Summary updated

BibTeX
@inproceedings{ding2025large,
  author = {Haipeng Ding and Zhewei Wei and Yuhang Ye},
  title = {{Large-Scale Spectral Graph Neural Networks via Laplacian Sparsification: Technical Report}},
  booktitle = {ACM SIGKDD Conference on Knowledge Discovery and Data Mining},
  year = {2025},
  doi = {10.1145/3690624.3709241},
}
Figure