All Questions
Tagged with keras time-series
419 questions
0
votes
0
answers
24
views
Input Batch Size in Keras and model.fit() batch size for Time Series Data
I am training an TCN model in Keras and have 9 individual trials of time-series data with an input shape = (9 trails/batches, 540 time steps for each trial, and 63 features).
I want to train the model ...
0
votes
1
answer
92
views
CNN-1D for time-series data returns strange accuracy [closed]
I am using keras to train a 1D CNN with time-series as input data to perform a binary classification. The model part of the code is the following:
modelo = Sequential()
modelo.add(Conv1D(filters=32, ...
0
votes
1
answer
27
views
Train LSTM for time series with varying lengths
I'm training a LSTM for time series prediction, where data comes from sensors at irregular intervals. I'm using the last 5 min data to predict the next value, but some sequences are larger than others....
0
votes
0
answers
32
views
Attention masks on time series data with keras funktional API
Im currently trying to study the effects of masking attention on a transformer model trained to classify time series data. My model works so far and give me okish performance, but when i try to mask ...
-1
votes
1
answer
63
views
Why does this simple machine learning code give the wrong answer?
I'm trying to learn some time-series neural network ML and was getting weird solutions, so I'm trying to model the simplest non-trivial case I can think of, which is predicting n+1 as the next number ...
0
votes
0
answers
60
views
Understanding the `model.fit` function in keras and imbalanced datasets
As an exercise, I'm trying to translate a model written in Keras (https://github.com/CVxTz/ECG_Heartbeat_Classification/blob/master/code/baseline_mitbih.py) into Pytorch code. I realize in Keras much ...
0
votes
0
answers
69
views
Keras LSTM model and predicting beyond validation set
I am currently encountering issues with formulating a prediction beyond my validation set. When utilizing a validation set, my model works fine and I am able to achieve a credible prediction.
However, ...
0
votes
0
answers
45
views
Why do my LSTM multi-step forecasts explode, despite low MAPE on validation set (single-step) on very simple linear trend?
Example below is self-complete.
I have recently switched from using darts (where forecast horizons etc) are all handled for me to keras because I wanted to integrate with other libraries such as shap ...
0
votes
0
answers
89
views
Tensorflow/Keras Transformer struggles to predict the last position in a sequence, but does well in all the other positions
I am using a Transformer for next frame prediction. Every frame has been previously encoded into a 1D latent vector using a VAE (the encoding-decoding from the VAE is very good).
I have divided the ...
0
votes
0
answers
49
views
How to visualize attention weighted feature map of BiLSTM seq2seq model using 3-dimensional temporal data?
I'm developing an attention-based BiLSTM seq2seq model for time series forecasting. My dataset has 3-dimension shape (None, 4, 67). The None means a number of samples and the 4 presents time steps. ...
1
vote
1
answer
126
views
Preparation of multivariate time series data
I am doing a university project on index/stock price prediction. I plan to use a combined cnn-lstm model, and I have several different types of data: Open High Low Close Volume, values, fundamental ...
2
votes
1
answer
966
views
Difference between single-step forecasting and multi-step in LSTM regression problem
I am using keras LSTM to do a time series prediction. It is a regression problem, where I want to predict for example the next 5 values. The data comes from a sensor and looks like this, where x axis ...
0
votes
0
answers
41
views
LSTM forecasting horizontal line with standardized datas
I’ve seen many topics about the problem I have in my situation but nothing help.
I am trying to make a forecast on a stock price with a Bidirectional LSTM.
My problem here is that the forecast on test ...
-1
votes
1
answer
292
views
Why my LSTM Model forecasts almost straight line on validation set?
I trained a BI-LSTM model on stock prices.
For this model, I did 2 approaches of backtesting :
Applying the predict function for the whole validation set and then compare predictions to real data
...
1
vote
1
answer
47
views
Understanding the input_shape of LSTM model
I divided my database in 40 rolling windows so I have a dataframe with shape (2000000, 132). Let's concentrate in the first window: it has 50k rows and the 132 columns so its shape is (50000, 132). I ...