ValueError:检查输入时出错:预期输入具有3个维度,但数组的形状为(100,1)

时间:2019-06-01 07:11:56

标签: keras model deep-learning

我一直在尝试建立一个模型,该模型可以接受形状(None,1)的输入并将形状输出为(None,1)。我的模型摘要如下:-


______________________________________________________________
Layer (type)                 Output Shape              Param #
=================================================================
input (InputLayer)           (1, None, 1)              0
_________________________________________________________________
dense1 (Dense)               (1, None, 32)             64
_________________________________________________________________
dense2 (Dense)               (1, None, 64)             2112
_________________________________________________________________
out (Dense)                  (1, None, 1)              65
=================================================================
Total params: 2,241
Trainable params: 2,241
Non-trainable params: 0
_________________________________________________________________

但是我遇到了错误

ValueError: Error when checking input: expected input to have 3 dimensions, but got array with shape (91912, 1)

我在这个问题上停留了很长时间。

0 个答案:

没有答案