-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Err in char_rnn tutorial #193
Comments
@williamFalcon Small question. You mentioned that
Performs the RNN formula. I didn't get how concatenating the input and hidden tensors is useful in this scenario. Why the need for concatenation? |
I think it should be changed. The implemented formula is wrong? |
I know this is an old issue/comment....but you don't "need" to concatenate the input and hidden tensors, this is just a way to calculate the same thing without having two separate weights tensors (the standard formulae typically assume two weights matrices, see below) Also I just wanted to chime in. I agree that this should be changed. |
/assigntome |
@apaszke
This tutorial "char_rnn_classification" has a bug in the forward part of this code:
The RNN formula is:
Which is implemented by these lines:
However, these lines:
Are trying to project into the classification space. However, the self.i2o operates on the combined output instead of the ht output.
This implementation uses the wrong formula:
But the correct formula is:
Which can be implemented as:
Basically, the current implementation does this:
But it really should do this:
The text was updated successfully, but these errors were encountered: