Class DynamicQuant

Inheritance Relationships

Base Type

  • public mindspore::ops::BaseOperator

Class Documentation

class DynamicQuant : public mindspore::ops::BaseOperator

the DynamicQuant operator prototype.

Public Functions

inline DynamicQuant()

Constructor.

void Init(const bool symmetric, const int64_t dst_type)

Method to init the op's attributes.

参数
  • symmetric[in] Define whether symmetric quantization.

  • dst_type[in] Define the data type of output.

void set_symmetric(const bool symmetric)

Method to set symmetric attribute.

参数

symmetric[in] Define whether symmetric quantization.

bool get_symmetric() const

Method to get symmetric attribute.

返回

Whether symmetric quantization.

void set_dst_type(const int64_t dst_type)

Method to set dst_type attribute.

参数

dst_type[in] Define the data type of output.

int64_t get_dst_type() const

Method to get dst_type attribute.

返回

the data type of output.

void set_prefer_axis(const int64_t prefer_axis)

Method to set prefer_axis attribute.

参数

prefer_axis[in] Define the preferred axis.

int64_t get_prefer_axis() const

Method to get prefer_axis attribute.

返回

the preferred axis.

void set_activation_channel(const bool activation_channel)

Method to set activation_channel attribute.

参数

activation_channel[in] Define whether activation perchannel quantization.

bool get_activation_channel() const

Method to get activation_channel attribute.

返回

Whether activation perchannel quantization.

void set_transpose(const bool transpose)

Method to set transpose attribute.

参数

symmetric[in] Define whether transpose matrix.

bool get_transpose() const

Method to get transpose attribute.

返回

Whether transpose matrix.

void set_prefer_axes(const std::vector<int> &prefer_axes)

Method to set prefer_axis attribute.

参数

prefer_axis[in] Define the preferred axis.

std::vector<int> get_prefer_axes() const

Method to get prefer_axis attribute.

返回

the preferred axis.