How to perform tf.image.per_image_standardization on a batch of images in a tensor stream

I would like to know how to perform image whitening on a batch of images.

According to the documentation at https://www.tensorflow.org/api_docs/python/tf/image/per_image_standardization it is said that tf.image.per_image_standardization accepts a three-dimensional tensor, that is, an image, of the form: [height, width, channels] .

Is this a missing function or is there another method?

Any help is greatly appreciated.

+7
batch-processing tensorflow
source share
1 answer

Here's how to perform this operation in an image package.

tf.map_fn(lambda frame: tf.image.per_image_standardization(frame), frames)

+6
source share