ValueError: Failed to find data adapter that can handle input: <class 'numpy.ndarray'>, (<class 'list'> containing values of types {"<class 'numpy.float64'>"})
之后,我添加了以下代码:
train_y= np.asarray(train_y) validation_y= np.asarray(validation_y)
train_y= np.asarray(train_y) validation_y= np.asarray(validation_y)
history = model.fit(
train_x, train_y,
batch_size=BATCH_SIZE,
epochs=EPOCHS,
validation_data=(validation_x, validation_y),
callbacks=[tensorboard, checkpoint])
但我收到此错误:
File "C:/Users/Enock/.spyder-py3/cryptoRnn.py", line 174
train_y= np.asarray(train_y) validation_y= np.asarray(validation_y)
^
SyntaxError: invalid syntax...
我该怎么办?