|
Open Deep Learning API
|
Go to the source code of this file.
Data Structures | |
| struct | odla_value_quant_info |
| Quantization info for each odla value. More... | |
Functions | |
| ODLA_API_EXPORT odla_value ODLA_API_CALL | odla_Dequantize (odla_value input, odla_value scale, odla_value zero_point, odla_int32 axis, odla_element_type target_data_type, const odla_value_id value_id) |
| Dequantize a tensor. More... | |
| ODLA_API_EXPORT odla_value ODLA_API_CALL | odla_Quantize (odla_value input, odla_value scale, odla_value zero_point, odla_int32 axis, odla_element_type target_data_type, const odla_value_id value_id) |
| Quantize a tensor. More... | |
This file defines the ODLA quantization related operators.
Definition in file odla_ops_quantization.h.
| ODLA_API_EXPORT odla_value ODLA_API_CALL odla_Dequantize | ( | odla_value | input, |
| odla_value | scale, | ||
| odla_value | zero_point, | ||
| odla_int32 | axis, | ||
| odla_element_type | target_data_type, | ||
| const odla_value_id | value_id | ||
| ) |
Dequantize a tensor.
Converts a quantized tensor to the full precision tensor.
| input | the input value |
| scale | scale for input |
| zero_point | zero point for input |
| axis | the axis of the dequantizing. Ignored if scale is a scalar |
| target_data_type | the data type of full precision output |
| value_id | a unique value id (can be NULL) |
| ODLA_API_EXPORT odla_value ODLA_API_CALL odla_Quantize | ( | odla_value | input, |
| odla_value | scale, | ||
| odla_value | zero_point, | ||
| odla_int32 | axis, | ||
| odla_element_type | target_data_type, | ||
| const odla_value_id | value_id | ||
| ) |
Quantize a tensor.
Converts a tensor to low precision tensor.
| input | the input value |
| scale | scale for input |
| zero_point | zero point for input |
| axis | the axis of the quantizing. Ignored if scale is a scalar |
| target_data_type | the data type of low precision output |
| value_id | a unique value id (can be NULL) |