mindspore.dataset.vision.py_transforms.RandomSharpness

class mindspore.dataset.vision.py_transforms.RandomSharpness(degrees=(0.1, 1.9))[source]

Adjust the sharpness of the input PIL image by a random degree.

Parameters

degrees (sequence) – Range of random sharpness adjustment degrees. It should be in (min, max) format (default=(0.1,1.9)).

Examples

>>> import mindspore.dataset.vision.py_transforms as py_vision
>>> from mindspore.dataset.transforms.py_transforms import Compose
>>>
>>> Compose([py_vision.Decode(),
>>>          py_vision.RandomSharpness((0.5, 1.5)),
>>>          py_vision.ToTensor()])