Class Reduce

Inheritance Relationships

Base Type

  • public mindspore::ops::BaseOperator

Derived Type

Class Documentation

class Reduce : public mindspore::ops::BaseOperator

Reduce defined Reduce operator prototype of lite.

Subclassed by mindspore::ops::ReduceFusion

Public Functions

inline Reduce()

Constructor.

inline explicit Reduce(const std::string k_name)

Constructor.

void Init(const bool keep_dims = false, const bool skip_mode = false)

Method to init the op's attributes.

Parameters
  • keep_dims[in] Define whether keep the dims reduced, default false.

  • skip_mode[in] Define whether skip reduce, default false.

void set_keep_dims(const bool keep_dims)

Method to set keep_dims attribute.

Parameters

keep_dims[in] Define whether keep the dims reduced, default false.

bool get_keep_dims() const

Method to get keep_dims attribute.

Returns

keep_dims attribute.

void set_skip_mode(const bool skip_mode)

Method to set skip_mode attribute.

Parameters

skip_mode[in] Define whether skip reduce, default false.

bool get_skip_mode() const

Method to get skip_mode attribute.

Returns

skip_mode attribute.