ChebNet: Spectral Graph Convolutions via Chebyshev Polynomials

6 minute read

Published:

TL;DR: ChebNet (Defferrard et al., 2016) approximates spectral graph filters with degree-\(K\) Chebyshev polynomials of a rescaled Laplacian \(\tilde{L} = \tfrac{2}{\lambda_{\max}}L_{\mathrm{sym}} - I\). This eliminates the eigendecomposition, runs in \(O(K|E|)\) time, and makes each node aggregate only from its \(K\)-hop neighbourhood. GCN is the \(K=1\) case with \(\lambda_{\max}\) fixed to \(2\) and the two remaining coefficients tied.
ChebNet spectral convolution
ChebNet: Chebyshev spectral graph convolutions (Defferrard et al., 2016)

The Problem with Direct Spectral Convolution

The spectral graph convolution \(h_\theta \star_G f = U\, h_\theta(\Lambda)\, U^{\top} f\), where \(L_{\mathrm{sym}} = I - D^{-1/2}AD^{-1/2} = U\Lambda U^{\top}\), requires:

  1. Full eigendecomposition of \(L_{\mathrm{sym}}\): \(O(N^3)\) — infeasible for large graphs
  2. Multiplying by \(U\) and \(U^{\top}\): \(O(N^2)\) per forward pass
  3. A learned filter \(h_\theta(\Lambda)\) with \(N\) free parameters — one per eigenvalue — not scalable, and tied to one fixed graph

ChebNet solves all three problems at once.

Chebyshev Polynomial Approximation

The Chebyshev polynomials \(\{T_0, T_1, T_2, \dots\}\) are orthogonal on \([-1,1]\) with respect to the weight \((1-x^2)^{-1/2}\) (orthogonal, not orthonormal — \(\lVert T_0\rVert^2 = \pi\) and \(\lVert T_k \rVert^2 = \pi/2\) for \(k \ge 1\)). A truncated Chebyshev expansion is near-minimax: its worst-case error on \([-1,1]\) is within a small logarithmic factor of the best possible degree-\(K\) approximation, which is why it is the standard basis for polynomial filter design.

ChebNet approximates the spectral filter as a degree-\(K\) Chebyshev polynomial:

\[ h_\theta(\Lambda) \;\approx\; \sum_{k=0}^{K} \theta_k\, T_k(\tilde{\Lambda}), \qquad \tilde{\Lambda} = \frac{2}{\lambda_{\max}}\Lambda - I . \]

The rescaling maps the spectrum into \([-1,1]\), which is where the Chebyshev basis is well conditioned. For \(L_{\mathrm{sym}}\) the spectrum lies in \([0,2]\), with \(\lambda_{\max}=2\) attained exactly when some connected component is bipartite — so \(\tilde{\Lambda}\) always lands in \([-1,1]\). The polynomials satisfy the three-term recursion:

\[ T_0(x) = 1, \qquad T_1(x) = x, \qquad T_k(x) = 2x\,T_{k-1}(x) - T_{k-2}(x). \]

Why this matters: applying \(T_k(\tilde{\Lambda})\) never requires the eigenvectors. Because \(\tilde{L} = \tfrac{2}{\lambda_{\max}}L_{\mathrm{sym}} - I = U\tilde{\Lambda}U^{\top}\) and any polynomial commutes with the similarity transform, \(T_k(\tilde{L}) = U\,T_k(\tilde{\Lambda})\,U^{\top}\). So we can compute directly in the node domain:

\[ y \;=\; \sum_{k=0}^{K} \theta_k\, T_k(\tilde{L})\, f \;=\; \sum_{k=0}^{K} \theta_k\, \bar{z}_k . \]

with \(\bar{z}_0 = f\), \(\bar{z}_1 = \tilde{L}f\), \(\bar{z}_k = 2\tilde{L}\bar{z}_{k-1} - \bar{z}_{k-2}\) — a recursion using only sparse matrix–vector products with \(\tilde{L}\), each costing \(O(\lvert E\rvert)\).

Computational Properties

PropertyDirect spectralChebNet (degree \(K\))
Eigendecomposition\(O(N^3)\)None needed
Forward pass cost\(O(N^2)\)\(O(K\lvert E\rvert)\)
Filter parameters\(N\)\(K+1\)
Spatial localityNon-local (all nodes)\(K\)-hop neighbourhood
Scalable to large graphsNoYes

Spatial interpretation: \(\tilde{L}\) has the same sparsity pattern as \(A\) (plus the diagonal), so \(\tilde{L}^k\) — and therefore \(T_k(\tilde{L})\), a degree-\(k\) polynomial in \(\tilde{L}\) — has a non-zero entry at \((u,v)\) only if \(\mathrm{dist}(u,v) \le k\). A degree-\(K\) ChebNet layer therefore reads from all nodes within \(K\) hops, the same receptive field as \(K\) stacked message-passing layers — but in a single layer, with only \(K+1\) filter coefficients rather than \(K\) nonlinear layers.

Key insight: By choosing Chebyshev polynomials, Defferrard et al. simultaneously (1) avoided eigendecomposition, (2) reduced filter parameters from \(N\) to \(K+1\), and (3) localised the filter to \(K\)-hop neighbourhoods. This makes ChebNet a spatial–spectral bridge: defined spectrally, computed spatially.
Intuition: Why Chebyshev Polynomials Specifically? You need to approximate a filter response \(h_\theta(\lambda)\) on the interval \([-1,1]\). Any polynomial basis spans the same functions, but the Chebyshev basis is numerically well conditioned there and a truncated Chebyshev expansion comes within a small factor of the best possible uniform (minimax) error, whereas the naive monomial basis \(1, \lambda, \lambda^2, \dots\) becomes badly ill-conditioned as the degree grows. It also has the stable three-term recursion \(T_k(x) = 2x\,T_{k-1}(x) - T_{k-2}(x)\), which lets you evaluate \(T_k(\tilde{L})f\) by successive sparse matrix–vector products with no eigendecomposition. It is the same reason Chebyshev polynomials are used in iterative solvers and spectral methods for PDEs.

Step-by-step computation for a degree-2 filter:

Given the rescaled Laplacian \(\tilde{L}\) and an input signal \(f\) (a single node feature):

z̄₀ = f                     # T₀(L̃)f = I·f = f  (no propagation)
z̄₁ = L̃ · f                 # T₁(L̃)f = L̃·f  (1-hop propagation)
z̄₂ = 2·L̃·z̄₁ − z̄₀         # T₂(L̃)f = 2L̃·z̄₁ − z̄₀  (reaches 2 hops)

output = θ₀·z̄₀ + θ₁·z̄₁ + θ₂·z̄₂  # learned linear combination

Each \(\bar{z}_k\) collects information from within \(k\) hops. The scalars \(\theta_0, \theta_1, \theta_2\) are the only learned parameters — deciding how much to weight each hop.

The ChebNet Layer

In the multi-feature case, a ChebNet layer with \(F_{\mathrm{in}}\) input features and \(F_{\mathrm{out}}\) output features replaces each scalar \(\theta_k\) with a weight matrix:

\[ H_{\mathrm{out}} = \sigma\!\left( \sum_{k=0}^{K} T_k(\tilde{L})\, H_{\mathrm{in}}\, \Theta_k \right), \qquad \Theta_k \in \mathbb{R}^{F_{\mathrm{in}} \times F_{\mathrm{out}}}. \]

Learnable parameters: \((K+1) \cdot F_{\mathrm{in}} \cdot F_{\mathrm{out}}\) — one weight matrix per polynomial order, versus a single \(F_{\mathrm{in}} \times F_{\mathrm{out}}\) matrix for a plain linear layer.

From ChebNet to GCN

GCN (Kipf & Welling, 2017) starts from the \(K=1\) truncation:

\[ h_\theta(\tilde{L}) \;\approx\; \theta_0 T_0(\tilde{L}) + \theta_1 T_1(\tilde{L}) \;=\; \theta_0 I + \theta_1 \tilde{L}. \]

Now fix \(\lambda_{\max} \approx 2\) — justified because \(\lambda_{\max}(L_{\mathrm{sym}}) \le 2\) always, with equality only for bipartite components, and because the network can absorb the rescaling into its weights anyway. Then \(\tilde{L} = L_{\mathrm{sym}} - I = -D^{-1/2}AD^{-1/2}\), so

\[ h_\theta(\tilde{L}) \;\approx\; \theta_0 I - \theta_1 D^{-1/2}AD^{-1/2}. \]

Tying the two coefficients with \(\theta = \theta_0 = -\theta_1\) leaves one free parameter and gives \(\theta\left(I + D^{-1/2}AD^{-1/2}\right)\). That operator equals \(2I - L_{\mathrm{sym}}\), so its spectrum is \([0,2]\) — eigenvalues above 1 mean repeated application amplifies part of the signal, which is numerically unstable in a deep stack. The renormalisation trick therefore replaces it with the self-looped propagation matrix, whose spectrum sits in \((-1,1]\), giving the familiar GCN layer:

\[ H^{(l+1)} = \sigma\!\left(\hat{A} H^{(l)} W^{(l)}\right), \qquad \hat{A} = \tilde{D}^{-1/2}\tilde{A}\tilde{D}^{-1/2}, \quad \tilde{A} = A + I . \]

So GCN is the first-order Chebyshev filter with \(\lambda_{\max}\) pinned to \(2\), its two coefficients tied, and the resulting operator renormalised. It sacrifices filter expressiveness — a single fixed low-pass response per layer instead of a learnable degree-\(K\) response — for simplicity and scalability.

ChebConv in Practice (PyG)

from torch_geometric.nn import ChebConv

conv = ChebConv(in_channels=64, out_channels=64, K=3)
# PyG's K counts the number of Chebyshev terms: it uses T₀, T₁, T₂,
# i.e. polynomial degree 2 → a 2-hop receptive field.
# 3 × 64 × 64 = 12,288 learnable parameters vs 64 × 64 = 4,096 for GCN

Note the off-by-one: PyG’s K is the number of terms \(K_{\text{PyG}} = K_{\text{degree}} + 1\), so K=3 reaches 2 hops, not 3.

When to Use ChebNet vs GCN

ScenarioRecommendation
Need multi-hop receptive field explicitlyChebNet (set \(K\))
Fast, simple baselineGCN (\(K=1\))
Very large graph (>1M nodes)GCN (simpler, better optimised)
Want a learnable, non-low-pass spectral filterChebNet
Need long-range dependenciesMultiple layers (both) or Graph Transformers

Summary

ChebNet is the theoretical bridge between the spectral and spatial views of graph neural networks. It:

  • Avoids eigendecomposition via polynomial approximation
  • Achieves \(O(K\lvert E\rvert)\) complexity per layer (linear in edges)
  • Reduces filter parameters from \(N\) to \(K+1\)
  • Has provable locality (support inside the \(K\)-hop neighbourhood)
  • Contains GCN as the \(K=1\) case, once \(\lambda_{\max}\) is pinned to \(2\), the coefficients are tied, and the operator is renormalised

Understanding ChebNet is essential for understanding why GCN works and what it approximates.

References