GaussianBlur¶
- class torchaug.transforms.GaussianBlur(kernel_size, sigma=(0.1, 2.0), batch_inplace=False, batch_transform=False)[source]¶
Blurs image with randomly chosen Gaussian blur.
If the input is a Tensor, it is expected to have […, C, H, W] shape, where … means an arbitrary number of leading dimensions.
- Parameters:
kernel_size (
Union[int,Sequence[int]]) – Size of the Gaussian kernel.sigma (
Union[int,float,Sequence[float]], optional) – Standard deviation to be used for creating kernel to perform blurring. If float, sigma is fixed. If it is tuple of float (min, max), sigma is chosen uniformly at random to lie in the given range. Default:(0.1, 2.0)batch_inplace (
bool, optional) – whether to apply the batch transform in-place. Does not prevent functionals to make copy but can reduce time and memory consumption. Default:Falsebatch_transform (
bool, optional) – whether to apply the transform in batch mode. Default:False