

The ImageDataGenerator generates batches of tensor image-data with real-time augmentation.

The ImageDataGenerator class of Keras allows us to achieve the same. This will help us to create a larger training dataset and consequently will enable our model to converge more efficiently. Though these images look similar, they are considered as entirely new images by CNN (Convolutional Neural Network). In such situations, we can create new images out of the existing images, by applying transformations to them.

We use image augmentation when we don’t have enough training data to train our model. Image Augmentation is the process of expanding the image training data, by using transformations such as random rotations, shear transforms, shifts zooms and flips, on available image data.
