Questions tagged [sequence-to-sequence]

This tag is used for Google's deprecated seq2seq framework, an encoder-decoder framework for Tensorflow (revamped version is called Neural Machine Translation)

94 questions
0
votes
1 answer

Seq to Seq model training

I have couple of questions: In a seq to seq model with varying input length, if you don't use the attention mask the RNN may end up computing the hidden state value for padded element? So thus it mean attention mask is mandatory else my output will…
0
votes
1 answer

How to construct encoder from a loaded model in Keras?

I have an encoder-decoder model whose structure is the same as the one at machinelearningmastery.com with num_encoder_tokens = 1949, num_decoder_tokens = 1944, and latent_dim = 2048. I would like to construct the encoder and decoder models by…
namacha
  • 1
  • 1
0
votes
0 answers

Sequence-to-Sequence Model not performing well

I am trying to build a seq2seq autoencoder that should have the ability to capture the logic of a sequence and be able to reconstruct it from the state vectors. I am using some example sequences to test if the model is capable of doing a very simple…
0
votes
1 answer

Keras embedding layer causing dimensionality problems

I am currently trying to include an embedding layer to my sequence-to-sequence autoencoder, built with the keras functional API. The model code looks like this: #Encoder inputs encoder_inputs = Input(shape=(None,)) #Embedding embedding_layer =…
0
votes
0 answers

How to build and train a sequence 2 sequence model in tensorflow.js

Hi I am trying to build a text summarizer, using sequence 2 sequence model in tensorflow.js. My dataSet(example) : { Text: i want to return this product because it was broken when i received it. Expected Output: broken Product. } I can convert…
Manoj
  • 983
  • 12
  • 23
0
votes
2 answers

Variable Input for Sequence to Sequence Autoencoder

I implemented a Sequence to Sequence Encoder Decoder but I am having problems with varying my target length in the prediction. It is working for the same length of the training sequence but not if it is different. What do I need to change ? from…
0
votes
1 answer

sequence tagging task in tensorflow using bidirectional lstm

I am little interested in sequence tagging for NER. I follow the code "https://github.com/monikkinom/ner-lstm/blob/master/model.py" to make my model like below: X = tf.placeholder(tf.float32, shape=[None, timesteps , num_input]) Y =…
0
votes
1 answer

In word embedding, how to map the vector to word?

I checked all API and couldn't find a way to map vector to word no matter in word2Vec or glove. Google doesn't help that much. Does anybody know to do this? Background: I'm training a chatbot by using seq2seq model. But the implementations I found…
Bing Magic
  • 29
  • 5
0
votes
0 answers

How to build an encoder-decoder model with Tensorflow ConvLSTMCell?

I would be really thankful if someone can explain to me that how I can build an encoder-decoder model with Tensorflow ConvLSTMCell(), tf.nn.dynamic_rnn(), and tf.contrib.legacy_seq2seq.rnn_decoder(). I would like to build a model that has 3 encoder…
MRM
  • 1,099
  • 2
  • 12
  • 29
0
votes
1 answer

Optimizing the neural network after each output (In sequence-to-sequence learning)

In sequence-to-sequence learning when we are predicting more than one step ahead, should we optimize the neural network after each output or should we optimize the outputs of every sequence together? Like if I am predicting 10 steps for each…
0
votes
2 answers

Seq2seq pytorch Inference slow

I tried the seq2seq pytorch implementation available here seq2seq . After profiling the evaluation(evaluate.py) code, the piece of code taking longer time was the decode_minibatch method def decode_minibatch( config, model, …
0
votes
1 answer

How can the perplexity of a language model be between 0 and 1?

In Tensorflow, I'm getting outputs like 0.602129 or 0.663941. It appears that values closer to 0 imply a better model, but it seems like perplexity is supposed to be calculated as 2^loss, which implies that loss is negative. This doesn't make any…
0
votes
1 answer

Google TensorFlow based seq2seq model crashes while training

I have been trying to use Google's RNN based seq2seq model. I have been training a model for text summarization and am feeding in a textual data approximately of size 1GB. The model quickly fills up my entire RAM(8GB), starts filling up even the…
Rudresh Panchal
  • 980
  • 4
  • 16
0
votes
0 answers

tf.scatter_nd_update Variable Requirement vs RNN.__call__ method

I am developing a RNN and am using Tensorflow 1.1. I got the following error: tensorflow.python.framework.errors_impl.InvalidArgumentError: The node 'model/att_seq2seq/encode/pocmru_rnn_encoder/rnn/while/Variable/Assign' has inputs from different…
0
votes
1 answer

Training Method Choice for seq2seq model

What kind of training method you may recommend for training an attention based sequence to sequence neural machine translation model? SGD, Adadelta, Adam or something better? Please give some advice, thanks.