Class RandomAdjustSharpness

Inheritance Relationships

Base Type

Class Documentation

class RandomAdjustSharpness : public mindspore::dataset::TensorTransform

Randomly adjust the sharpness of the input image with a given probability.

Public Functions

explicit RandomAdjustSharpness(float degree, float prob = 0.5)

Constructor.

Parameters
  • degree[in] A float representing sharpness adjustment degree, which must be non negative.

  • prob[in] A float representing the probability of the image being sharpness adjusted, which must in range of 0, 1.

Example
/* Define operations */
auto decode_op = vision::Decode();
auto random_adjust_sharpness_op = vision::RandomAdjustSharpness(30.0);

/* dataset is an instance of Dataset object */
dataset = dataset->Map({decode_op, random_adjust_sharpness_op},  // operations
                       {"image"});                               // input columns
~RandomAdjustSharpness() = default

Destructor.