揭示深度学习中梯度的数学本质,解释为何非光滑函数仍可有效训练。
Mathematical analysis of the gradients in deep learning
- 通过广义梯度理论,精确描述全连接神经网络的梯度机制。
- 证明广义梯度是代价泛函的极限Fréchet次梯度,且在可微区域等于标准梯度。
- 为PyTorch/TensorFlow等框架的梯度计算提供理论支撑,适合研究者与工程师参考。
深度学习算法通常由一类深度人工神经网络(ANNs)通过随机梯度下降(SGD)方法训练而成,广泛应用于科学、工业及日常生活。基本形式下,ANN可视为仿射线性函数与多维激活函数的复合函数。其中最常用的激活函数是修正线性单元(ReLU),定义为 $\mathbb{R} \ni x \mapsto \max\{ x, 0 \} \in \mathbb{R}$。然而,ReLU 不可微,通常导致监督学习问题中的代价函数缺乏光滑性。尽管如此,深度学习实践者仍使用基于广义梯度的SGD方法,这在 { t TensorFlow} 与 { t PyTorch} 等库中被实现。本文揭示了全连接前馈神经网络训练中广义梯度的精确数学描述,并对其进行分析。我们提出一种唯一确定广义梯度函数的逼近过程,证明广义梯度是代价泛函的极限Fréchet次梯度,并进一步表明:在代价泛函连续可微的任意开集上,广义梯度必等于标准梯度。
原文摘要 · Abstract (English)
Deep learning algorithms -- typically consisting of a class of deep artificial neural networks (ANNs) trained by a stochastic gradient descent (SGD) optimization method -- are nowadays an integral part in many areas of science, industry, and also our day to day life. Roughly speaking, in their most basic form, ANNs can be regarded as functions that consist of a series of compositions of affine-linear functions with multidimensional versions of so-called activation functions. One of the most popular of such activation functions is the rectified linear unit (ReLU) function $\mathbb{R} \ni x \mapsto \max\{ x, 0 \} \in \mathbb{R}$. The ReLU function is, however, not differentiable and, typically, this lack of regularity transfers to the cost function of the supervised learning problem under consideration. Regardless of this lack of differentiability issue, deep learning practioners apply SGD methods based on suitably generalized gradients in standard deep learning libraries like {\sc TensorFlow} or {\sc Pytorch}. In this work we reveal an accurate and concise mathematical description of such generalized gradients in the training of deep fully-connected feedforward ANNs and we also study the resulting generalized gradient function analytically. Specifically, we provide an appropriate approximation procedure that uniquely describes the generalized gradient function, we prove that the generalized gradients are limiting Fréchet subgradients of the cost functional, and we conclude that the generalized gradients must coincide with the standard gradient of the cost functional on every open sets on which the cost functional is continuously differentiable.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。