arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2212.04540cs.IR
收藏

TinyKG:一种用于知识图谱神经推荐系统的记忆高效训练框架

TinyKG: Memory-Efficient Training Framework for Knowledge Graph Neural Recommender Systems

Huiyuan Chen, Xiaoting Li, Kaixiong Zhou, Xia Hu, Chin-Chia Michael Yeh, Yan Zheng, Hao Yang

摘要:

人们对设计各种知识图谱神经网络(KGNNs)产生了极大的兴趣,它们实现了最先进的性能并为推荐提供了很好的解释性。有前途的性能主要是由于他们的能力,捕捉高阶邻近信息的知识图谱。然而,由于高内存使用率,大规模训练KGNN具有挑战性。在前向过程中,自动微分引擎(\textsl{e.g.}、TensorFlow/PyTorch)通常需要缓存所有中间激活图,以便在后向过程中计算梯度,这会导致占用大量GPU内存。现有的工作解决了这个问题,利用多GPU分布式框架。尽管如此,当寻求在内存受限的环境中部署KGNN时,这带来了实际挑战,特别是对于行业规模的图。在这里,我们提出了TinyKG,这是一个基于GPU的内存高效的KGNN训练框架,用于推荐任务。具体来说,TinyKG在前向传递中使用精确的激活,同时将激活的量化版本存储在GPU缓冲区中。在反向过程中,这些低精度激活被反量化回全精度张量,以计算梯度。为了减少量化误差,TinyKG应用了一种简单而有效的量化算法来压缩激活,这确保了低方差的无偏性。因此,KGNN的训练内存占用大大减少,精度损失可以忽略不计。为了评估我们的TinyKG的性能,我们对真实世界的数据集进行了全面的实验。我们发现,我们的TinyKG与INT 2量化积极减少激活地图的内存足迹与$7 \times$,只有$2\%$损失的准确性,使我们能够部署KGNN内存受限的设备。

英文摘要:

There has been an explosion of interest in designing various Knowledge Graph Neural Networks (KGNNs), which achieve state-of-the-art performance and provide great explainability for recommendation. The promising performance is mainly resulting from their capability of capturing high-order proximity messages over the knowledge graphs. However, training KGNNs at scale is challenging due to the high memory usage. In the forward pass, the automatic differentiation engines (\textsl{e.g.}, TensorFlow/PyTorch) generally need to cache all intermediate activation maps in order to compute gradients in the backward pass, which leads to a large GPU memory footprint. Existing work solves this problem by utilizing multi-GPU distributed frameworks. Nonetheless, this poses a practical challenge when seeking to deploy KGNNs in memory-constrained environments, especially for industry-scale graphs. Here we present TinyKG, a memory-efficient GPU-based training framework for KGNNs for the tasks of recommendation. Specifically, TinyKG uses exact activations in the forward pass while storing a quantized version of activations in the GPU buffers. During the backward pass, these low-precision activations are dequantized back to full-precision tensors, in order to compute gradients. To reduce the quantization errors, TinyKG applies a simple yet effective quantization algorithm to compress the activations, which ensures unbiasedness with low variance. As such, the training memory footprint of KGNNs is largely reduced with negligible accuracy loss. To evaluate the performance of our TinyKG, we conduct comprehensive experiments on real-world datasets. We found that our TinyKG with INT2 quantization aggressively reduces the memory footprint of activation maps with $7 \times$, only with $2\%$ loss in accuracy, allowing us to deploy KGNNs on memory-constrained devices.

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

↑