Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
430 views
in Technique[技术] by (71.8m points)

backpropagation - Neural network: How to calculate the error for a unit

I am trying to work out question 26 from this exam paper (the exam is from 2002, not one I'm getting marked on!)

This is the exact question:

enter image description here

The answer is B.

Could someone point out where I'm going wrong?

I worked out I1 from the previous question on the paper to be 0.982.

The activation function is sigmoid. So should the sum be, for output 1:

d1 = f(Ik)[1-f(Ik)](Tk-Zk)

From the question:

T1 = 0.58
Z1 = 0.83
T1 - Z1 = -0.25
sigmoid(I1) = sigmoid(0.982) = 0.728
1-sigmoid(I1) = 1-0.728 = 0.272

So putting this all together:

d1 = (0.728)(0.272)(-0.25)
d1 = -0.049

But the answer should be d1 = -0.0353

Can anyone show me where I'm going wrong?

Edit 1: I tried to work backwards to understand the situation, but I still got stuck.

I said:

d1 = f(Ik)[1-f(Ik)](Tk-Zk)
-0.0353 = f'(Ik)(-0.25) (where I know -0.0353 is the right answer, and -0.25 is Tk - Zk)
0.1412 = f'(Ik)
0.1412 = f(Ik)[1-f(Ik)]
0.1412 = sigmoid(x).(1-sigmoid(x))

...but then I got stuck, if anyone has an idea


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

The problem is, that the I? you got from the previous question is not the same I? you need for this task.

The value of I? changes depending on the input values(which are different for this question)!

For the solution of this question you can instead use the fact that f(I?) = z?:

δ? = f(I?)·[1 - f(I?)]·(t? - z?)

= z?·[1 - z?]·(t? - z?)

→ δ? = 0.83·[1 - 0.83]·(-0.25) = -0.2075·0.17 = -0.035275 ≈ -0.0353

→ δ? = 0.26·[1 - 0.26]·(0.70 - 0.26) ≈ -0.0847

→ δ? = 0.56·[1 - 0.56]·(0.20 - 0.56) ≈ -0.0887


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...