330
v1v2v3v4v5 (latest)

Local Fragments, Global Gains: Subgraph Counting using Graph Neural Networks

Main:24 Pages
4 Figures
Bibliography:3 Pages
5 Tables
Abstract

Subgraph counting is a fundamental task for analyzing structural patterns in graph-structured data, with important applications in domains such as computational biology and social network analysis, where recurring motifs reveal functional and organizational properties. In this paper, we propose localized versions of the Weisfeiler-Leman (WL) algorithms to improve both expressivity and computational efficiency for this task. We introduce Local kk-WL, which we prove to be more expressive than kk-WL and at most as expressive as (k+1)(k+1)-WL, and provide a characterization of patterns whose subgraph and induced subgraph counts are invariant under Local kk-WL equivalence. To enhance scalability, we present two variants -- Layer kk-WL and Recursive kk-WL -- that achieve greater time and space efficiency compared to applying kk-WL on the entire graph. Additionally, we propose a novel fragmentation technique that decomposes complex subgraphs into simpler subpatterns, enabling the exact count of all induced subgraphs of size at most 44 using only 11-WL, with extensions possible for larger patterns when k>1k>1. Building on these ideas, we develop a three-stage differentiable learning framework that combines subpattern counts to compute counts of more complex motifs, bridging combinatorial algorithm design with machine learning approaches. We also compare the expressive power of Local kk-WL with existing GNN hierarchies and demonstrate that, under bounded time complexity, our methods are more expressive than prior approaches.

View on arXiv
Comments on this paper