Skip to content

🐍 Geometric Computer Vision Library for Spatial AI

docs(augmentation): remove incorrect per-channel fill claim from RandomCrop3D and RandomCrop (#4694)

li-lizhe138e91394b5a
diff --git a/kornia/augmentation/_2d/geometric/crop.py b/kornia/augmentation/_2d/geometric/crop.py
index b7931baed..a50475be2 100644
--- a/kornia/augmentation/_2d/geometric/crop.py
+++ b/kornia/augmentation/_2d/geometric/crop.py
@@ -49,8 +49,7 @@ class RandomCrop(GeometricAugmentationBase2D):
pad_if_needed: It will F.pad the image if smaller than the
desired size to avoid raising an exception. Since cropping is done
after padding, the padding seems to be done at a random offset.
- fill: Pixel fill value for constant fill. Default is 0. If a tuple of
- length 3, it is used to fill R, G, B channels respectively.
+ fill: Pixel fill value for constant fill. Default is 0.
This value is only used when the padding_mode is constant.
padding_mode: Type of padding. Should be: constant, reflect, replicate.
resample: the interpolation mode.
diff --git a/kornia/augmentation/_3d/geometric/crop.py b/kornia/augmentation/_3d/geometric/crop.py
index df5718dc1..1e754dbda 100644
--- a/kornia/augmentation/_3d/geometric/crop.py
+++ b/kornia/augmentation/_3d/geometric/crop.py
@@ -46,8 +46,7 @@ class RandomCrop3D(GeometricAugmentationBase3D):
pad_if_needed: It will F.pad the image if smaller than the
desired size to avoid raising an exception. Since cropping is done
after padding, the padding seems to be done at a random offset.
- fill: Pixel fill value for constant fill. Default is 0. If a tuple of
- length 3, it is used to fill R, G, B channels respectively.
+ fill: Pixel fill value for constant fill. Default is 0.
This value is only used when the padding_mode is constant.
padding_mode: Type of padding. Should be: constant, edge, reflect or symmetric. Default is constant.
resample: resample mode from "nearest" (0) or "bilinear" (1).