I've read many tutorial about LSTM , but all of them use 1 timestep .

this is my code:

X_trainset = np.reshape(X_trainset, (X_trainset.shape[0], 1, X_trainset.shape[1]))

for x in range(epoch):
    used_model.fit(X_trainset, y_trainset, epochs=1,batch_size=batch_size,verbose=2 ,shuffle=False)

i want to try to use 10 timestep but i dont know how to do that

in the past, i've read tutorial to do that in stackoverflow but, i cant find it anymore ( i forgot the keyword )

1 Answers

0
hhz On

Just build a LSTM model with 10 nodes:

model=Model(inputs,LSTM(10,activations='tanh')(inputs))

Then feed your data into it.