These assume you have already converted images into a three channel, 224 by 224 matrix with load_img and img_to_array. The processing differs based on the model so set the appropriate model that you are using.
preprocess_input(img, model = c("Xception", "VGG16", "VGG19", "ResNet50",
"InceptionV3"))
the input image, as an array
the model you wish to preprocess to
Taylor B. Arnold, taylor.arnold@acm.org
Chollet, Francois. 2015. Keras: Deep Learning library for Theano and TensorFlow.