Reputation: 23
I made a machine learning code in keras that is combination of cnn and lstm(merge)
Is just combination layers ensemble model?
from keras.layers import Dense, LSTM, Conv2D, Flatten, concatenate
lstmLayer = LSTM(10)(input)
cnnLayer = Conv2D(10, (3,3)(input)
flatLayer = Flatten()(cnnLayer)
cnnDense = Dense(10)(flatLayer)
concat = concatenate([lstmLayer, cnnDense])
output = Dense(1)(concat)
Upvotes: 0
Views: 169
Reputation: 56357
No, combining layers is not an ensemble, you can have different layers in one model. Only a combination of fully trained models is an ensemble.
Upvotes: 2