The dimension of the X_train is (7059, 22) and the y_train is (7059,). The dataset itself is a numerical weather dataset from Google cloud platform samples.gsod available publicly.
model = Sequential()
model.add(keras.Input(shape=(X_train.shape[1],1)))
model.add(keras.layers.SimpleRNN(100, return_sequences=True, activation="relu"))
model.add(keras.layers.SimpleRNN(75, activation="softmax"))
model.add(keras.layers.Dense(1))
model.compile(
loss=keras.losses.BinaryCrossentropy(from_logits=True),
optimizer=keras.optimizers.Adam(),
metrics=["accuracy"]
)
model.fit(X_train, y_train, batch_size=64, epochs=10, verbose=2)
model.evaluate(X_test, y_test, batch_size=64, verbose=2)
I get the following error ValueError: Input 0 of layer sequential_29 is incompatible with the layer: expected ndim=3, found ndim=2. Full shape received: [None, 22] when I run model.fit(). Can anyone help me out?