Class RandomApply
Defined in File transforms.h
Inheritance Relationships
Base Type
public mindspore::dataset::TensorTransform
(Class TensorTransform)
Class Documentation
-
class RandomApply : public mindspore::dataset::TensorTransform
Randomly perform a series of transforms with a given probability.
Public Functions
-
explicit RandomApply(const std::vector<TensorTransform*> &transforms, double prob = 0.5)
Constructor.
- Parameters
transforms – [in] A vector of raw pointers to TensorTransform objects to be applied.
prob – [in] The probability to apply the transformation list (default=0.5).
Constructor.
- Parameters
transforms – [in] A vector of shared pointers to TensorTransform objects to be applied.
prob – [in] The probability to apply the transformation list (default=0.5).
-
explicit RandomApply(const std::vector<std::reference_wrapper<TensorTransform>> &transforms, double prob = 0.5)
Constructor.
- Parameters
transforms – [in] A vector of TensorTransform objects to be applied.
prob – [in] The probability to apply the transformation list (default=0.5).
-
~RandomApply() = default
Destructor.
-
explicit RandomApply(const std::vector<TensorTransform*> &transforms, double prob = 0.5)