Scale¶
Struct for scale values.
Attributes¶
| Name | Description |
|---|---|
scale_list |
|
scale |
|
is_uniform |
|
zero_points |
Per-channel zero points for asymmetric quantization. |
zero_point |
Uniform zero point for asymmetric quantization. |
is_asymmetric |
Indicates whether asymmetric quantization is used. |
scale_list¶
scale¶
is_uniform¶
zero_points¶
Per-channel zero points for asymmetric quantization.
zero_point¶
Uniform zero point for asymmetric quantization.
is_asymmetric¶
Indicates whether asymmetric quantization is used.
Methods¶
| Name | Description |
|---|---|
__init__ |
|
from_cpp |
|
__getitem__ |
Returns the scale value at the specified index. |
__repr__ |
__init__¶
def __init__(
self,
scale: float,
is_uniform: bool,
scale_list: List[float],
zero_point: int = 0,
is_asymmetric: bool = False,
zero_points: Optional[List[int]] = None,
)
from_cpp¶
__getitem__¶
Returns the scale value at the specified index.
Parameters
i[in] — Index.
Returns
Scale value.