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

The comment in the Bi-LSTM (Attention) model has an issue. #84

Open
tmracy opened this issue Sep 10, 2024 · 1 comment
Open

The comment in the Bi-LSTM (Attention) model has an issue. #84

tmracy opened this issue Sep 10, 2024 · 1 comment

Comments

@tmracy
Copy link

tmracy commented Sep 10, 2024

The comment # output : [batch_size, len_seq, n_hidden] should indeed be corrected to # output : [batch_size, len_seq, n_hidden*2] because the Bi-LSTM model is bidirectional. In a bidirectional LSTM, the hidden size is effectively doubled, as it concatenates the forward and backward hidden states. Therefore, the correct shape of the output after permutation is [batch_size, len_seq, n_hidden * 2].

@bbzxc
Copy link

bbzxc commented Jan 9, 2025

Could you please tell me where the Bi-LSTM (Attention) method was proposed? Is there a paper or an algorithm introduction available?

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