I’m pretty new to Pytorch and I’m struggling at the moment with the mini-btach parameter for LSTM
Imagine I have the following sequenz:
input = Variable(torch.Tensor([1,2,3,4,5,6,7,8,9,10]))
As far as I know, using one batch I can do:
input.view_(10, -1, 1)
If I would pass this to LSTM, i would first get the h_t for the input 1, then 2, then 3 and so on, right?
But what if I shape the input like this:
input.view_(-1, 2, 1) # it is somethin like: [ [,], [,]...]
How does the LSTM work on that input. The first shape parameter would be 5 now, but actually I still have a seq_length of 10 (1-10) ??
Thanks for explaining