arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2111.06483cs.LGcs.AI
收藏

顺序聚集与再物质化:大图上图神经网络的分布式全批训练

Sequential Aggregation and Rematerialization: Distributed Full-batch Training of Graph Neural Networks on Large Graphs

Intel AI Lab(英特尔人工智能实验室)

Hesham Mostafa

摘要:

我们提出了顺序聚合和再物质化(SAR)计划的分布式全批训练的图神经网络(GNNs)在大型图。最近,GNN的大规模训练主要是基于采样的方法和基于不可学习消息传递的方法。另一方面,SAR是一种分布式技术,可以直接在整个大型图上训练任何GNN类型。SAR中的关键创新是分布式顺序重新物质化方案,该方案在向后传递期间顺序地重建然后释放过大的GNN计算图的片段。这导致了出色的内存扩展行为,其中每个工作线程的内存消耗随工作线程的数量线性下降,即使是密集连接的图形。使用SAR,我们报告了迄今为止全批GNN训练的最大应用,并展示了随着工人数量的增加而节省的大量内存。我们还提出了一种基于核融合和注意力矩阵再物质化的通用技术,以优化基于注意力的模型的运行时间和内存效率。我们表明,与SAR相结合,我们优化的注意力内核可以显著提高基于注意力的GNNs的速度并节省内存。我们提供了SAR GNN训练库:\url{https://github.com/IntelLabs/SAR}。

英文摘要:

We present the Sequential Aggregation and Rematerialization (SAR) scheme for distributed full-batch training of Graph Neural Networks (GNNs) on large graphs. Large-scale training of GNNs has recently been dominated by sampling-based methods and methods based on non-learnable message passing. SAR on the other hand is a distributed technique that can train any GNN type directly on an entire large graph. The key innovation in SAR is the distributed sequential rematerialization scheme which sequentially re-constructs then frees pieces of the prohibitively large GNN computational graph during the backward pass. This results in excellent memory scaling behavior where the memory consumption per worker goes down linearly with the number of workers, even for densely connected graphs. Using SAR, we report the largest applications of full-batch GNN training to-date, and demonstrate large memory savings as the number of workers increases. We also present a general technique based on kernel fusion and attention-matrix rematerialization to optimize both the runtime and memory efficiency of attention-based models. We show that, coupled with SAR, our optimized attention kernels lead to significant speedups and memory savings in attention-based GNNs.We made the SAR GNN training library publicy available: \url{https://github.com/IntelLabs/SAR}.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑