I am a beginner to transfer learning, In this project i aimed to use VGG16 and add some more layers to do a classification between 2 classes: class0 and class1
I have dataframe named 'train' with 'id' column contains file names while label contains class of that image
Images and prepared through ImageDataGenerator() and flow.from_dataframe
To summarise, the last layer of mine was Dense(2,activation='softmax')
The input image to VGG16 has shape of (32,32,3)
However, it kepts being error:
ValueError: Error when checking target: expected dense_55 to have 2 dimensions, but got array with shape (1, 32, 32, 3)
A summary of my model:
Here was my jupyter notebook for training.
what is wrong with my coding here?