这是「每日论文」的第 1 篇,从 1986 年这篇把反向传播写进 Nature 的短文读起。下面只对摘要做完整的中英对照,其余是导读,不逐段翻译全文。
This is the first piece in the Daily Paper series. We start with the 1986 Nature letter that brought back-propagation to a wide scientific audience. Only the abstract is translated in full; the rest is a bilingual reading guide, not a line-by-line translation of the paper.
论文信息 Bibliographic details
- 标题 Title:Learning representations by back-propagating errors
- 作者 Authors:David E. Rumelhart、Geoffrey E. Hinton、Ronald J. Williams
- 单位 Affiliations:加州大学圣地亚哥分校认知科学研究所 Institute for Cognitive Science, University of California, San Diego(Rumelhart、Williams);卡内基-梅隆大学计算机科学系 Department of Computer Science, Carnegie-Mellon University(Hinton,通讯作者 corresponding author)
- 期刊 Journal:Nature 第 323 卷 Vol. 323,第 6088 期 issue 6088,第 533–536 页 pp. 533–536
- 类型 Type:Letter(短文)
- 发表 Published:1986 年 10 月 9 日 9 October 1986(1986 年 5 月 1 日收稿 received 1 May;7 月 31 日接受 accepted 31 July)
- DOI:10.1038/323533a0
以上著录已对照 Nature 官网与原文 PDF 核对。同期更长的技术报告见作者在 Parallel Distributed Processing 第 1 卷第 318–362 页的章节(文中参考文献 4)。
The bibliographic details above were checked against the official Nature page and the original PDF. A longer contemporaneous treatment is the authors’ chapter in Parallel Distributed Processing, Vol. 1, pp. 318–362 (reference 4 in the letter).
摘要 Abstract
下面的英文是这篇 Nature letter 的开篇段落(期刊页面将其标为 Abstract),已对照官网与 PDF 原文逐字核对后引出;中文为对应全译。文末上标 1 指向 Rosenblatt 1961 年的 Principles of Neurodynamics。
The English text below is the opening paragraph of the letter, which the Nature page labels as the Abstract. It is quoted verbatim after checking the official journal page and the PDF. The Chinese that follows is a complete translation. The superscript 1 cites Rosenblatt’s 1961 Principles of Neurodynamics.
We describe a new learning procedure, back-propagation, for networks of neurone-like units. The procedure repeatedly adjusts the weights of the connections in the network so as to minimize a measure of the difference between the actual output vector of the net and the desired output vector. As a result of the weight adjustments, internal ‘hidden’ units which are not part of the input or output come to represent important features of the task domain, and the regularities in the task are captured by the interactions of these units. The ability to create useful new features distinguishes back-propagation from earlier, simpler methods such as the perceptron-convergence procedure1.
我们描述一种用于神经元式单元网络的新学习程序——反向传播(back-propagation)。该程序反复调整网络中各连接的权重,以尽量减小网络实际输出向量与期望输出向量之间的某种差异度量。权重调整的结果是:那些既不属于输入、也不属于输出的内部「隐藏」单元,逐渐表征出任务领域中的重要特征,而任务中的规律则由这些单元之间的相互作用所捕捉。能够创造出有用的新特征,使反向传播有别于感知机收敛程序等更早、更简单的方法1。
背景 Background
单层感知机可以把输入直接连到输出,并用迭代规则缩小实际输出与目标输出的差距;可一旦任务需要中间表征,问题就难了。感知机里也可以放「特征分析器」,但那些单元的输入连接是手工固定的,状态完全由输入决定,并不学习表征。Minsky 与 Papert 在 1969 年的 Perceptrons 中指出:要判断一整串输入是否关于中点对称这类问题,必须有中间层——单个输入单元单独看来,并不提供关于整体是否对称的证据。隐藏单元该在什么情况下激活、该表征什么,并没有现成的目标可抄,这就是所谓的信用分配问题。这篇短文要说明:一套相对简单、用途广泛的程序,已经足以让网络自己构造出合适的内部表征。文中也写明,相近的学习程序已由 David Parker(个人通讯)和 Yann Le Cun(1985 年 Cognitiva 会议,参考文献 3)独立发现。
Single-layer perceptrons can connect inputs directly to outputs and iteratively reduce the gap between actual and desired outputs. Learning becomes harder once a task needs intermediate representations. Perceptrons could include “feature analysers,” but those units had hand-fixed input connections, so their states were fully determined by the input vector: they did not learn representations. In Perceptrons (1969), Minsky and Papert showed that tasks such as detecting whether a whole input vector is symmetrical about its centre require an intermediate layer, because an individual input unit, considered alone, provides no evidence about the symmetry of the entire vector. The learning procedure must decide when hidden units should be active, and what they should represent—the credit-assignment problem. This letter argues that a general-purpose and relatively simple procedure is already powerful enough to construct appropriate internal representations. The authors also note that variants of the procedure were discovered independently by David Parker (personal communication) and by Yann Le Cun (Cognitiva 85; reference 3).
方法 Method
最简单的情形是分层前馈网络:底层是输入单元,中间可以有任意多层,顶层是输出单元。同一层之内、以及从高层连回低层的连接被禁止,但允许跳过中间层。输入向量通过设定输入单元的状态送入网络;随后自下而上逐层用式 (1) 和式 (2) 计算各单元状态。同一层内的单元并行更新,不同层则按顺序进行,直到得到输出。
单元 j 的总输入是连到它的各单元输出的线性组合:
xj = Σi yi wji (1)
偏置(bias)被写成一个恒为 1 的额外输入,其权重等价于符号相反的阈值,并与其他权重同样对待。单元的实值输出是总输入的非线性函数,文中采用 logistic 函数:
yj = 1 / (1 + e−xj) (2)
作者强调,不一定非用这两个函数不可——任何具有有界导数的输入—输出函数都可以;但先做线性加权、再加非线性,会大大简化学习程序。
若有一组固定、有限的输入—输出例子,网络在某一组权重下的总误差定义为
E = ½ Σc Σj (yj,c − dj,c)2 (3)
其中 c 遍历输入—输出对,j 遍历输出单元,y 是实际状态,d 是期望状态。要用梯度下降最小化 E,就要对每个权重求 ∂E/∂w。对每个例子,这个偏导数分两趟计算:前向传播按式 (1)(2) 自下而上确定各层状态;反向传播再用链式法则,把导数从顶层传回底层。对输出单元有 ∂E/∂yj = yj − dj;再对式 (2) 求导,即可得到误差对总输入、进而对更低层状态和权重的影响。这一步骤可逐层向下重复。
权重更新可以每看完一个例子就做一次,也可以先把所有例子的梯度累加起来再改权重。本文报告的实验采用后一种(按整遍扫描更新)。最简单的梯度下降是 Δw = −ε ∂E/∂w。作者指出,它不如利用二阶导数的方法收敛得快,但更简单,也容易用局部的并行计算实现。他们采用的加速形式把当前梯度用来修正权重空间中的「速度」而非位置:
Δw(t) = −ε ∂E/∂w(t) + α Δw(t − 1) (9)
其中 t 每完整扫描一整组例子就加 1,α 是介于 0 与 1 之间的指数衰减因子,用来平衡当前梯度与更早梯度对权重变化的贡献。为打破对称性,训练从很小的随机权重开始。
短文后半还把同一套程序推广到迭代运行的递归网络:把迭代网按时间展开成等价的分层网(图 5),前向时保存各单元输出的历史,并对应对权重的梯度取平均后再更新,从而保持不同层上对应权重相等。这样,网络既可以学习迭代搜索,也可以学习序列结构。
The simplest setting is a layered feed-forward network: a layer of input units at the bottom, any number of intermediate layers, and a layer of output units at the top. Connections within a layer, or from higher to lower layers, are forbidden, but connections may skip intermediate layers. An input vector is presented by setting the states of the input units. States in each layer are then set from the connections coming from lower layers, using equations (1) and (2). Units within a layer are updated in parallel; different layers are updated sequentially, from the bottom up, until the output states are determined.
The total input to unit j is a linear function of the outputs of the units connected to it:
xj = Σi yi wji (1)
A bias is an extra input that is always 1; its weight is equivalent to a threshold of the opposite sign and is treated like the other weights. A unit has a real-valued output that is a non-linear function of its total input. The letter uses the logistic function:
yj = 1 / (1 + e−xj) (2)
The authors note that it is not necessary to use exactly these functions: any input–output function with a bounded derivative will do. Using a linear combination of inputs before the nonlinearity, however, greatly simplifies the learning procedure.
If there is a fixed, finite set of input–output cases, the total error for a given set of weights is
E = ½ Σc Σj (yj,c − dj,c)2 (3)
where c indexes cases (input–output pairs), j indexes output units, y is the actual state of an output unit, and d is its desired state. Minimizing E by gradient descent requires the partial derivative of E with respect to each weight, which is the sum of the per-case derivatives. For a given case those derivatives are computed in two passes. In the forward pass, unit states are determined from lower layers with equations (1) and (2). The backward pass propagates derivatives from the top layer back to the bottom by the chain rule. For an output unit, ∂E/∂yj = yj − dj; differentiating equation (2) then yields the effect of a change in total input, and hence of changes in lower-level states and weights. The same step can be repeated for successively earlier layers.
Weights may be changed after every input–output case, or the derivatives may be accumulated over all cases before a change. The experiments reported in the letter use the second scheme (an update after each sweep). The simplest gradient-descent rule is Δw = −ε ∂E/∂w. This does not converge as rapidly as methods that use second derivatives, but it is much simpler and can be implemented by local computations in parallel. The authors improve it, without sacrificing simplicity and locality, with an acceleration method in which the current gradient modifies the velocity of the point in weight space rather than its position:
Δw(t) = −ε ∂E/∂w(t) + α Δw(t − 1) (9)
Here t is incremented by 1 for each sweep through the whole set of cases, and α is an exponential decay factor between 0 and 1 that balances the current gradient against earlier gradients. Training starts from small random weights, in order to break symmetry.
The later pages map the same procedure onto iteratively run recurrent networks by unfolding them into equivalent layered nets (Fig. 5). The history of each unit’s output must be stored for the backward pass, and the gradients of corresponding (shared) weights are averaged so that those weights remain equal. With these provisos, such nets can learn to perform iterative searches or to learn sequential structures.
结果 Results
短文用两个具体任务说明:隐藏单元能够自己学到输入、输出编码里并未写明的特征。以下数字均来自原文图注或正文,不另补未给出的指标。
The letter illustrates the point with two tasks in which hidden units learn features that are not explicit in the input and output encodings. The figures below are those actually reported in the text or figure captions; no unreported metrics are added.
镜像对称 Mirror symmetry
仅把输入单元直接连到输出单元,做不到「判断一维二值输入是否关于中点对称」。必须有中间层。学习程序找到了一个很简洁的解:只用两个中间单元(图 1)。网络有 6 个输入单元、2 个隐藏单元、1 个输出单元。学习对全部 64 种可能的输入向量扫描了 1,425 遍,每一遍结束后根据累加梯度更新权重。式 (9) 中的参数为 ε = 0.1、α = 0.9;初始权重在 −0.3 与 0.3 之间均匀随机抽取。
这个解的关键性质是:对某一个隐藏单元而言,关于输入向量中点对称的那些权重,大小相等、符号相反。因此,若送入对称图案,两个隐藏单元从输入得到的净输入都是 0;又因为它们带负偏置,两者都关闭。输出单元带正偏置,于是被点亮。中点两侧的权重比为 1 : 2 : 4,从而中点之上可能出现的 8 种图案会送给每个隐藏单元一个互不相同的激活总和,能够精确抵消这个总和的,只有与之对称的下半图案。对所有非对称图案,两个隐藏单元都会从输入得到非零激活;这两个隐藏单元的权重图案相同、符号相反,因此每遇到一个非对称图案,就会有一个隐藏单元打开,并抑制输出单元。图 1 还标出了学到的具体数值:两个隐藏单元的偏置均为 −1.1,输出单元偏置为 6.4,隐藏单元到输出的权重均为 −8.8;输入权重呈现约 14.2、7.2、3.6 及其镜像(与 1 : 2 : 4 的比例一致,个别位置为 7.1 而非 7.2)。
Simply connecting input units to output units cannot detect whether the binary activity levels of a one-dimensional array of input units are symmetrical about the centre point. An intermediate layer is essential. The learning procedure discovered an elegant solution that uses just two intermediate units (Fig. 1). The network has 6 input units, 2 hidden units and 1 output unit. Learning required 1,425 sweeps through the set of 64 possible input vectors, with the weights adjusted from the accumulated gradient after each sweep. The parameters in equation (9) were ε = 0.1 and α = 0.9. The initial weights were random and uniformly distributed between −0.3 and 0.3.
The key property of this solution is that, for a given hidden unit, weights that are symmetric about the middle of the input vector are equal in magnitude and opposite in sign. If a symmetrical pattern is presented, both hidden units receive a net input of 0 from the input units and, because they have a negative bias, both are off. The output unit, having a positive bias, is then on. The weights on each side of the midpoint are in the ratio 1 : 2 : 4. That ensures that each of the eight patterns that can occur above the midpoint sends a unique activation sum to each hidden unit, so the only pattern below the midpoint that can exactly balance this sum is the symmetrical one. For all non-symmetrical patterns, both hidden units receive non-zero activations from the input units. The two hidden units have identical patterns of weights but with opposite signs, so for every non-symmetric pattern one hidden unit comes on and suppresses the output unit. Fig. 1 also shows the learned values: hidden-unit biases of −1.1, an output bias of 6.4, hidden-to-output weights of −8.8, and input weights of about 14.2, 7.2 and 3.6 and their mirror images (consistent with the 1 : 2 : 4 ratio; one counterpart is 7.1 rather than 7.2).
家族树 Family trees
第二个任务是存储两棵同构家族树中的信息(图 2)。信息被写成三元组 〈人物 1〉〈关系〉〈人物 2〉,可能的关系为:父亲、母亲、丈夫、妻子、儿子、女儿、叔舅、姑姨、兄弟、姐妹、侄甥、侄女/外甥女(father, mother, husband, wife, son, daughter, uncle, aunt, brother, sister, nephew, niece)。若网络在给定前两项时能给出第三项,就可以说它「知道」这些三元组。前两项通过激活两个输入单元来编码,网络再激活代表第三项的输出单元以补全命题。全部可能的三元组有 104 个,训练用了其中 100 个。
网络共五层(图 3):底层左侧 24 个输入单元表示「人物 1」,右侧 12 个输入单元表示关系;这两组输入各自全连接到第二层中自己的 6 个单元,后两组单元学着把人物和关系编码成分布式的活动模式;第二层再全连接到中间的 12 个单元,这些单元又连接到倒数第二层的 6 个单元;倒数第二层必须激活正确的输出单元,每个输出单元代表一个「人物 2」。输入和输出在空间上排成两行:英国人在上一行,位置同构的意大利人紧挨在下面。图 3 的例子是 Colin 与关系「有姑姨」(has-aunt),两个正确答案(Colin 有两位姑姨)被标出。
训练共 1,500 遍:前 20 遍使用 ε = 0.005、α = 0.5,其余遍次使用 ε = 0.01、α = 0.9。为了让权重更易解释,每次改权重后把每个权重再减小 0.2%(文中称为 weight-decay)。经过长时间学习,衰减与 ∂E/∂w 达到平衡,因而权重的最终大小可以反映它在减小误差上的用处。为避免网络必须用很大的权重才能把输出推到 1 或 0,作者规定:该亮的输出单元活动值高于 0.8、该灭的低于 0.2 时,误差即视为 0。
第二层里那 6 个编码「人物」的单元学到了输入、输出的独热编码中完全没有写明的特征(图 4)。单元 1 主要区分英国人与意大利人,其余多数单元忽略这一区分,于是一个英国人的表征与其意大利对应者非常相似——网络利用了两棵树的同构来共享结构,因而趋向于从一棵树合理地推广到另一棵。单元 2 编码一个人所属的世代,单元 6 编码其所属的家族分支。正因为这些隐藏特征抓住了任务领域的底层结构,网络对未参加训练的 4 个三元组也能正确推广。
The second task is to store the information in two isomorphic family trees (Fig. 2). The information is expressed as triples of the form 〈person 1〉〈relationship〉〈person 2〉, where the possible relationships are {father, mother, husband, wife, son, daughter, uncle, aunt, brother, sister, nephew, niece}. A layered net can be said to “know” these triples if it can produce the third term of each triple when given the first two. The first two terms are encoded by activating two of the input units, and the network must then complete the proposition by activating the output unit that represents the third term. There are 104 possible triples; the network was trained on 100 of them.
The network has five layers (Fig. 3). The bottom layer has 24 input units on the left for person 1 and 12 input units on the right for the relationship. Each of these two input groups is totally connected to its own group of 6 units in the second layer, which learn to encode people and relationships as distributed patterns of activity. The second layer is totally connected to a central layer of 12 units, and these are connected to a penultimate layer of 6 units. Activity in the penultimate layer must activate the correct output units, each of which stands for a particular person 2. The input and output units are laid out spatially with the English people in one row and the isomorphic Italians immediately below. In the example of Fig. 3, the inputs are Colin and the relationship “has-aunt”; two correct answers are marked, because Colin has two aunts.
The network was trained for 1,500 sweeps, using ε = 0.005 and α = 0.5 for the first 20 sweeps and ε = 0.01 and α = 0.9 for the remaining sweeps. To make the weights easier to interpret, the authors introduced “weight-decay” by decrementing every weight by 0.2% after each weight change. After prolonged learning, the decay was balanced by ∂E/∂w, so the final magnitude of each weight indicates its usefulness in reducing the error. To prevent the network needing large weights to drive the outputs to 1 or 0, the error was considered to be zero if output units that should be on had activities above 0.8 and output units that should be off had activities below 0.2.
The 6 second-layer units that encode people learned features that are not at all explicit in the input and output encodings, which use a separate unit for each person (Fig. 4). Unit 1 is primarily concerned with the distinction between English and Italian, and most of the other units ignore this distinction, so the representation of an English person is very similar to that of their Italian equivalent. The network is making use of the isomorphism between the two family trees to share structure, and will therefore tend to generalize sensibly from one tree to the other. Unit 2 encodes which generation a person belongs to, and unit 6 encodes which branch of the family they come from. Because the hidden features capture the underlying structure of the task domain, the network generalizes correctly to the four triples on which it was not trained.
影响 Impact
这篇只有四页的 letter,把「误差从输出反向传回隐藏层、从而让隐藏单元自己学会有用特征」这件事,写给了当时广泛的科学读者。它并不是反向传播的第一次数学表述——文中已点出 Parker 与 Le Cun 的独立工作;后来的学科史也常把更早的相关推导(例如 Werbos 1974)一并追溯回来——但它和同年 PDP 第 1 卷里那一章,使多层网络重新变得可以训练,也把「表征是学出来的,而不是手工设计的」这一想法推到了台前。今天大规模神经网络的训练,本质上仍是这条思路:用自动微分把输出误差的梯度传回每一层参数。Hinton 此后继续沿着神经网络与表征学习这条线工作;2024 年,他与 Hopfield 因人工神经网络方面的基础性贡献共同获得诺贝尔物理学奖。把这一后来的荣誉记在这里,是为了说明这条线索的分量,并不表示诺奖是单独颁给这一篇 1986 年短文的。
This four-page letter presented, to a broad scientific readership, a procedure that sends error information from the output back to hidden layers, so that hidden units can learn useful features on their own. It was not the first mathematical statement of back-propagation—the letter itself records the independent work of Parker and Le Cun, and later historical accounts also point to earlier related derivations (including Werbos, 1974)—but together with the same authors’ chapter in PDP Volume 1 that year, it made multilayer networks trainable again and put the idea that representations can be learned, rather than hand-designed, in front of a wide audience. Training large neural networks today still follows this idea: automatic differentiation sends the gradient of an output error back to the parameters of each layer. Hinton continued to work along the line of neural networks and representation learning; in 2024 he and Hopfield jointly received the Nobel Prize in Physics for foundational contributions to artificial neural networks. That later honour is noted here to indicate the weight of the lineage, not to suggest that the prize was awarded to this 1986 letter alone.
局限 Limitations
作者自己写出的最明显困难是:误差曲面可能包含局部极小,梯度下降并不能保证找到全局最小。不过他们根据许多任务上的经验写道,网络很少会陷进明显差于全局最小的糟糕局部极小;这种不受欢迎的情形,他们只在「连接数刚刚够完成任务」的网络里遇到过。再多加一些连接,就在权重空间里增加了额外的维度,从而提供绕过那些障碍的路径。
短文结尾还写了一句很清楚的限定:就当时这种形式而言,这套学习程序并不是大脑学习的一个可信模型。但把它用到各种任务上可以看出,有趣的内部表征可以通过权重空间中的梯度下降构造出来;因此,值得继续寻找在生物上更说得通的梯度下降方式。
文中没有讨论的、后来才被广泛正视的困难也包括:当网络加深、单元接近饱和时,式 (2) 这类 sigmoid 的导数会接近 0,层层相乘后早期层的学习信号会变弱(梯度消失);文中的演示规模也很小(对称任务是 64 个图案,家族树是 104 个三元组中的 100 个)。这些并不是对原文的批评,而是读经典时需要记住的上下文:它证明了表征可以被学出来,但并没有一次性解决更深、更大模型的优化与可扩展性问题。
The most obvious drawback, stated by the authors themselves, is that the error surface may contain local minima, so gradient descent is not guaranteed to find a global minimum. Their experience with many tasks, they write, is that the network very rarely gets stuck in poor local minima that are significantly worse than the global minimum. They had only encountered this undesirable behaviour in networks that have just enough connections to perform the task. Adding a few more connections creates extra dimensions in weight-space, and those dimensions provide paths around the barriers that create poor local minima in the lower-dimensional subspaces.
The letter also draws a clear limit at the end: in its then-current form, the procedure is not a plausible model of learning in brains. Applying it to various tasks does show, however, that interesting internal representations can be constructed by gradient descent in weight-space, which suggests that it is worth looking for more biologically plausible ways of doing gradient descent in neural networks.
Difficulties that the letter does not discuss, and that were widely recognised only later, include the following. When a net becomes deeper and units approach saturation, the derivative of a sigmoid such as equation (2) approaches 0, and the learning signal to earlier layers can fade (the vanishing-gradient problem). The demonstrations themselves are also small: 64 patterns for symmetry, and 100 of 104 triples for the family trees. These points are context for reading a classic, not a complaint about the original paper. The letter showed that useful representations can be learned; it did not, in one step, solve the optimisation and scaling problems of much deeper and larger models.
关键词 Key terms
- 反向传播 Back-propagation:把输出误差的梯度沿网络反向传递,用来修改包括隐藏层在内的所有权重。A procedure that sends the gradient of output error backward through the network to adjust all weights, including those of hidden units.
- 隐藏单元 Hidden units:既非输入也非输出、没有直接目标、必须自己学会表征的内部单元。Internal units that are neither input nor output, have no direct targets, and must learn what to represent.
- 内部表征 Internal representation:隐藏单元活动所编码的、对完成任务有用的特征。Features useful for the task, encoded in the activities of hidden units.
- 梯度下降 Gradient descent:沿误差对权重的偏导数方向,迭代减小总误差 E。Iteratively reducing the total error E by following the partial derivatives of the error with respect to the weights.
- 动量 Momentum:式 (9) 中用 α 把当前梯度与此前的权重更新结合起来,以加速学习。In equation (9), the factor α that combines the current gradient with the previous weight change, used to accelerate learning.
- 权重衰减 Weight-decay:每次更新后再把每个权重减小一个很小的比例(文中为 0.2%),使权重大小更能反映其用处。Decrementing every weight by a small fraction after each update (0.2% in this letter), so that a weight’s magnitude better reflects its usefulness.
- 分布式表征 Distributed representation:一个概念由多个单元的活动模式共同编码,而不是由单个单元独占。A concept encoded by a pattern of activity over many units, rather than by a single dedicated unit.
- 局部极小 Local minimum:误差曲面上梯度下降可能停住、但不一定是全局最优的点。A point on the error surface at which gradient descent may stop without having reached the global optimum.
原文链接 Original paper
DOI:https://doi.org/10.1038/323533a0
Nature 页面:https://www.nature.com/articles/323533a0