arXiv:2410.15155cs.LGcs.AR2024-10被引 1

提出异步流水线模拟存内训练的收敛理论,证明其效率接近同步方案。

On the Convergence Theory of Pipeline Gradient-based Analog In-memory Training

  • 设计异步流水线模拟存内训练算法,避免权重复制开销。
  • 证明算法在存在硬件误差时仍能以 $O(\varepsilon^{-2}+\varepsilon^{-1})$ 复杂度收敛。
  • 适合关注存内计算能效与大规模模型训练的系统研究者。

为实现大模型深度神经网络(DNN)的高效节能训练,模拟存内计算(AIMC)展现出巨大潜力。其通过将模型权重保留在内存中,避免训练过程中的数据搬移,显著降低开销。然而,由于权重复制成本高且不准确,数据并行在AIMC加速器上效率较低,亟需探索流水线并行,特别是异步流水线并行,以充分利用所有加速器资源。本文研究了在异步流水线(Analog-SGD-AP)下基于随机梯度下降的收敛理论。尽管已有实证研究,但关于模拟硬件误差如何影响多层DNN训练的理论理解仍不足。此外,异步流水线引入旧权重问题,使更新信号不再是有效梯度。为此,本文分析了Analog-SGD-AP在多层DNN训练中的收敛性,证明其收敛复杂度为 $O(\varepsilon^{-2} + \varepsilon^{-1})$,仅比数字和同步流水线的SGD复杂度多出非主导项 $O(\varepsilon^{-1})$,表明异步流水线可在重叠计算的同时几乎无代价地提升存内训练效率。

原文摘要 · Abstract (English)

Aiming to accelerate the training of large deep neural networks (DNN) in an energy-efficient way, analog in-memory computing (AIMC) emerges as a solution with immense potential. AIMC accelerator keeps model weights in memory without moving them from memory to processors during training, reducing overhead dramatically. Despite its efficiency, scaling up AIMC systems presents significant challenges. Since weight copying is expensive and inaccurate, data parallelism is less efficient on AIMC accelerators. It necessitates the exploration of pipeline parallelism, particularly asynchronous pipeline parallelism, which utilizes all available accelerators during the training process. This paper examines the convergence theory of stochastic gradient descent on AIMC hardware with an asynchronous pipeline (Analog-SGD-AP). Although there is empirical exploration of AIMC accelerators, the theoretical understanding of how analog hardware imperfections in weight updates affect the training of multi-layer DNN models remains underexplored. Furthermore, the asynchronous pipeline parallelism results in stale weights issues, which render the update signals no longer valid gradients. To close the gap, this paper investigates the convergence properties of Analog-SGD-AP on multi-layer DNN training. We show that the Analog-SGD-AP converges with iteration complexity $O(\varepsilon^{-2}+\varepsilon^{-1})$ despite the aforementioned issues, which matches the complexities of digital SGD and Analog SGD with synchronous pipeline, except the non-dominant term $O(\varepsilon^{-1})$. It implies that AIMC training benefits from asynchronous pipelining almost for free compared with the synchronous pipeline by overlapping computation.

存内计算异步训练收敛理论

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。