eraseΒΆ
- torchvision.transforms.functional.erase(img: Tensor, i: int, j: int, h: int, w: int, v: Tensor, inplace: bool = False) Tensor [source]ΒΆ
Erase the input Tensor Image with given value. This transform does not support PIL Image.
- Parameters:
img (Tensor Image) β Tensor image of size (C, H, W) to be erased
i (int) β i in (i,j) i.e coordinates of the upper left corner.
j (int) β j in (i,j) i.e coordinates of the upper left corner.
h (int) β Height of the erased region.
w (int) β Width of the erased region.
v β Erasing value.
inplace (bool, optional) β For in-place operations. By default, is set False.
- Returns:
Erased image.
- Return type:
Tensor Image