mindspore.dataset.vision.py_transforms.HsvToRgb

class mindspore.dataset.vision.py_transforms.HsvToRgb(is_hwc=False)[source]

Convert a NumPy HSV image or one batch NumPy HSV images to RGB images.

Parameters

is_hwc (bool) – The flag of image shape, (H, W, C) or (N, H, W, C) if True and (C, H, W) or (N, C, H, W) if False (default=False).

Examples

>>> import mindspore.dataset.vision.py_transforms as py_vision
>>> from mindspore.dataset.transforms.py_transforms import Compose
>>>
>>> Compose([py_vision.Decode(),
>>>          py_vision.CenterCrop(20),
>>>          py_vision.ToTensor(),
>>>          py_vision.HsvToRgb()])