RandomFlipUD#
- class tonic.transforms.RandomFlipUD(sensor_size: Tuple[int, int, int], p: float = 0.5)[source]#
Flips events in y with probability p. Pixels map as:
y’ = height - y
- Parameters:
sensor_size (Tuple[int, int, int]) – a 3-tuple of x,y,p for sensor_size
p (float) – probability of performing the flip
Example
>>> transform = tonic.transforms.RandomFlipUD(p=0.3)