Skip to content

Commit

Permalink
[GraphBolt][CUDA] Demonstrate GPUGraphCache usage in example. (#7482)
Browse files Browse the repository at this point in the history
  • Loading branch information
mfbalin committed Jun 26, 2024
1 parent f63fee3 commit 2e1097f
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions examples/sampling/graphbolt/pyg/node_classification_advanced.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,8 @@ def create_dataloader(
datapipe,
num_workers=args.num_workers,
overlap_graph_fetch=args.overlap_graph_fetch,
num_gpu_cached_edges=args.num_gpu_cached_edges,
gpu_cache_threshold=args.gpu_graph_caching_threshold,
)


Expand Down Expand Up @@ -370,6 +372,18 @@ def parse_args():
"with the rest of operations by using an alternative CUDA stream. Disabled"
"by default.",
)
parser.add_argument(
"--num-gpu-cached-edges",
type=int,
default=0,
help="The number of edges to be cached from the graph on the GPU.",
)
parser.add_argument(
"--gpu-graph-caching-threshold",
type=int,
default=1,
help="The number of accesses after which a vertex neighborhood will be cached.",
)
parser.add_argument(
"--torch-compile",
action="store_true",
Expand Down

0 comments on commit 2e1097f

Please sign in to comment.