Hi all,
I want to build a simple LSTM model and am a bit confused about the 3D input dimensions. According to the pytorch documentation the 3 dimensions represent (seq_len, batch, input_size). However, I cannot figure out why I need both the sequence length and the batch size here. Say, I have a 5 dimensional timeseries, that is, 5 feature dimensions. The timeseries has a total length of, say, 1000, with a batch size of 100. So I have read in some other threads, that in this case my input tensor would be (10, 100, 5) (I think). But does that mean that I feed my entire timeseries in at once in that 3D tensor?
Is there a certain reason why the LSTM would take the whole timeseries at once in a 3D tensor?
What would I be doing if I just want to do the splitting in batches in the train function as usual, i.e., that I iterate over the dataloader and sample batches of size 100 which I feed into the forward method of the LSTM?
Best wishes and thank you in advance!