inputs[0] = tf.keras.Input(shape=(train_data.shape[1], 1)) # 输入层
这是我定义的输入层,在运行一下的代码中:
inp=model2.inputs
functor = K.backend.function([inp, K.backend.learning_phase()], outputs)
总是会出现
ValueError: Input tensors to a Functional must come from `tf.keras.Input`. Received: 0 (missing previous layer metadata).
但是我确实是tf.keras.input定义的输入层呀,求各位大佬解答。