arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1905.12334cs.LGstat.ML
收藏

8位浮点混合精度训练

Mixed Precision Training With 8-bit Floating Point

Intel Labs(英特尔研究院)

Naveen Mellempudi, Sudarshan Srinivasan, Dipankar Das, Bharat Kaul

摘要:

深度神经网络的降低精度计算是解决模型大小指数增长导致的计算差距扩大的关键领域之一。近年来,深度学习训练已基本迁移到16位精度,在性能和能效方面取得了显着进步。然而,由于反向传播的更高精度和动态范围要求,以8位精度训练DNN的尝试遇到了重大挑战。在本文中,我们提出了一种使用8位浮点表示权值、激活、错误和梯度来训练深度神经网络的方法。除了降低计算精度外,我们还将权重主副本的精度要求从32位降低到16位。我们在多个数据集(imagenet-1K,WMT 16)和更广泛的工作负载(Resnet-18/34/50,GNMT,Transformer)上展示了最先进的准确性。我们提出了一种增强的损失缩放方法,以增加减少低于正常范围的8位浮点改善错误传播。我们还研究了量化噪声对泛化的影响,并提出了一种随机舍入技术来解决梯度噪声。作为应用所有这些技术的结果,我们报告的验证精度略高于全精度基线。

英文摘要:

Reduced precision computation for deep neural networks is one of the key areas addressing the widening compute gap driven by an exponential growth in model size. In recent years, deep learning training has largely migrated to 16-bit precision, with significant gains in performance and energy efficiency. However, attempts to train DNNs at 8-bit precision have met with significant challenges because of the higher precision and dynamic range requirements of back-propagation. In this paper, we propose a method to train deep neural networks using 8-bit floating point representation for weights, activations, errors, and gradients. In addition to reducing compute precision, we also reduced the precision requirements for the master copy of weights from 32-bit to 16-bit. We demonstrate state-of-the-art accuracy across multiple data sets (imagenet-1K, WMT16) and a broader set of workloads (Resnet-18/34/50, GNMT, Transformer) than previously reported. We propose an enhanced loss scaling method to augment the reduced subnormal range of 8-bit floating point for improved error propagation. We also examine the impact of quantization noise on generalization and propose a stochastic rounding technique to address gradient noise. As a result of applying all these techniques, we report slightly higher validation accuracy compared to full precision baseline.

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

↑