Skip to content
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

possible opposite explanation of hidden compared to output in notebook #3 #200

Closed
Hadar933 opened this issue Apr 25, 2023 · 0 comments
Closed

Comments

@Hadar933
Copy link

In your forward method, inside Encoder, you specify that

    #outputs = [src len, batch size, hid dim * num directions]
    #hidden = [n layers * num directions, batch size, hid dim]
    
    #hidden is stacked [forward_1, backward_1, forward_2, backward_2, ...]
    #outputs are always from the last layer

While the dimensions are correct, I think that it is the outputs that are stacked, and the hidden is from the last layer (see GRU docs)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants