GraphSnapShot: Graph Machine Learning Acceleration with Fast Storage and Retrieval

Dong Liu, Roger Waleffe, Meng Jiang, Shivaram Venkataraman · OpenReview

Abstract

In our recent research, we have developed a framework called GraphSnapShot, which has been proven an useful tool for graph learning acceleration. GraphSnapShot is a framework for fast cache, storage, retrieval and computation for graph learning. It can quickly store and update the local topology of graph structure and allows us to track patterns in the structure of graph networks, just like take snapshots of the graphs. In experiments, GraphSnapShot shows efficiency, it can achieve up to 30% training acceleration and 73% memory reduction for lossless graph ML training compared to current baselines such as dgl. This technique is particularly useful for large dynamic graph learning tasks such as social media analysis and recommendation systems to process complex relationships between entities.

Introduction

Training Graph Neural Networks (GNNs) on massive, dynamic graphs presents significant computational challenges. Standard techniques often encounter the "neighbor explosion" problem, where the number of nodes to sample grows exponentially with each additional hop. Furthermore, existing systems frequently suffer from I/O bottlenecks, repeatedly resampling local structures and loading embeddings from slow disk storage into fast GPU memory. When graphs evolve dynamically, these systems either become stale or waste resources recomputing from scratch. GraphSnapShot addresses this by bridging the latency gap between disk and computation while adapting to topological changes.

Methodology

The core of GraphSnapShot is the GraphSDSampler, which manages a centralized cache of local graph structures. The framework is built on several key pillars:

Hybrid Sampling Strategy

GraphSnapShot combines static pre-sampling with dynamic real-time updates. A snapshot at time $t$ is defined as: $$G_{snapshot,t} = \alpha \cdot G_{static} + (1 - \alpha) \cdot G_{dynamic,t}$$ The parameter $\alpha$ acts as a "freshness" dial, balancing pre-computed stable structures with real-time updates.

The GraphSnapShot sampling process, illustrating the combination of static pre-sampling and dynamic updates.

System Architecture

The framework implements a three-tier Disk-Cache-CPU/GPU model. The cache stores frequently accessed neighborhoods as key-value pairs, acting as a high-speed buffer that minimizes expensive disk I/O.

The three-tier system architecture of GraphSnapShot, managing data flow between Disk, Cache, and CPU/GPU.

Graph Splitting and Cache Management

Nodes are categorized into Dense (high-degree) and Sparse (low-degree) subgraphs based on a threshold $\theta$. Dense nodes are managed via sophisticated caching strategies:

  • Fully Cache Refresh (FCR): Periodically replaces the entire cache to ensure total freshness.
  • On-The-Fly (OTF): Dynamically updates only the portions of the cache involved in recent computations.
  • Shared Cache Mode: Allows multiple training processes to reuse the same cached subgraphs, reducing redundant memory footprints.

Sparse nodes are handled via Full Batch Load (FBL), fetching directly from disk to save cache space where it isn't needed.

Experimental Results

GraphSnapShot was validated on industry-standard benchmarks including OGBN (ogbn-arxiv, ogbn-products, ogbn-mag) and classic datasets (CiteSeer, Cora, Pubmed).

  • Speed: Training time was reduced by up to 30%, with specific configurations like OTF-shared reaching 29.63% acceleration.
  • Memory Efficiency: The framework achieved up to 73% memory reduction. On the ogbn-mag dataset, it demonstrated an 89.72% compression rate for optimized storage, while GPU memory usage dropped by approximately 40%.
  • Accuracy: GraphSnapShot maintained competitive accuracy compared to traditional samplers in the Deep Graph Library (DGL).

Conclusion

GraphSnapShot provides a robust infrastructure for large-scale GNN training by treating local graph structures as persistent snapshots. By exploiting power-law distributions in real-world graphs, the system optimizes for "heavy hitter" nodes while remaining lean on the "long tail." Future work will focus on automating hyperparameter selection (like $\theta$ and $\alpha$) based on graph topology and exploring performance on specialized hardware like Non-Volatile Memory (NVM) or distributed clusters.

Summary updated

BibTeX
@misc{liu2024graphsnapshot,
  author = {Dong Liu and Roger Waleffe and Meng Jiang and Shivaram Venkataraman},
  title = {{GraphSnapShot: Graph Machine Learning Acceleration with Fast Storage and Retrieval}},
  year = {2024},
  eprint = {2406.17918},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2406.17918},
}
Figure