lstm - Many to one implementation in keras -
i trying implement many 1 model inputs word vectors of size d . need output vector of size d @ end of lstm .
in question , mentioned use(for many 1 model)
model = sequential() model.add(lstm(1, input_shape=(timesteps, data_dim))) i still doubtful how specify input , more importantly output dimensions in keras model
the code provided one-to-many scenario - output of size 1. if want have output of size d need try following code:
model = sequential() model.add(lstm(d, input_shape=(len_seq, d))) moreover - word vectors advise use embedding layer designed use case. use input lstm then.

Comments
Post a Comment