-
Notifications
You must be signed in to change notification settings - Fork 703
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added set_s function for rnns #127
Conversation
should be ok now, tested with
in python |
Great! This would be even greater if you could convert this test code into On Wed, Oct 26, 2016 at 10:33 AM, Paul Michel [email protected]
|
for your following code: for (unsigned i = 0; i < layers; ++i) { in my opinion, it should be : 张文,在读博士 自然语言处理研究组Wen Zhang, Ph.D Candidate
|
@neubig Is there already a framework in place for unit tests? @zhang-wen Not sure what you mean.
Maybe I misunderstood what you meant. Just to make sure we're talking of the same thing, the new behaviour for set_h and set_s are :
|
@pmichel31415 Yes, see the tests/ directory. |
Shall I merge this? I'd like to prevent the branches from diverging too much and causing problems at merge time. Tests would be great, but they can wait for later. |
@paul Michel sorry about unclear describing. your understanding is correct, for your two unsure question:
the problem is LSTM, i do not actually understand why do you copy the h and c of 张文,在读博士 自然语言处理研究组Wen Zhang, Ph.D Candidate
|
@neubig Yes, I'll write tests but probably won't be able to do it before next week, I think this should be merged @zhang-wen The previous behaviour of new_h was to increment the time step of the rnn-state-machine with the new h_new. to be consistent with this behaviour you need to copy the previous state. Thanks for your feedback! |
@paul Michel i am thinking about the rnn/lstm structure, little confusing about the s and h, 张文,在读博士 自然语言处理研究组Wen Zhang, Ph.D Candidate 已使用 Sparrow (http://www.sparrowmailapp.com/?sig) 在 2016年10月27日 星期四,09:03,Paul Michel 写道:
|
@paul Michel sorry, i make the mistake again, for simple run, the s() is the same as h(). 张文,在读博士 自然语言处理研究组Wen Zhang, Ph.D Candidate 已使用 Sparrow (http://www.sparrowmailapp.com/?sig) 在 2016年10月30日 星期日,08:08,Wen Zhang 写道:
|
@zhang-wen I'm going to push some documentation on rnn builders sometimes in the beginning of the week, hopefully today. This should make things more clear. Long story short, there are two vectors stored in LSTMs,
|
C++ and python implementation. Partially addresses #124
WARNING : NOT TESTED (should be ok though, basically copy pasted set_h)