I tried x.unsqueeze(0) in the forward before it gets passed into the LSTM, but that did not work. Doesnt this create a batch size?



 Dwight_Foster:

hs = self.init_state(batch_size)
x, hs = self.lstm(x,hs)