fffa476e1e50ff0a59700a6fbfd3531d62fe692a,kornia/augmentation/augmentations.py,ColorJitter,forward,#ColorJitter#Any#Any#,190
Before Change
batch_size = input.shape[0] if len(input.shape) == 4 else 1
params = ColorJitter.get_params(batch_size, self.brightness, self.contrast, self.saturation, self.hue)
if isinstance(input, tuple):
jittered: torch.Tensor = cast(
torch.Tensor,
F.apply_color_jitter(
input[0],
params=params,
return_transform=False))
return jittered, input[1]
return F.apply_color_jitter(input, params, self.return_transform)
class RandomGrayscale(AugmentationBase):
After Change
if params is None:
batch_size = self.infer_batch_size(input)
params = ColorJitter.get_params(batch_size, self.brightness, self.contrast, self.saturation, self.hue)
return super().forward(input, params)
class RandomGrayscale(AugmentationBase):
rRandom Grayscale transformation according to a probability p value
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances Project Name: arraiy/torchgeometry
Commit Name: fffa476e1e50ff0a59700a6fbfd3531d62fe692a
Time: 2020-01-20
Author: sj8716643@126.com
File Name: kornia/augmentation/augmentations.py
Class Name: ColorJitter
Method Name: forward
Project Name: tensorlayer/tensorlayer
Commit Name: 9b2940f5c418a0315f6de32239021fa1532db319
Time: 2019-01-25
Author: zhangjqsmiling@gmail.com
File Name: tensorlayer/models/core.py
Class Name: Model
Method Name: __call__
Project Name: arraiy/torchgeometry
Commit Name: fffa476e1e50ff0a59700a6fbfd3531d62fe692a
Time: 2020-01-20
Author: sj8716643@126.com
File Name: kornia/augmentation/augmentations.py
Class Name: RandomGrayscale
Method Name: forward