@@ -434,7 +434,7 @@ class Pad(Transform):
434
434
.. note::
435
435
In torchscript mode padding as single int is not supported, use a sequence of
436
436
length 1: ``[padding, ]``.
437
- fill (number or tuple or dict, optional): Pixel fill value used when the ``padding_mode`` is constant .
437
+ fill (number or tuple or dict, optional): Pixel fill value used for pixels outside the image boundary .
438
438
Default is 0. If a tuple of length 3, it is used to fill R, G, B channels respectively.
439
439
Fill value can be also a dictionary mapping data type to the fill value, e.g.
440
440
``fill={tv_tensors.Image: 127, tv_tensors.Mask: 0}`` where ``Image`` will be filled with 127 and
@@ -509,7 +509,7 @@ class RandomZoomOut(_RandomApplyTransform):
509
509
the image can have ``[..., C, H, W]`` shape. A bounding box can have ``[..., 4]`` shape.
510
510
511
511
Args:
512
- fill (number or tuple or dict, optional): Pixel fill value used when the ``padding_mode`` is constant .
512
+ fill (number or tuple or dict, optional): Pixel fill value used for pixels outside the image boundary .
513
513
Default is 0. If a tuple of length 3, it is used to fill R, G, B channels respectively.
514
514
Fill value can be also a dictionary mapping data type to the fill value, e.g.
515
515
``fill={tv_tensors.Image: 127, tv_tensors.Mask: 0}`` where ``Image`` will be filled with 127 and
@@ -586,7 +586,7 @@ class RandomRotation(Transform):
586
586
center of rotation. In practice however, due to numerical precision, this can lead to off-by-one
587
587
differences of the resulting image size compared to using the image center in the first place. Thus, when
588
588
setting ``expand=True``, it's best to leave ``center=None`` (default).
589
- fill (number or tuple or dict, optional): Pixel fill value used when the ``padding_mode`` is constant .
589
+ fill (number or tuple or dict, optional): Pixel fill value used for pixels outside the image boundary .
590
590
Default is 0. If a tuple of length 3, it is used to fill R, G, B channels respectively.
591
591
Fill value can be also a dictionary mapping data type to the fill value, e.g.
592
592
``fill={tv_tensors.Image: 127, tv_tensors.Mask: 0}`` where ``Image`` will be filled with 127 and
@@ -664,7 +664,7 @@ class RandomAffine(Transform):
664
664
:class:`torchvision.transforms.InterpolationMode`. Default is ``InterpolationMode.NEAREST``.
665
665
If input is Tensor, only ``InterpolationMode.NEAREST``, ``InterpolationMode.BILINEAR`` are supported.
666
666
The corresponding Pillow integer constants, e.g. ``PIL.Image.BILINEAR`` are accepted as well.
667
- fill (number or tuple or dict, optional): Pixel fill value used when the ``padding_mode`` is constant .
667
+ fill (number or tuple or dict, optional): Pixel fill value used for pixels outside the image boundary .
668
668
Default is 0. If a tuple of length 3, it is used to fill R, G, B channels respectively.
669
669
Fill value can be also a dictionary mapping data type to the fill value, e.g.
670
670
``fill={tv_tensors.Image: 127, tv_tensors.Mask: 0}`` where ``Image`` will be filled with 127 and
@@ -780,7 +780,8 @@ class RandomCrop(Transform):
780
780
pad_if_needed (boolean, optional): It will pad the image if smaller than the
781
781
desired size to avoid raising an exception. Since cropping is done
782
782
after padding, the padding seems to be done at a random offset.
783
- fill (number or tuple or dict, optional): Pixel fill value used when the ``padding_mode`` is constant.
783
+ fill (number or tuple or dict, optional): Pixel fill value used for pixels outside the image boundary.
784
+
784
785
Default is 0. If a tuple of length 3, it is used to fill R, G, B channels respectively.
785
786
Fill value can be also a dictionary mapping data type to the fill value, e.g.
786
787
``fill={tv_tensors.Image: 127, tv_tensors.Mask: 0}`` where ``Image`` will be filled with 127 and
@@ -927,7 +928,7 @@ class RandomPerspective(_RandomApplyTransform):
927
928
:class:`torchvision.transforms.InterpolationMode`. Default is ``InterpolationMode.BILINEAR``.
928
929
If input is Tensor, only ``InterpolationMode.NEAREST``, ``InterpolationMode.BILINEAR`` are supported.
929
930
The corresponding Pillow integer constants, e.g. ``PIL.Image.BILINEAR`` are accepted as well.
930
- fill (number or tuple or dict, optional): Pixel fill value used when the ``padding_mode`` is constant .
931
+ fill (number or tuple or dict, optional): Pixel fill value used for pixels outside the image boundary .
931
932
Default is 0. If a tuple of length 3, it is used to fill R, G, B channels respectively.
932
933
Fill value can be also a dictionary mapping data type to the fill value, e.g.
933
934
``fill={tv_tensors.Image: 127, tv_tensors.Mask: 0}`` where ``Image`` will be filled with 127 and
@@ -1028,7 +1029,7 @@ class ElasticTransform(Transform):
1028
1029
:class:`torchvision.transforms.InterpolationMode`. Default is ``InterpolationMode.BILINEAR``.
1029
1030
If input is Tensor, only ``InterpolationMode.NEAREST``, ``InterpolationMode.BILINEAR`` are supported.
1030
1031
The corresponding Pillow integer constants, e.g. ``PIL.Image.BILINEAR`` are accepted as well.
1031
- fill (number or tuple or dict, optional): Pixel fill value used when the ``padding_mode`` is constant .
1032
+ fill (number or tuple or dict, optional): Pixel fill value used for pixels outside the image boundary .
1032
1033
Default is 0. If a tuple of length 3, it is used to fill R, G, B channels respectively.
1033
1034
Fill value can be also a dictionary mapping data type to the fill value, e.g.
1034
1035
``fill={tv_tensors.Image: 127, tv_tensors.Mask: 0}`` where ``Image`` will be filled with 127 and
0 commit comments