Questions tagged [encoder-decoder]
184 questions
0
votes
1 answer
Decoder always predicts the same token
I have the following decoder for machine translation that after a few steps only predicts the EOS token. Overfitting on a dummy, tiny dataset is impossible because of this so it seems that there is a big error in the code.
Decoder(
(embedding):…

Bram Vanroy
- 27,032
- 24
- 137
- 239
0
votes
1 answer
Get encoder from trained UNet
I have trained a UNet model on some images but now, I want to extract the encoder part of the model. My UNet has the following architecture:
UNet(
(conv_final): Conv2d(8, 1, kernel_size=(1, 1), stride=(1, 1))
(down_convs): ModuleList(
(0):…

Sarvagya Gupta
- 861
- 3
- 13
- 28
0
votes
0 answers
Input contains NaN while using LSTM
I am trying to build a univariate encoder-decoder LSTM model.
I got this error again and again:
ValueError: Input contains NaN, infinity or a value too large for dtype('float32').
I have already searched and read the other posts who asked about…

Noori
- 3
- 3
0
votes
1 answer
training loss during LSTM training is higher than validation loss
I am training an LSTM to predict a time series. I have tried an encoder-decoder, without any dropout. I divided my data n 70% training and 30% validation. The total points in the training set and validation set are around 107 and 47 respectively.…

Nhqazi
- 732
- 3
- 12
- 30
0
votes
0 answers
Adding a Pre-Trained Word Embedding into an Encoder Decoder
I would like to add a Pretrained Word Embedding to my Encoder-Decoder. Below is my code:
# Define an Encoder
encoder_inputs = Input(shape=(None, nEncoderToken))
encoder = LSTM(embedding_dim, return_state=True)
encoder_outputs, state_h, state_c =…

Adam L
- 25
- 5
0
votes
1 answer
NaN loss and 0 accuracy from the start itself: Encoder Decoder Model Keras
I have made an encoder decoder model using Keras framework, for making a chatbot. I cannot find any issues with my model, still on training the LOSS is nan from the first epoch itself, and the accuracy remains zero.
I have tried the code for…

Shreyansh Chordia
- 21
- 3
0
votes
1 answer
Implement an Encoder and Decoder architecture with attention mechanism
I want to implement Encoder-Decoder with attention mechanism from scratch. Can anyone please help me with the code?

Hardik Vagadia
- 355
- 2
- 10
0
votes
1 answer
ZeroPadding2D pad twices when I set padding to 1
I've just started to learn Tensorflow (2.1.0), Keras (2.3.7) with Python 3.7.7.
I'm trying an encoder-decoder network using VGG16.
I need to Upsample a layer from (12, 12, ...) to (25, 25, ...) to make conv7_1 has the same shape as conv4_3 layer.…

VansFannel
- 45,055
- 107
- 359
- 626
0
votes
1 answer
Base64 encoding in 12C BPEL is replacing the parent tag by the BPEL variable name
I'm trying to base64 encode a request XML by storing it first in a BPEL varible.
Could you please have a look at the problem and suggest me what I did wrong and how the same can be fixed?
e.g. When I decode the encoded message, I get the output as…

jaihind
- 1,090
- 1
- 8
- 9
0
votes
1 answer
Strategies to speed up LSTM training
I have an encoder decoder network with : 3 BLSTMs in the encoder and 2 vanilla LSTMs in the decoder connected with a mutli head attention with 4 nodes. Latent dimension is 32 and my total sample looks like (10000,400,128). The encoder network has a…

Crossfit_Jesus
- 53
- 4
- 18
0
votes
1 answer
How have the number of dimensions after LSTM been decided in Pointer Generator Model in PyTorch?
I don't understand why is the number of input and output dimensions 2 * config.hidden_dim while applying a fully connected layer in the encode class (mentioned in the last line)?
class Encoder(nn.Module):
def __init__(self):
…

sakshi agarwal
- 3
- 1
0
votes
0 answers
Getting padded data back LSTM
I have variable length for each training data which I have padded to zero keeping the length of the longest variable as the constant length. After getting the data trained how do I get the original data back? Is there a way to train in Seq2Seq…

Crossfit_Jesus
- 53
- 4
- 18
0
votes
0 answers
MNIST Data set anomaly detection
I am trying to use MNIST data set for anomaly detection using Encoder with tensor flow, the input of Encoder is normal and abnormal data , the question is how i divide MNIST to normal and abnormal data (exp the zeros are abnormal and the (1-9) are…

MBK AI
- 1
- 2
0
votes
1 answer
Training in inference mode in seq-to-seq model
This is apparently the code for seq2seq model with embedding that i wrote
encoder_inputs = Input(shape=(MAX_LEN, ), dtype='int32',)
encoder_embedding = embed_layer(encoder_inputs)
encoder_LSTM = LSTM(HIDDEN_DIM, return_state=True)
…

saransh bhatnagar
- 40
- 4
0
votes
1 answer
Error: Dimension conflicts layer in Keras following sequence-to-sequence tutorial
Following this tutorial
https://blog.keras.io/a-ten-minute-introduction-to-sequence-to-sequence-learning-in-keras.html
Specifically, the section concerning using data that is integer sequenced instead of one-hot encoded.
From the error message…

Riley
- 1
- 2