图2-9 该示例神经网络等价于单层神经网络This example neuralnetwork is equivalent to a single layer neural network
请记住,当隐藏节点具有线性激活函数时,隐藏层实际上是无效的。
Keep in mind that the hidden layer becomesineffective when the hidden nodes have linear activation functions.
然而,输出节点可以、有时也必须采用线性激活函数。
However, the output nodes may, andsometimes must, employ linear activation functions.
神经网络的有监督学习(Supervised Learning of a Neural Network)
本节介绍神经网络监督学习的概念和过程。
This section introduces the concepts andprocess of supervised learning of the neural network.
在第1章的“机器学习”我们对此概念有所提及。
It is addressed in the “Types of MachineLearning” section in Chapter 1.
在许多训练方法中,本书只包括有监督学习的内容。
Of the many training methods, this bookcovers only supervised learning.
因此,针对神经网络也只讨论有监督学习。
Therefore, only supervised learning isdiscussed for the neural network as well.
在图中的描述里,神经网络的监督学习按以下步骤进行:
In the big picture, supervised learning ofthe neural network proceeds in the following steps:
用适当的值初始化权重。
Initialize the weights with adequatevalues.
从训练数据中获取“输入”,对应的格式为{输入,正确输出},并将其输入神经网络。
Take the“input” from the training data, which is formatted as { input, correct output}, and enter it into the neural network.
从神经网络获得输出,并与正确的输出比较计算误差。
Obtain the output from the neural networkand calculate the error from the correct output.
调整权重以减小误差。
Adjust the weights to reduce the error.
对所有训练数据重复步骤2-3。
Repeat Steps 2-3 for all training data.
以上步骤基本上与“机器学习”的监督学习过程相同。
These steps are basically identical to thesupervised learning process of the “Types of Machine Learning” section.
因为监督学习的训练是一个修改模型以减小正确输出与模型输出之间的差异的过程。
This makes sense because the training ofsupervised learning is a process that modifies the model to reduce thedifference between the correct output and model’s output.
唯一的区别是,模型的修改变成了神经网络的权值变化。
The only difference is that themodification of the model becomes the changes in weights for the neuralnetwork.
图2-10说明了迄今为止已经解释过的有监督学习的概念。
Figure 2-10 illustrates the concept ofsupervised learning that has been explained so far.
图2-10 有监督学习的概念模型图The concept of supervisedlearning
这将有助于你清楚地理解前面所描述的步骤。
This will help you clearly understand thesteps described previously.
单层神经网络的训练:增量规则(Training of a Single-Layer Neural Network: Delta Rule)
如前所述,神经网络以加权的形式存储信息。
As previously addressed, the neural networkstores information in the form of weights.
因此,为了训练具有新信息的神经网络,应该相应地改变权重。
Therefore, in order to train the neuralnetwork with new information, the weights should be changed accordingly.
——本文译自Phil Kim所著的《Matlab Deep Learning》