title: Keras: expected dense_1_input to have shape (8,) but got array with shape (5,)
body: <p>I am getting an error message while trying to execute the below code for binary classification in Keras</p>
  
  <p>"Error when checking input: expected dense_1_input to have shape (8,) but got array with shape (5,)". I have specified input_dim = 5. Not sure what I am missing. Would really appreciate any help on this!   </p>
  
  <p>X_Train dataframe shape = (116020, 5)</p>
  
  <p>Y_Train dataframe shape = (116020, )</p>
  
  <p>My Code:</p>
  
  <pre><code>model.add(Dense(12,input_dim = 5, activation='relu'))
  model.add(Dense(15, activation='relu'))
  model.add(Dense(8, activation='relu'))
  model.add(Dense(10, activation='relu'))
  model.add(Dense(1, activation='sigmoid'))
  model.compile(loss="binary_crossentropy", optimizer = "adam", metrics = ['accuracy'])
  model.fit(X_train,Y_train, epochs = 1000, batch_size = 10)
  </code></pre>