Questions tagged [sequence-to-sequence]
The sequence-to-sequence tag has no usage guidance.
50
questions with no upvoted or accepted answers
3
votes
1
answer
57
views
String together a set of tokens into a sequence
I have this problem scenario - Given a set of tokens, string them or a subset of the tokens together using stop words into a sequence. I am clear that I can have potentially infinite pre-training data ...
3
votes
1
answer
4k
views
Predicting next number in a sequence - data analysis
I am a machine learning newbie and I am working on a project where I'm given a sequence of integers all of which are in the range 0 to 70. My goal is to predict the next integer in the sequence given ...
3
votes
0
answers
114
views
Encoder-Decoder Sequence-to-Sequence Model for Translations in Both Directions
Is it possible to use a pre-trained sequence to sequence encoder-decoder model which translates an input text in source language to an output in target language to do an inverse translation? That is, ...
2
votes
0
answers
223
views
Why the LSTM on Keras does not work correctly when it is necessary to predict several steps forward
I used AirPassenger Dataset. And based on several previous values(for examples 20) I want to predict several(3 or 5) steps in future.
Like
X -> y
[10,20,30,....200]->[210,220,230]
[20,30,40,.......
2
votes
2
answers
366
views
Timeseries LSTM: does test data need to come after training data?
I have one single, very long time series. I want to train an LSTM to distinguish between two behaviours (A or B) at every timestep (sequence-to-sequence).
Because the time series is very long, I plan ...
2
votes
0
answers
185
views
LSTM low training/validation error but really bad predictions
I'm building a LSTM model to create an automatic drums composer.
I'm following this post: LSTM Metallica
I've built my model and done all the enconding, I was able to emulate the behavior of the ...
2
votes
0
answers
470
views
Weight matrices in transformers
I am trying to understand the transformer architecture.
I am aware that the encoder/decoder contains multiple stacked self attention layers. Further each layer contains multiple heads. For example ...
2
votes
0
answers
316
views
Why isnt my seq2seq model reconising what the <END> tag is?
I am making a seq2seq chatbot with the help of this guide: https://medium.com/predict/creating-a-chatbot-from-scratch-using-keras-and-tensorflow-59e8fc76be79 . I set up the model and data processing ...
2
votes
1
answer
4k
views
IndexError: list index out of range
I'm implementing a sequence-2-sequence model with RNN-VAE architecture, and I use an attention mechanism. I have problem in the decoder part.
I'm struggling with this error: IndexError: list index ...
2
votes
0
answers
1k
views
Recommended model for univariate or multivariate multistep ahead time series forecasting
I have a dataset consisting of recurring and non-recurring expense transactions from bank accounts, as well as other features describing the bank account and each transation. I aggregate these ...
2
votes
1
answer
302
views
Keras: Softmax output into embedding layer
I'm trying to build an encoder-decoder network in Keras to generate a sentence of a particular style. As my problem is unsupervised i.e. I don't have the ground truths for the generated sentences, I ...
1
vote
1
answer
511
views
Why does a decoder generate all hidden states during inference?
Seems that in Vanilla transformers at least (a la AIAYN), during inference time, the hidden states are generated for all tokens in the input sequence, but only the last one is used to predict the next ...
1
vote
0
answers
37
views
RNN to model DNA sequencing classification
I have a DNA sequence dataset each mapped to a certain class.
e,g
TCAGCCGAGAGCTCATCGATCGTACGT 2
ATGCAGTGCATCGATCGATCGTAGAAC 3
Where the number after the sequence specifies the type of protein this ...
1
vote
1
answer
326
views
Seq2Seq loss function
I was reading the paper neural_approach_conversational_ai.pdf. And in the section Seq2Seq for Text Generation there is a formula that i feel a bit wrong
[1]: https://i.stack.imgur.com/sX0it.png
Can ...
1
vote
0
answers
15
views
Sequence learning from farm operations data
I need to generalize a single sequence from N sequences entailing farming tasks/operations and ultimately plotting it on Gantt chart.
There are a total let's assume N sequences = n (total fields) * t (...
1
vote
1
answer
206
views
Multi-step forecasts of factory production data using a Seq2Seq Encoder-Decoder Model with Attention
I am attempting to use a Seq2Seq model to make forecasts of factory production data using an Encoder-Decoder model augmented with Attention. I have become a little stuck as the output of the model ...
1
vote
0
answers
40
views
Workaround / fallback value for tfp.distributions.Categorical.log_prob in tensorflow graph mode
Is there a way to avoid tfp.distributions.Categorical.log_probraising an error if the input is a label out of range?
I am passing a batch of samples to the ...
1
vote
0
answers
82
views
Dummy Variables of Weights in RNN Backpropagation Through Time
In the deep learning book RNN chapter (https://www.deeplearningbook.org/contents/rnn.html), it is mentioned that -
To resolve this ambiguity, we introduce dummy variables $W^{(t)}$ that are defined to ...
1
vote
0
answers
123
views
Multiple time series sequence prediction for multiple multivariate time series
My question is somehow similar to this question, but not satisfied with the answer. I have 100 samples, each sample consists of ...
1
vote
0
answers
41
views
Seq2Seq for sentence correction
I have a task in hand where I get a dirty formed sentence and need to correct it. Examples are, "StackOverflow best question answering platform" to be converted to "StackOverflow is best question ...
1
vote
0
answers
195
views
How can I finetune XLM-R for neural machine translation between the same language(Catalan to Catalan-with different grammar structure))?
Can I fine-tune XLM-R to do something similar to https://www.guru99.com/seq2seq-model.html
(encoder-decoder architecture or any other way that perform good in small dataset - around 1000)
For example:
...
1
vote
0
answers
34
views
How can I do a sequence to sequence model (RNN / LSTM) with Keras with fixed length data?
What I'm trying to do seems so simple, but I can't find any examples online. First, I'm not working in language, so all of the embedding stuff adds needless ...
1
vote
0
answers
131
views
Improving Performance of LSTM for time series prediction
My data consists of two features and a set of time series data labeled as "bookings". I have 1056 data point in the times series, for which I have two features for each. The data size is 1056x3.
My ...
1
vote
0
answers
142
views
How to create a seq2seq without specifying a fixed decoder length?
Based on the model presented in this answer:
...
1
vote
0
answers
37
views
Adding context in a sequence to sequence problem
The encoder of a seq2seq model is meant to generate a conditioning context for the decoder, as mentioned here
A RNN layer (or stack thereof) acts as "encoder": it processes the input sequence and ...
1
vote
0
answers
46
views
Initialising states in a multilayer sequence to sequence model
With a sequence to sequence model where the enocoder and decoder are both comprised of one layer each, the initial state of the decoder is initialised to use the final states of the encoder layer.
In ...
1
vote
0
answers
284
views
What should the size of the decoder output be in a sequence to sequence model
In a sequence to sequence model, a lot of the tutorials I have read state that the decoder target length should be the same as the encoder input length (https://blog.keras.io/building-autoencoders-in-...
1
vote
0
answers
71
views
On-the-fly seq2seq: starting translation before the input sequence ends
By now anybody even remotely familiar with RNNs has been exposed to the famous figure representing variants of such networks:
However one type that is missing is one where there would be a partial ...
1
vote
0
answers
291
views
Neural network outputting same result for all inputs
I'm building an encoder-decoder neural network in Keras for sequence generation. The specific task is to try and change the styles of the text.
Both my encoder and decoders are LSTMs with latent ...
1
vote
2
answers
163
views
How to pad real-valued sequences
I have several sequences of univariate real-valued time-series data. The sequences are of different lengths and right now I cannot batch them and feed them to a network.
What is the correct procedure ...
0
votes
0
answers
17
views
Is this problem a time series regression or seq2seq regression or some other type of problem?
I measure sequences of 3 parameters in my system. 2 are independent and the 3rd dependent. Let's call the independent ones $x$ and $y$, and the dependent one $z$. They are each measured once per hour ...
0
votes
0
answers
385
views
How to Use Generative AI for Time Series Forecasting?
What I have
A time series dataset of time stamps (hourly resolution), some covariates (like store foot-traffic) and items sold.
What to forecast
Number of items sold for next 24 hours, i.e. 24 ...
0
votes
0
answers
63
views
Seq2seq Transformer Autoencoder returns same results when unfolded using only memory and initial value
I have numeric signals from two sensors, and I would like to create a mapping using sequence-to-sequence autoencoder. I used the transformer architecture, and it seems to be learning - the loss is ...
0
votes
0
answers
35
views
Which language model to use for this use case? [Finetuning on custom dataset]
An example from my train data is as follows:
...
0
votes
0
answers
16
views
Error in seq2seq translation when passing predicted output to rnn due to input shape not always being the same
I'm working on a language translator and I'm getting an error I'm unsure about.
During the decoding process when using argmax on the predicted output I am sometimes getting an RuntimeError ...
0
votes
0
answers
26
views
GRU as a Classifier
Hello Data Scientists,
I have sensor data dataset consists of (10 features and labels), the labels classify the data to (normal or 4 type of attacks). The Label is encoded (0,1,2,3,4). There is a ...
0
votes
0
answers
24
views
Pretrained model for RNN Encoder-Decoder?
Our team are implementing a paper called Cold-Start-Reinforcement-Learning-with-Softmax-Policy-Gradient.
Although the paper didn't mention. We want to use a pre-trained model, which is a RNN Encoder-...
0
votes
0
answers
10
views
In abstractive document summarization task, if I have multiple target sequences for one input document, what is the ideal loss form?
I use autoregressive model like T5 to tackle the abstractive document summarization task. In my case there are multiple target summarizations for one input document. Is there some related works about ...
0
votes
0
answers
52
views
I can't figure out why even when training the seq2seq chatbot neural network, it doesn't give adequate answers
When training with 50 thousand pairs of questions and loss 0.2 accuracy 0.9 it does not give adequate answers
...
0
votes
0
answers
34
views
Batch inference and seq2seq
I am following this guide to the Seq2Seq architecture. It is clear that the author suggests batch training during the teacher forcing step. However, during the inference step, the author restricts the ...
0
votes
0
answers
44
views
Siamese network for a sequence-to-sequence generation
Shall I use the siamese network for a sequence-to-sequence generation problem in machine learning?
Eg:
Input 1: Sentence 1 (sequence)
Input 2: Sentence 2 (sequence)
Output: Newly Generated sentence (...
0
votes
0
answers
54
views
Dialogue history encoding for multi-turn dialogues using Seq2seq
In single-turn dialogue seq2seq models where the goal is to produce a good answer y to a query x, sentences are usually encoded such that x is fed to the encoder, while the decoder is only given a &...
0
votes
1
answer
82
views
How to make a pipeline for Videos Dataset for TensorFlow [Sequence Matters] & train Model Effectively with Low Memory System
I am working on a Deep Learning project and I am facing an issue with the size of the dataset. I want to make a pipeline for video dataset [Sequence Matters]. Because if I try the load the whole ...
0
votes
1
answer
53
views
Forecasting of Images using ConvLSTM2D
I am working on a problem of seq2seq modelling using ConvLSTM2D layer in keras. Implementation of convLSTM in keras allows user to control over output sequence using 'return_sequence' option. When ...
0
votes
0
answers
149
views
Predict sequence using seqGAN
I am trying to create a GAN model in which I am using this seq2seq as Generator and the following architecture as Discriminator:
...
0
votes
1
answer
41
views
Preprocess multi-sample time series data: encode each sample separately or in aggregate?
Let's say I have 3 dense sequences of uniform length. Should I fit a scaler on them separately or together?
...
0
votes
0
answers
28
views
How to reduce dimensionality of encoder decoder output?
I have an encoder decoder architecture where the output $ \bar{\bf{y}}_t $ is a sequence of integers of maximum length $n$. Each integer in the sequence is representative of a category so the ...
0
votes
1
answer
65
views
two different attention methods for seq2seq
I see two different ways of applying attention in seq2seq:
(a) the context vector (the weighted sum of encoder hidden states) fed into the output softmax, as shown in the diagram below. The diagram ...
0
votes
0
answers
34
views
Strategy for "forcing" number of labels in seq2seq predictions with Keras?
I'm trying to train a seq2seq model that for every timestep in a given timeseries sample will output 1 of 6 possible labels.
Furthermore, the training data is constructed in such a way that
Each ...
0
votes
2
answers
117
views
Seq2Seq Model training: Encoder vs. Decoder
Can someone point me to an article which explains how the model training is done in Seq2Seq? I know "Teacher Forcing" is used but what I found so far hasn't been detailed enough. What I am most ...