title: error: expected activation_4 to have 2 dimensions, but got array with shape (14, 3, 150, 150)
body: <p>I'm trying to use my own dataset that consists of two categories. I do not understand how can solve this. How can I fix this? it seems like the model gets the shape of the image as input instead of the actual image.</p>
  
  <pre><code>print X_train.shape
  print y_train.shape
  print X_test.shape
  print y_test.shape
  
  (55, 3, 150, 150)
  (55, 1)
  (14, 3, 150, 150)
  (14, 1)
  
  from keras.models import Sequential
  from keras.layers import Conv2D, MaxPooling2D
  from keras.layers import Activation, Dropout, Flatten, Dense
  from keras import backend as K
  K.set_image_dim_ordering('th')
  
  model = Sequential()
  #model.add(Convolution2D(32, kernel_size=(3, 3), input_shape=(3, IMG_SIZE, IMG_SIZE)))
  model.add(Conv2D(32, (3, 3), activation='relu', input_shape=(3,150,150)))
  #model.add(Activation('relu'))
  model.add(MaxPooling2D(pool_size=(2, 2)))
  
  model.add(Conv2D(32, 3, 3))
  model.add(Activation('relu'))
  model.add(MaxPooling2D(pool_size=(2, 2)))
  
  model.add(Conv2D(64, 3, 3))
  model.add(Activation('relu'))
  model.add(MaxPooling2D(pool_size=(2, 2)))
  
  model.add(Flatten())
  model.add(Dense(64))
  model.add(Activation('relu'))
  model.add(Dropout(0.5))
  model.add(Dense(num_classes))
  model.add(Activation('sigmoid'))
  
  model.compile(loss='categorical_crossentropy',
                optimizer='rmsprop',
                metrics=['accuracy'])
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/IdWoN.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/IdWoN.png" alt="model.summary()"></a></p>
  
  <pre><code>ValueError: Error when checking target: expected activation_4 to have 2 dimensions, but got array with shape (14, 3, 150, 150)
  </code></pre>