Search code examples
pythonkerasconv-neural-networkpre-trained-modeltransfer-learning

Does the accuracy of the deep learning program drop if I do not put in the default input shape into the pretrained model?


As the title says, I want to know whether input shape affects the accuracy of the deep learning model.

Also, can pre-trained models (like Xception) be used on grayscale images?

P.S. : I recently started learning deep learning so if possible please explain in simple terms.


Solution

  • Usually, with convolutional neural networks, differences in the image shape (the width/height of an image) will not matter. However, differences in the # of channels in the image (equivalently the depth of the image), will affect the performance. In fact, there will usually be dimension mismatch errors you get if the model was trained for greyscale/colour and you put in the other type.