[论文解读] Randomness In Neural Network Training: Characterizing The Impact of Tooling
本文研究了工具链——特别是硬件和软件选择——如何在深度神经网络训练中引入非确定性,揭示了尽管对主要指标影响甚微,实现层面的噪声仍显著影响模型稳定性与子群表现。研究显示,确保确定性会带来高昂且与架构和硬件相关的训练开销(最高达746%),凸显了在安全关键型人工智能应用中实现确定性工具链的迫切需求。
The quest for determinism in machine learning has disproportionately focused on characterizing the impact of noise introduced by algorithmic design choices. In this work, we address a less well understood and studied question: how does our choice of tooling introduce randomness to deep neural network training. We conduct large scale experiments across different types of hardware, accelerators, state of art networks, and open-source datasets, to characterize how tooling choices contribute to the level of non-determinism in a system, the impact of said non-determinism, and the cost of eliminating different sources of noise. Our findings are surprising, and suggest that the impact of non-determinism in nuanced. While top-line metrics such as top-1 accuracy are not noticeably impacted, model performance on certain parts of the data distribution is far more sensitive to the introduction of randomness. Our results suggest that deterministic tooling is critical for AI safety. However, we also find that the cost of ensuring determinism varies dramatically between neural network architectures and hardware types, e.g., with overhead up to $746\%$, $241\%$, and $196\%$ on a spectrum of widely used GPU accelerator architectures, relative to non-deterministic training. The source code used in this paper is available at https://github.com/usyd-fsalab/NeuralNetworkRandomness.
研究动机与目标
- 探究工具链(硬件与软件堆栈)对深度神经网络训练中非确定性的影响。
- 量化实现层面噪声对模型稳定性、子群表现与公平性的影响。
- 测量在不同硬件与模型架构下实现确定性所需的计算成本。
- 评估仅控制算法层面随机性是否足以实现可靠模型训练。
- 评估在确定性训练中,模型稳定性、公平性与训练效率之间的权衡。
提出的方法
- 在多种硬件类型(如V100 GPU)、加速器及广泛使用的深度学习模型(如ResNet-18、ResNet-50)上开展大规模实验。
- 隔离并评估算法噪声(如随机初始化、数据打乱)与实现噪声(硬件+软件堆栈)的贡献。
- 通过准确率标准差、预测变化率以及训练权重之间的L2距离等指标衡量模型稳定性。
- 通过分析多次训练运行中各类别与子群表现的方差,评估公平性影响。
- 使用软件补丁与确定性硬件配置,量化实现确定性带来的训练速度开销。
- 采用标准化数据集(CIFAR-10、CIFAR-100、ImageNet)与开源框架(PyTorch、TensorFlow、JAX),以确保可复现性与广泛适用性。
实验结果
研究问题
- RQ1硬件与软件工具链的选择在多大程度上导致了深度神经网络训练中的非确定性?
- RQ2即使主要指标保持稳定,实现层面的噪声在多大程度上影响了模型稳定性与子群表现?
- RQ3在不同神经网络架构与硬件平台下,实现完全确定性的计算成本是多少?
- RQ4仅控制算法层面的随机性(如随机种子)是否足以降低模型不确定性?
- RQ5工具链中的非确定性如何放大对代表性不足子群的性能偏差与方差?
主要发现
- 硬件与软件工具链带来的实现噪声显著导致模型不稳定,其预测变化率与权重方差程度与算法噪声相当。
- 主要指标(如top-1准确率)在不同训练运行间变化极小,但各类别与子群表现对训练随机性表现出高度敏感性。
- 非确定性显著增加了对代表性不足子群的性能方差,加剧了敏感AI应用中的公平性风险。
- 确保确定性的成本差异极大,某些GPU架构上的训练开销最高可达746%,具体取决于模型与硬件。
- 仅控制算法噪声是不够的;实现层面的噪声仍是不确定性的重要来源,必须实现全栈确定性。
- 确定性工具链对AI安全至关重要,尤其在医疗、信用评分与自动驾驶等高风险领域,子群性能的方差可能导致有害偏见。
阅读本论文
在 Nubint 阅读器中打开原文,边读边就任意段落提问。
在 Nubint 中阅读本论文本解读由 AI 根据论文原文生成,引用前请核对原文。