问题
I have the following LSTM model where I input my time-series to the LSTM layer. The other input (which is the dense
layer) contains the 10 features
I manually extracted from the time-series.
input1 = Input(shape=(26,6))
x1 = LSTM(100)(input1)
input2 = Input(shape=(10,1))
x2 = Dense(50)(input2)
x = concatenate([x1,x2])
x = Dense(200)(x)
output = Dense(1, activation='sigmoid')(x)
model = Model(inputs=[input1,input2], outputs=output)
I thought that the performance of my model will hugely increase with the features layer. However, it did not.
I was thinking the way I included the features to the model is primitive and needs more creativity with new layers (e.g., instead of Dense
). I thought that it is great to get your feedback to have my features more efficiently into the LSTM model.
I am happy to provide more details if needed.
来源:https://stackoverflow.com/questions/60895974/how-to-efficiently-connect-features-to-lstm-model