View source on GitHub |
Apply cutout (https://arxiv.org/abs/1708.04552) to image.
tfm.vision.augment.cutout(
image: tf.Tensor, pad_size: int, replace: int = 0
) -> tf.Tensor
This operation applies a (2pad_size x 2pad_size) mask of zeros to
a random location within image
. The pixel values filled in will be of the
value replace
. The location where the mask will be applied is randomly
chosen uniformly over the whole image.
Returns | |
---|---|
An image Tensor that is of type uint8. |