Abstract
Graph kernels, such as the diffusion kernel, are fundamental for measuring node similarity in various domains, yet their exact computation scales cubically with the number of nodes. While Graph Random Features (GRFs) provide a scalable approximation using random walks, they face bottlenecks due to the sequential nature of long walks and inflexible termination criteria. This paper introduces GRFs++ (Refined Graph Random Features), a novel framework that utilizes "walk-stitching" and generalized termination strategies. By decomposing long sequential walks into parallelizable short walks combined via matrix multiplication, GRFs++ achieves superior accuracy and efficiency. We evaluate GRFs++ across diverse synthetic and real-world datasets, demonstrating its effectiveness in kernel estimation, node clustering, and 3D mesh analysis.
Introduction
The ability to measure similarity between nodes is central to graph-based machine learning. Graph kernels provide a mathematically rigorous way to define these similarities, but calculating the full kernel matrix $K$ typically requires $O(N^3)$ operations, making it impractical for large-scale networks.
Graph Random Features (GRFs) were developed to approximate these kernels by sampling random walks. However, standard GRFs have two primary limitations:
- Sequential Bottleneck: Capturing long-range dependencies requires long random walks, which are inherently sequential and cannot leverage the parallel processing power of modern GPUs.
- Rigid Termination: They typically rely on a simple Bernoulli process for walk termination, which may not optimally capture complex graph structures.
Methods: The GRFs++ Framework
GRFs++ addresses these limitations through two key innovations: Walk-Stitching and General Termination Strategies.
Walk-Stitching
The core idea of walk-stitching is to replace a single long, sequential random walk with multiple shorter walks generated in parallel. These short walks are then "stitched" together using optimized matrix multiplication. This approach effectively bridges distant nodes through intermediate "proxy" nodes.
Mathematically, this process involves higher-order de-convolutions to ensure the resulting estimator remains unbiased. By shifting the computational load from sequential sampling to parallel matrix operations, GRFs++ significantly improves throughput on hardware accelerators.
Flexible Termination Strategies
Unlike standard GRFs that use a fixed stopping probability, GRFs++ allows walk lengths to be sampled from arbitrary discrete probability distributions, such as the Poisson distribution. This flexibility allows the algorithm to better allocate computational resources, ensuring that walk lengths are tailored to the specific structural properties of the graph being modeled.
Experimental Results
Kernel Estimation Accuracy
We evaluated the accuracy of GRFs++ in estimating the true diffusion kernel across various graph topologies, including Erdős-Rényi (ER) graphs, binary trees, and real-world networks like the Eurosis dataset.
As shown in the experimental results, increasing the "stitching degree" (the number of short walks combined) leads to a monotonic decrease in the Frobenius norm error. GRFs++ is particularly effective in large-diameter graphs where long-range dependencies are critical.
Computational Efficiency and Downstream Tasks
In addition to improved accuracy, GRFs++ offers substantial speedups. In tests on 500-node graphs, the "Walk Time" was drastically reduced compared to sequential GRFs. While the matrix multiplication introduces a "Stitching Time," the total execution time remains significantly lower.
The practical utility of GRFs++ was further validated through:
- Node Clustering: On the Eurosis dataset, GRFs++ reduced the clustering error rate from 0.2248 to 0.1304.
- 3D Mesh Analysis: In predicting vertex normals for the Thingi10K dataset, GRFs++ performed on par with exact kernel baselines while being computationally feasible for large meshes.
Conclusion
GRFs++ represents a significant advancement in graph kernel approximation. By reimagining random walks through the lens of parallelizable matrix operations and flexible statistical distributions, it overcomes the sequential bottlenecks of previous methods. While the current implementation excels with the diffusion kernel and assumes graph sparsity for optimal performance, future work may extend these principles to dynamic graphs and integrated Graph Neural Network architectures.
Summary updated