vis4d.data.transforms.photometric¶
Photometric transforms.
Classes
|
Apply color jitter to images. |
|
Apply Brightness transformation to images. |
|
Apply Contrast transformation to images. |
|
Apply Gamma transformation to images. |
|
Apply HSV transformation to images. |
|
Apply hue transformation to images. |
|
Apply saturation transformation to images. |
- class ColorJitter(*, in_keys=['images'], out_keys=['images'], sensors=None, same_on_batch=True, **kwargs)[source]¶
Apply color jitter to images.
- Parameters:
brightness_range (tuple[float, float]) – Range of brightness values.
contrast_range (tuple[float, float]) – Range of contrast values.
saturation_range (tuple[float, float]) – Range of saturation values.
hue_range (tuple[float, float]) – Range of hue values.
image_channel_mode (str, optional) – Image channel mode. Defaults to “RGB”.
- class RandomBrightness(*, in_keys=['images'], out_keys=['images'], sensors=None, same_on_batch=True, **kwargs)[source]¶
Apply Brightness transformation to images.
- Parameters:
brightness_range (tuple[float, float]) – Range of brightness values.
image_channel_mode (str, optional) – Image channel mode. Defaults to “RGB”.
- class RandomContrast(*, in_keys=['images'], out_keys=['images'], sensors=None, same_on_batch=True, **kwargs)[source]¶
Apply Contrast transformation to images.
- Parameters:
contrast_range (tuple[float, float]) – Range of contrast values.
image_channel_mode (str, optional) – Image channel mode. Defaults to “RGB”.
- class RandomGamma(*, in_keys=['images'], out_keys=['images'], sensors=None, same_on_batch=True, **kwargs)[source]¶
Apply Gamma transformation to images.
- Parameters:
gamma_range (tuple[float, float]) – Range of gamma values.
image_channel_mode (str, optional) – Image channel mode. Defaults to “RGB”.
- class RandomHSV(*, in_keys=['images'], out_keys=['images'], sensors=None, same_on_batch=True, **kwargs)[source]¶
Apply HSV transformation to images.
Used by YOLOX. Modifed from: https://github.com/Megvii-BaseDetection/YOLOX.
- Parameters:
hue_delta (int) – Delta for hue.
saturation_delta (int) – Delta for saturation.
value_delta (int) – Delta for value.
image_channel_mode (str, optional) – Image channel mode. Defaults to “BGR”.
- class RandomHue(*, in_keys=['images'], out_keys=['images'], sensors=None, same_on_batch=True, **kwargs)[source]¶
Apply hue transformation to images.
- Parameters:
hue_range (tuple[float, float]) – Range of hue values.
image_channel_mode (str, optional) – Image channel mode. Defaults to “RGB”.
- class RandomSaturation(*, in_keys=['images'], out_keys=['images'], sensors=None, same_on_batch=True, **kwargs)[source]¶
Apply saturation transformation to images.
- Parameters:
saturation_range (tuple[float, float]) – Range of saturation values.
image_channel_mode (str, optional) – Image channel mode. Defaults to “RGB”.