neural network ๐ถ - kangwoncs.kangwon.ac.kr/.../05_neural_network.pdfย ยท 2016-06-17ย ยท ๐ถ46...
TRANSCRIPT
๐ ๐๐๐๐ ๐ถ
Machine Learning
๐ ๐๐๐๐ ๐ถ
2015.06.27.
Neural Network
๐ ๐๐๐๐ ๐ถ 2
Neural Network
โข Human Neuron
โข Perceptron
โข Artificial Neural Network
โข Feed-forward Neural Nets.
โข Gradient
โข Least Square Error
โข Cross Entropy
โข Back-propagation
โข Conclusion
๐ ๐๐๐๐ ๐ถ 3
Issues
โข Inceptionism of Google
๐ ๐๐๐๐ ๐ถ 4
Issues
โข Inceptionism of Google
๐ ๐๐๐๐ ๐ถ 5
Issues
โข Inceptionism of Google
๐ ๐๐๐๐ ๐ถ 6
Issues
โข Inceptionism of Google
๐ ๐๐๐๐ ๐ถ 7
Human Neuron
๐ ๐๐๐๐ ๐ถ 8
Human Neuron
Input WeightSum
ActivationFunction
Output
Defined vectors
This is calculated as the weighted sum of the input vectors
The input vectors are transformed into an output signal via a activation function
An output signal is [0 or 1] or real value number (between 0 to 1)
๐ ๐๐๐๐ ๐ถ 9
Perceptron
Raw data Input vector Weight ActivationFunction
Output
๐ ๐๐๐๐ ๐ถ 10
Perceptron
โข Inputs are features
โข Each feature has weight
โข Sum is the activationโข Positive: 1
โข Negative: 0
๐ง = ๐๐๐ค๐ โ ๐ฅ๐๐ฆ = ๐ ๐ง ,Activation is
Step function Sigmoid function Gaussian function
๐ ๐๐๐๐ ๐ถ 11
Perceptron & Logistic Regression
๐ฅ๐
๐ฅ ๐ค
โฆ
Logistic RegressionPerceptron
Parametric problem
๐ ๐๐๐๐ ๐ถ 12
Perceptron learning rule
โข On-line, error (mistake) driven learning
โข Rosenblatt (1959, a psychologist)โข suggested that when a target output value is provided for
a single neuron with fixed input, it can incrementally change weights and learn to produce the output using the Perceptron learning rule
โข Perceptron == Linear Threshold Unit
๐ง = ๐๐๐ค๐
๐ โ ๐ฅ๐
= ๐ค๐๐ฅ
๐ ๐๐๐๐ ๐ถ 13
Perceptron learning rule
๐ ๐๐๐๐ ๐ถ 14
Geometric View
๐ ๐๐๐๐ ๐ถ 15
Geometric View
๐ ๐๐๐๐ ๐ถ 16
Geometric View
๐ ๐๐๐๐ ๐ถ 17
Geometric View
๐ ๐๐๐๐ ๐ถ 18
Deriving the delta rule
๐ ๐๐๐๐ ๐ถ 19
Perceptron Example
-1
x1
x2
Raw data Input vector
?
Weight ActivationFunction
0
Output
X1 X2 Output
0 0 0
0 1 0
1 0 0
1 1 1
For AND
๐ ๐๐๐๐ ๐ถ 20
Perceptron Example
X1 X2 Output
0 0 0
0 1 0
1 0 0
1 1 1
For AND
X0 X1 X2 Summation Output
-1 0 0 (-1*0.5) + (0*0.4) + (0*0.4) = -0.5 0
-1 0 1 (-1*0.5) + (0*0.4) + (1*0.4) = -0.1 0
-1 1 0 (-1*0.5) + (1*0.4) + (0*0.4) = -0.1 0
-1 1 1 (-1*0.5) + (1*0.4) + (1*0.4) = 0.3 1
๐ ๐๐๐๐ ๐ถ 21
Limitation of a Perceptron: Linear separable
๐ ๐๐๐๐ ๐ถ 22
Decision surface of a perceptron
โข Perceptron is able to represent some useful functions
โข AND(x1, x2) choose weights w0=-1.5, w1=1, w2=1
โข But functions that are not linearly separable(e.g. XOR) are not representable
๐ ๐๐๐๐ ๐ถ 23
Perceptrons...
โข Perceptron: Mistake Bound Theorem
โข Dual Perceptron
โข Voted-Perceptron
โข Regularization: Average Perceptron
โข Passive-Aggressive Algorithm
โข Unrealizable Case
๐ ๐๐๐๐ ๐ถ 24
We need Non-linearly separable
StructureTypes of
Decision Regions
Exclusive-OR
Problem
Classes with
Meshed regions
Most General
Region Shapes
Single-Layer
Two-Layer
Three-Layer
Half Plane
Bounded By
Hyperplane
Convex Open
Or
Closed Regions
Arbitrary
(Complexity
Limited by No.
of Nodes)
A
AB
B
A
AB
B
A
AB
B
BA
BA
BA
๐ ๐๐๐๐ ๐ถ 25
Artificial Neural Network
Raw data Input vector Weight ActivationFunction
Output
Add units!!Layer
๐ ๐๐๐๐ ๐ถ 26
Artificial Neural Network
Raw data Input layer
Weight
ActivationFunction
Hiddenlayer
ActivationFunction
Outputlayer
Weight
๐ ๐๐๐๐ ๐ถ 27
Artificial Neural Network
๐ง๐ = ๐ฆ1 ๐ด๐๐ท ๐๐๐ ๐ฆ2 = ๐ฅ1 ๐๐ ๐ฅ2 ๐ด๐๐ท ๐๐๐ ๐ฅ1 ๐ด๐๐ท ๐ฅ2= ๐ฅ1 ๐๐๐ ๐ฅ2
๊ทธ๋ฆผ์ถ์ฒ: Pattern Classification
Solve a XOR!!
๐ ๐๐๐๐ ๐ถ 28
Artificial Neural Network
Input value
Emission value
Weight
Activation function
๊ทธ๋ฆผ์ถ์ฒ: Pattern Classification
Combination of each states
๐ ๐๐๐๐ ๐ถ 29
Feed-forward Neural Nets.
โข Net activation (scalar, hidden unit โ๐โ)
โข input-to-hidden
1) ๐๐๐ก๐ =
๐=1
๐
๐ฅ๐๐ค๐๐ + ๐ค๐0 =
๐=0
๐
๐ฅ๐๐ค๐๐ โก ๐ค๐๐๐ฅ
โข ๐: ๐๐๐๐ข๐ก ๐๐๐ฆ๐๐, ๐: โ๐๐๐๐๐ ๐๐๐ฆ๐๐, ๐ค๐๐: ๐ โ ๐์ ๐ค๐๐๐โ๐ก
โข ๐ฅ: ๐ข๐๐๐ก๐ (= ๐๐๐๐), ๐ค:๐ค๐๐๐โ๐ก
โข ๐ฅ0 = 1, ๐ค0 = 0~1 (๐๐๐๐ ๐ฃ๐๐๐ข๐)
๐ ๐๐๐๐ ๐ถ 30
Feed-forward Neural Nets.
โข Activation function (non-linear function)
2) ๐ฆ๐ = ๐ ๐๐๐ก๐
โข โ ๐ ๐๐ = ๐ ๐๐๐๐ข๐ ํํ ํจ์ (๐)
3) ๐ ๐๐๐ก = ๐ ๐๐ ๐๐๐ก โก 1, ๐๐๐ก โฅ 0โ1, ๐๐๐ก < 0
: ๐๐๐ก๐๐ฃ๐๐ก๐๐๐ ๐๐ข๐๐๐ก๐๐๐
๐ ๐๐๐๐ ๐ถ 31
Feed-forward Neural Nets.
โข Activation functions
logistic sigmoid
๐ ๐๐๐ก =1
1 + exp โ๐๐๐ก
๐๐ ๐๐๐ก
๐๐๐๐ก= ๐ ๐๐๐ก 1 โ ๐ ๐๐๐ก
tanh
๐ ๐๐๐ก = tanh ๐๐๐ก =๐๐ฅ + ๐โ๐ฅ
๐๐ฅ + ๐โ๐ฅ
๐ก๐๐โ` ๐๐๐ก = 1 โ ๐ก๐๐โ` ๐๐๐ก2
hard tanh
๐ ๐๐๐ก = ๐ป๐๐๐Tanh ๐๐๐ก
๐ป๐๐๐Tanh ๐๐๐ก =
โ1 ๐๐ ๐ฅ < โ1
๐ฅ ๐๐ โ 1 โค ๐ฅ โค 1
1 ๐๐ ๐ฅ > 1
๊ทธ๋ฆผ์ถ์ฒ: Torch7 Documentation
๐ ๐๐๐๐ ๐ถ 32
Feed-forward Neural Nets.
โข Activation functions
SoftSign๐ ๐๐๐ก = ๐๐๐๐ก๐๐๐๐(๐๐๐ก)
๐๐๐๐ก๐๐๐๐ ๐๐๐ก =๐
1 + ๐
SoftMax๐ ๐๐๐ก = ๐๐๐๐ก๐๐๐ฅ(๐๐๐ก)
=exp ๐๐๐ก๐ โ ๐ โ๐๐๐ก
๐ exp(๐๐๐ก๐ โ ๐ โ๐๐๐ก)
, ๐ โ๐๐๐ก = max๐
(๐๐๐ก๐)
Rectifier
๐ ๐๐๐ก = ๐๐๐๐ก (๐๐๐ก)
๐๐๐๐ก ๐๐๐ก = max(0, ๐๐๐ก)
๐๐๐ฅ 0, ๐๐๐ก =๐ฅ ๐๐ ๐ฅ > 0
0.01๐ฅ ๐๐กโ๐๐๐ค๐๐ ๐
๊ทธ๋ฆผ์ถ์ฒ: Wikipedia
๐ ๐๐๐๐ ๐ถ 33
Feed-forward Neural Nets.
โข output layer (output unit โ๐โ)
โข hidden-to-output
4) ๐๐๐ก๐ =
๐=1
๐+1
๐ฆ๐๐ค๐๐ + ๐ค๐0 =
๐=0
๐๐ป
๐ฆ๐๐ค๐๐ = ๐ค๐๐๐ฆ
โข ๐: ๐๐ข๐ก๐๐ข๐ก ๐๐๐ฆ๐๐, ๐๐ป: ๐กโ๐ ๐๐ข๐๐๐๐ ๐๐ โ๐๐๐๐๐ ๐ข๐๐๐ก๐
โข ๐ฆ0 = 1 ๐๐๐๐ ๐ฃ๐๐๐ข๐ ๐๐ โ๐๐๐๐๐
โข output unitโข ์ฌ๊ธฐ๋ ๐ ๐๐ . ์ ์ฉ
5) ๐ง๐ = ๐(๐๐๐ก๐)
๐ ๐๐๐๐ ๐ถ 34
Gradient
โข ๊ฐ ๋ณ์๋ก์ ์ผ์ฐจ ํธ๋ฏธ๋ถ ๊ฐ์ผ๋ก ๊ตฌ์ฑ๋๋ ๋ฒกํฐโข ๋ฒกํฐ: ๐(. )์ ๊ฐ์ด ๊ฐํ๋ฅธ ์ชฝ์ ๋ฐฉํฅ์ ๋ํ๋
โข ๋ฒกํฐ์ ํฌ๊ธฐ: ๋ฒกํฐ ์ฆ๊ฐ์ ๊ธฐ์ธ๊ธฐ๋ฅผ ๋ํ๋
โข ์ด๋ค ๋ค๋ณ์ ํจ์ ๐(๐ฅ1, ๐ฅ2, โฆ , ๐ฅ๐)๊ฐ ์์ ๋, ๐์gradient๋ ๋ค์๊ณผ ๊ฐ์
๐ป๐ = (๐๐
๐๐ฅ1,๐๐
๐๐ฅ2, โฆ ,
๐๐
๐๐ฅ๐)
โข Gradient๋ฅผ ์ด์ฉํ ๋ค๋ณ์ scalar ํจ์ ๐์ ์ ๐๐์ ๊ทผ์ฒ์์์ ์ ํ ๊ทผ์ฌ์ (using Taylor expansion)
๐ ๐ = ๐ ๐๐ + ๐ป๐ ๐๐ ๐ โ ๐๐ + ๐( ๐ โ ๐๐ )
๐ ๐๐๐๐ ๐ถ 35
Gradient Descent
โข Formula
๐ ๐+1 = ๐๐ โ ๐๐๐ป๐ ๐๐ , ๐ โฅ 0
๐๐: ๐๐๐๐๐๐๐๐ ๐๐๐ก๐
โข Algorithm
๐๐๐๐๐ ๐๐๐๐ก ๐, ๐กโ๐๐๐ โ๐๐๐ ๐, ๐๐ ๐ ๐ โ ๐ + 1
๐ โ ๐ โ ๐๐ป๐ ๐๐๐๐๐๐ ๐๐ป๐ ๐ < 0
๐๐๐๐๐๐ ๐๐๐๐
์ถ์ฒ: wikipedia
๐ ๐๐๐๐ ๐ถ 36
Least Square Error
โข ์ด๋ค ๋ชจ๋ธ์ ํ๋ผ๋ฏธํฐ๋ฅผ ์ถ์ ํ ๋ sample data์train data ๊ฐ, ๐๐๐ ๐๐๐ข๐๐2์ ํฉ์ด ์ต์๊ฐ ๋๋๋ก ํ๋ ๊ฒ
๐1
๐2
๐3
๐4
๐5
ใ ก์ ๋ต๋ชจ๋ธใ ก์ถ์ ๋ชจ๋ธ
์ ๋ต๋ฐ์ดํฐ์ถ์ ๋ฐ์ดํฐ
Residual: ๐(= ํ)
min ๐ =
๐
(๐ฆ๐ โ ๐ฆ๐)
๐ ๐๐๐๐ ๐ถ 37
Least Square Error
โข ์ด๋ค ์ถ์ ๋ ๋ชจ๋ธ ๐ ๐ฅ = ๐๐ฅ + ๐ ์ธ ๊ฒฝ์ฐ
โข ๐๐๐ ๐๐๐ข๐๐์ ๋ํด์ ์ดํด๋ณด๋ฉด ๋ค์๊ณผ ๊ฐ์
๐๐๐ ๐๐๐ข๐๐๐ = ๐ฆ๐ โ ๐ ๐ฅ๐
โข ์ฆ, LSE์ ํ๋ผ๋ฏธํฐ๋ฅผ ์ถ์ ํ๋ค๋ ๊ฒ์ min(๐๐๐ ๐๐๐ข๐๐2)์๊ตฌํ๋ค๋ ๊ฒ
โข ๋ฐ๋ผ์ ์์์ผ๋ก ํํํ๋ฉด
๐=1
๐
๐2 =
๐=1
๐
๐ฆ๐ โ ๐ ๐ฅ๐2
โข ์์ ๋ชจ๋ธ, ์ฆ ์ง์ ์ธ ๊ฒฝ์ฐ
๐=1
๐
๐2 =
๐=1
๐
๐ฆ๐ โ ๐๐ฅ๐ + ๐๐2
โข ๋ฐ๋ผ์ ๐2์ ์ต์ํ ํ๋ ํ๋ผ๋ฏธํฐ a, b๋ฅผ ๊ฒฐ์
๐ ๐๐๐๐ ๐ถ 38
Back-propagation
โข Delta Rule์ ๊ธฐ๋ฐํ ๋ฐฉ๋ฒโข LSE๋ฅผ ๊ธฐ๋ฐ์ผ๋ก target(t)๊ณผ output(z)์ ์ค์ฐจ ์ ๊ณฑ์ ์ต์๋ก
ํจ
โข Credit assignment problemโข NN์ Hidden layer์์ ์ ๋ต์ ํ์ธํ ๋ฐฉ๋ฒ ์์
โข ๋ฐ๋ผ์ Back Prop.์ ์ด์ฉํ์ฌ weight ๊ฐฑ์
output(z) : target(t)
compare์ฐจ์ด๋ฐ์: error(=scalar function)
โดweight๋ค์์ด error ๊ฐ์์ค์ด๋๋ก์กฐ์ weight๋ํจํด๋ณ๋กํ์ต
weight
๐ ๐๐๐๐ ๐ถ 39
Back-propagation
โข ์์ ํจํด์ ๋ํ ํ์ต๋ฅ (training error)
9) ๐ฝ ๐ค โก1
2
๐=1
๐
๐ก๐ โ ๐ง๐2 =
1
2๐ก โ ๐ง 2
โข ๐ก๐: ์ ๋ต(target), ๐ง๐: net ์ถ๋ ฅ(train result) output
โข ๐ก, ๐ง: ๊ธธ์ด๊ฐ c์ธ target, net์ ์ถ๋ ฅ โvectorโ
โข ๐ค: net์ ๋ชจ๋ ๊ฐ์ค์น (training error)
โข Back prop. training rule
โข gradient descent์ ๊ธฐ๋ฐ (init: random weight)
10) โ๐ค = โ๐๐๐ฝ
๐๐ค, ๐๐ 11) โ๐ค๐๐ = โ๐
๐๐ฝ
๐๐ค๐๐
โข ๐: ํ์ต๋ฅ (training error) ๊ฐ์ค์น ๋ณํ์ ์๋์ ํฌ๊ธฐ
โข ๋ฐ๋ณต m๋ฒ์ผ ๋, gradient descent ๊ธฐ์คํจ์(๐ฝ(๐ค))๋ฅผ ๋ฎ์ถ๋๋ก ์์ง์
12) ๐ค๐+1 = ๐ค๐ + โ๐ค๐
๐ ๐๐๐๐ ๐ถ 40
Back-propagation
โข Back Prop. of Hidden-to-Output
โข ๐ก๐๐๐๐๐๐๐ ๐๐๐๐๐ "๐ค๐๐" ์ต์ ํ ํ์ (โด ๐ฝ ๐ค ๋ฅผ๐ค๋ก ์ต์ ํ)
โข ๐ค๐๐๊ฐ ๐ค๐๐์ ์ธ์ฐ์ ์ผ๋ก ์ข ์๋์ง ์์
โข ์ฆ, ๐ฝ๋ ๐๐๐ก์ ์์กด์ : (9)1
2๐ก โ ๐ง 2, (5) ๐ง๐ = ๐(๐๐๐ก๐)
โข ๐๐๐ก์ ๐ค์ ์์กด์ : (4) ๐๐๐ก๐ = ๐ค๐๐๐ฆ
โข ๋ฐ๋ผ์ chain rule ์ ์ฉ ๊ฐ๋ฅ
I J K
โ๐๐๐๐๐ โ ๐ก๐ โ ๐๐ข๐ก์๋ํ๐ก๐๐๐๐๐๐๐ ๐๐๐๐๐ "๐ค๐๐"๋ฅผ๊ณ์ฐ
๐ ๐๐๐๐ ๐ถ 41
Back-propagation
โข ๐ค๐๐์ต์ ํ์ ๋ํ ๐๐๐๐ก๐์ chain rule
13)๐๐ฝ
๐๐ค๐๐=
๐๐ฝ
๐๐๐๐ก๐
๐๐๐๐ก๐๐๐ค๐๐
โข unit k์ โ๐ฟ๐โ: Delta rule [(๐ก๐ โ ๐ง๐)]
โข unit์ net ํ์ฑํ์ ๋ฐ๋ผ ์ ๋ฐ์ ์๋ฌ๊ฐ ์ด๋ป๊ฒ ๋ฐ๋๋์ง ๋ฌ์ฌ(LSE, ์ค์ฐจ)
14) ๐๐๐๐ก๐: โ๐ฟ๐ =๐๐ฝ
๐๐๐๐ก๐โข ํ์ฑํจ์ ๐(. )๊ฐ ๋ฏธ๋ถ ๊ฐ๋ฅํ๋ค ๊ฐ์ : (5) ๐ง๐ = ๐(๐๐๐ก๐),
9 ๐ฝ =1
2 ๐=1๐ ๐ก๐ โ ๐ง๐
2์ ๊ธฐ๋ฐํ์ฌ, ์ถ๋ ฅ unit์ ๋ํ ๐ฟ๐๋ ๋ค
์๊ณผ ๊ฐ์
15) ๐ฟ๐ = โ๐๐ฝ
๐๐๐๐ก๐= โ
๐๐ฝ
๐๐ง๐
๐๐ง๐๐๐๐๐ก๐
= ๐ก๐ โ ๐ง๐ ๐โฒ(๐๐๐ก๐)
๐ ๐๐๐๐ ๐ถ 42
Back-propagation
โข ๐ค๐๐์ต์ ํ์ ๋ํ ๐๐๐๐ก๐์ chain rule
13)๐๐ฝ
๐๐ค๐๐=
๐๐ฝ
๐๐๐๐ก๐
๐๐๐๐ก๐๐๐ค๐๐
โข ์ฐ๋ณ์ ๋ง์ง๋ง ๋ฏธ๋ถ์์ (4) ๐๐๐ก๐ = ๐ค๐๐๐ฆ๋ฅผ ์ด์ฉ
๐๐๐๐ก๐๐๐ค๐๐
= ๐ฆ๐
โข Hidden-to-output์ weight๋ฅผ ์ํ ํ์ต๋ฃฐ17) โ๐ค๐๐ = ๐ก๐ โ ๐ง๐ ๐โฒ ๐๐๐ก๐ ๐ฆ๐
โดoutput unit์ด ์ ํ์ผ ๊ฒฝ์ฐโข ์ฆ, ๐ ๐๐๐ก๐ = ๐๐๐ก๐, ๐
โฒ ๐๐๐ก๐ = 1
โข โ๐ค๐๐ = ๐ก๐ โ ๐ง๐ ๐ฆ๐
โข ์ (17)์ LSE(Least Square Error)์ ๊ฐ์
โข LSE: ๐๐+1 = ๐๐ + ๐๐ ๐๐ โ ๐(๐๐) ๐ฆ๐ , ๐ ๐๐ = ๐๐๐๐ฆ๐
๐ ๐๐๐๐ ๐ถ 43
Back-propagation
โข Back Prop. of Input-to-Hidden
โข ๐ก๐๐๐๐๐๐๐ ๐๐๐๐๐ "๐ค๐๐" ์ต์ ํ ํ์ (โด ๐ฝ ๐ค ๋ฅผ๐ค๋ก ์ต์ ํ)
I J K
๐๐๐๐ข๐ก โ ๐ก๐ โ โ๐๐๐๐๐์๋ํ๐ก๐๐๐๐๐๐๐ ๐๐๐๐๐ "๐ค๐๐"๋ฅผ๊ณ์ฐ
๐ ๐๐๐๐ ๐ถ 44
Back-propagation
โข Back Prop. of Input-to-Hidden
โข (11) โ๐ค๐๐ = โ๐๐๐ฝ
๐๐ค๐๐๊ณผ chain rule ์ด์ฉ
18)๐๐ฝ
๐๐ค๐๐=
๐๐ฝ
๐๐ฆ๐๐
๐๐ฆ๐๐
๐๐๐๐ก๐
๐๐๐๐ก๐
๐๐ค๐๐
โข ์ ์์์ ์ฐ๋ณ์ ์ฒซ ํญ์ ๐ค๐๐๋ฅผ ๋ชจ๋ ํฌํจ
19)๐๐ฝ
๐๐ฆ๐๐=
๐
๐๐ฆ๐๐
1
2
๐=1
๐
๐ก๐ โ ๐ง๐2
= โ
๐=1
๐
๐ก๐ โ ๐ง๐๐๐ง๐๐๐ฆ๐
= โ
๐=1
๐
๐ก๐ โ ๐ง๐๐๐ง๐๐๐๐๐ก๐
๐๐๐๐ก๐๐๐ฆ๐
= โ
๐=1
๐
๐ก๐ โ ๐ง๐ ๐โฒ ๐๐๐ก๐ ๐ค๐๐ = โ
๐=1
๐
๐ค๐๐๐ฟ๐
9) ๐ฝ ๐ค โก1
2
๐=1
๐
๐ก๐ โ ๐ง๐2 =
1
2๐ก โ ๐ง 2
๐ง๐ = ๐ ๐๐๐ก๐
๐๐๐ก๐ =
๐
๐ฆ๐๐ค๐๐
๐ฟ๐ = ๐ก๐ โ ๐ง๐ ๐โฒ ๐๐๐ก๐ ๐ฆ๐
chain rule
๐ฟ๐
๐ ๐๐๐๐ ๐ถ 45
Back-propagation
โข unit k์ โ๐ฟ๐โ (์(19)์ ์(18)์์์ ๋ ๋ฒ์งธ ์)
20) ๐ฟ๐ โก ๐โฒ ๐๐๐ก๐
๐=1
๐
๐ค๐๐๐ฟ๐
๐โฒ ๐๐๐ก๐ =๐๐ฆ๐
๐๐๐๐ก๐=
๐๐ ๐๐๐ก๐
๐๐๐๐ก๐
โข Input-to-hidden์ weight ํ์ต
21) โ๐ค๐๐ = ๐๐ฅ๐๐ฟ๐ = ๐
๐=1
๐
๐ค๐๐๐ฟ๐ ๐โฒ ๐๐๐ก๐ ๐ฅ๐
๐ฅ๐: 18 ์๋ง์ง๋ง =๐๐๐๐ก๐๐๐ค๐๐
=๐ ๐ ๐ฅ๐๐ค๐๐
๐๐ค๐๐= ๐ฅ๐
๐ ๐๐๐๐ ๐ถ 46
Conclusion
โข Back propagation์ chain rule์ ์ด์ฉํ ๋ชฉ์ ํจ์์๋ฏธ๋ถ ๊ณ์ฐ์ multi layer model์ ์ ์ฉํ gradient descent์ ๊ธฐ๋ฐํ ๊ฒ
โข ๋ชจ๋ gradient descent์ ๋ง์ฐฌ๊ฐ์ง๋ก Back Prop.์ ๋์์ ์์์ ์ ์์กดโข ์์, ์ฆ weight init์ ๊ฐ๊ธ์ 0์ ํผํด์ผ ํจ (๊ณฑ ์ฐ์ฐ ๋๋ฌธ)
โข ์ (17)์ ๋ณด๋ฉด, unit k์์์ ๊ฐ์ค์น ๊ฐฑ์ ์ (๐ก๐ โ ๐ง๐)์ ๋น๋กํด์ผ ํจโข (๐ก๐ = ๐ง๐), ์ฆ ์ถ๋ ฅ๊ณผ ์ ๋ต์ด ๊ฐ์ผ๋ฉด weight ๋ณํ X
โข sigmoid function ๐โฒ(๐๐๐ก)๋ ํญ์ ์์ ์ [0 or 1]โข (๐ก๐ โ ๐ง๐)์ ๐ฆ๐๊ฐ ๋ ๋ค ์์ด๋ฉด output์ ์๊ณ ๊ฐ์ค์น๋ ์ฆ๊ฐ๋ผ
์ผ ํจ
๐ ๐๐๐๐ ๐ถ 47
Conclusion
โข weight ๊ฐฑ์ ์ ์ ๋ ฅ ๊ฐ์ ๋น๋กํด์ผ ํจโข ๐ฆ๐ = 0 ์ด๋ฉด, hidden unit โjโ๋ output๊ณผ error์ ์ํฅ์ ์ฃผ์ง
์์ ๐ค๐๐์ ๋ณ๊ฒฝ์ ํด๋น ํจํด์ error์ ์ํฅ ์์
โข feed forward์ ์ผ๋ฐํ๋ฅผ ์ฌ์ฉํ Back prop.์ ์ผ๋ฐํโข input unit๋ค์ bias unit ํฌํจ
โข input unit๋ค์ hidden unit ๋ฟ๋ง ์๋๋ผ output unit๋ค์๋ ์ง์ ์ฐ๊ฒฐ ๊ฐ๋ฅ (๊ทธ๋ฆผ ์ฐธ์กฐ)
โข ๊ฐ ์ธต๋ง๋ค ๋ค๋ฅธ ๋น์ ํ์ฑ์ด ์์
โข NN [i-to-h: sigmoid, h-to-o: ReLU]
โข ๊ฐ unit๋ค์ ๊ทธ ์์ ์ ๋น์ ํ์ฑ์ ๊ฐ์ง
โข ๊ฐ unit๋ค์ ๋ค๋ฅธ ํ์ต๋ฅ (โ๐ค)์ ๊ฐ์ง
๐ ๐๐๐๐ ๐ถ 48
References
โข https://photos.google.com/share/AF1QipPX0SCl7OzWilt9LnuQliattX4OUCj_8EP65_cTVnBmS1jnYgsGQAieQUc1VQWdgQ?key=aVBxWjhwSzg2RjJWLWRuVFBBZEN1d205bUdEMnhB
โข http://cs.kangwon.ac.kr/~leeck/Advanced_algorithm/4_Perceptron.pdf
โข Pattern Recognition, Richard O. Duda et al.
๐ ๐๐๐๐ ๐ถ 49
QA
๊ฐ์ฌํฉ๋๋ค.
๋ฐ์ฒ์, ๋ฐ์ฐฌ๋ฏผ, ์ต์ฌํ, ๋ฐ์ธ๋น, ์ด์์
๐ ๐๐๐๐ ๐ถ , ๊ฐ์๋ํ๊ต
Email: [email protected]
๐ ๐๐๐๐ ๐ถ 50
๐ฅ๐
Input layer
Weight
ActivationFunction
๐ฆ๐
Hiddenlayer
ActivationFunction
๐ง๐
Outputlayer
Weight