Python keras how to change the size of input after convolution layer into lstm layer

谁说我不能喝 提交于 2019-11-30 22:51:52

You can add Reshape() layer in between to make dimensions compatible.

http://keras.io/layers/core/#reshape

keras.layers.core.Reshape(dims)

Reshape an output to a certain shape.

Input shape

Arbitrary, although all dimensions in the input shaped must be fixed. Use the keyword argument input_shape (tuple of integers, does not include the samples axis) when using this layer as the first layer in a model.

Output shape

(batch_size,) + dims

Arguments

dims: target shape. Tuple of integers, does not include the samples dimension (batch size).

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!