Output for an RNN

谁说我不能喝 提交于 2019-12-13 07:29:13

问题


I'm taking the Coursera course Neural Networks for Machine Learning hosted by Geoffrey Hinton from the University of Toronto and there is a quiz question in week 7 for which my answer differs from the right one.

The question goes like this:

One question is, how should I get a probability between 0 and 1 if the Whh weight is negative and the logistic h unit gives values between 0 and 1. Given the above, their linear combination will allways be negative.

A second question would be if we also have to use backpropagation in order to get the right answer?

The way I've started to tackle this question is the following:

h0 = 1/( 1 + exp(- (Whh * hbias + Wxh*x0)) )

h1 = 1/( 1 + exp(- (Whh * h0 + Wxh*x1)))

y1 = Why * h1

Which of my assumptions are incorrect?

Regards, Cristian


回答1:


Try this.

h0 = sigmoid(x0*Wxh + hbias)
h1 = sigmoid(x1*Wxh + Whh*h0 + hbias)
y1 = h1*Why


来源:https://stackoverflow.com/questions/43044992/output-for-an-rnn

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!