def per_image_standardizer(self, image): stand = SamplewiseStandardizer(clip=6) image = tf.py_func(stand, [tf.to_double(image), False], tf.float64) return image