Specifying incorrect input dimensions for image classification

What is the behaviour of Keras if an input dimension of (x, y) is specified but an image with dimensions (x', y') are introduced to the first layer of a sequential model?

Posted Apr 6, 2017, 6:20 PM UTC

01
barnyardman•

You'll get a shape mismatch. Your defined shape and the input shape need to match.

If you want to use a new shape with a model you'll be introducing new parameters which will need to be trained.

Transfer learning requires images of the same shape, luckily reshaping is super easy.

2