Как соединить реккурентные слои с одномерной свёрткой и полносвязными слоями
Пыталась создать архитектуру, Но выдает ошибку, как учесть размерность между слоями?
model.add(Embedding(max_words, 8, input_length=maxlen))
model.add(LSTM(32))
model.add(Conv1D(128, 3))
model.add(Dense(1, activation='sigmoid'))
---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
<ipython-input-15-d4ca4b2095b5> in <module>()
2 model.add(Embedding(max_words, 8, input_length=maxlen))
3 model.add(LSTM(32))
----> 4 model.add(Conv1D(128, 3))
5 model.add(Dense(1, activation='sigmoid'))
4 frames
/usr/local/lib/python3.6/dist-packages/tensorflow/python/keras/engine/input_spec.py in assert_input_compatibility(input_spec, inputs, layer_name)
194 ', found ndim=' + str(ndim) +
195 '. Full shape received: ' +
--> 196 str(x.shape.as_list()))
197 # Check dtype.
198 if spec.dtype is not None:
ValueError: Input 0 of layer conv1d is incompatible with the layer: : expected min_ndim=3, found ndim=2. Full shape received: [None, 32]