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

add seq2seq layer to embedding layer with mask raise "Exception: Layers should have equal number of output tensors and output masks. Layer recurrent_sequential_1 has 3 output tensors and 4 output masks." #270

Open
shelfee opened this issue Jan 16, 2019 · 4 comments

Comments

@shelfee
Copy link

shelfee commented Jan 16, 2019

model = Sequential() model.add(Embedding(39, 39, input_length=24, mask_zero=True)) model.add(Seq2Seq(input_length=24, input_dim=39, hidden_dim=10, output_length=22, output_dim=39))
raise the Exception

@shelfee shelfee changed the title add seq2seq layer 同 add seq2seq layer to Jan 16, 2019
@shelfee shelfee changed the title add seq2seq layer to add seq2seq layer to embedding layer with mask raise "Exception: Layers should have equal number of output tensors and output masks. Layer recurrent_sequential_1 has 3 output tensors and 4 output masks." Jan 16, 2019
@ketyi
Copy link

ketyi commented Feb 12, 2019

I've the exact same Exception with an ultra simple:
base_model = Seq2Seq(input_dim=128, input_length=150, hidden_dim=512, output_length=150, output_dim=128, depth=2) multi_model = multi_gpu_model(base_model, gpus=2) multi_model.compile(loss='mse', optimizer='adam', metrics=['mse'])

I don't have any masks and with the AttentionSeq2Seq class just worked...

@foreshadow
Copy link

Same issue.

@byamao1
Copy link

byamao1 commented Feb 6, 2020

I encounter this problem too.

@Lance-Tin
Copy link

I encounter this problem too. just executed the example code;
tensorflow==1.13.1
keras==2.2.4
python==3.6.2

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

5 participants