(self, features)
return image, label
Returns a 128x128x3 Tensor with constant label 0.
Returns a 128x128x3 Tensor with constant label 0.
Returns a 128x128x3 Tensor with constant label 0 .
def _parse_fn(self, features):
    """Returns a 128x128x3 Tensor with constant label 0."""
    image = features["image"]
    image = tf.image.resize_image_with_crop_or_pad(
        image, target_height=128, target_width=128)
    image = tf.cast(image, tf.float32) / 255.0
    label = tf.constant(0, dtype=tf.int32)
    return image, label
def _parse_fn ( self , features ) : image = features [ "image" ] image = tf . image . resize_image_with_crop_or_pad ( image , target_height = 128 , target_width = 128 ) image = tf . cast ( image , tf . float32 ) / 255.0 label = tf . constant ( 0 , dtype = tf . int32 ) return image , label