Apply a list of transformations randomly with a given probability

transform_random_apply(img, transforms, p = 0.5)

Arguments

img

A magick-image, array or torch_tensor.

transforms

(list or tuple): list of transformations.

p

(float): probability.