There is ImageDataGenerator.flow() function, in which we pass our training images and it returns augmented images. But what does ImageDataGenerator.fit() function does?
Asked
Active
Viewed 810 times
1 Answers
2
For some transformations such as centering or scaling, the ImageDataGenerator needs statistics on the data such the feature-wise mean, standard deviation etc. The fit()
method collects these statistics. This API is similar to how the preprocessing functions in scikit-learn work.

sdcbr
- 7,021
- 3
- 27
- 44