I have train, validation and test datasets from the original corpora of images. Some of these images are grascale, some RGB and the grayscale images are converted to RGB using tf.image.grayscale_to_rgb(image). These images are then processed using tf.keras.applications.resnet_v2.preprocess_input. I need to evaluate using the test dataset and show the result by plotting the images. How to restore those images which have been processed? The challenge here is to undo/reverse the operation done by both of these library functions.
Hi @khteh, You can restore those images, with reversed preprocessing formula - (preprocessed + 1.0) * 127.5 . Thanks!