DequantizeLinear - 10 vs 13¶
Next section compares an older to a newer version of the same operator after both definition are converted into markdown text. Green means an addition to the newer version, red means a deletion. Anything else is unchanged.
DequantizeLinear10 → DequantizeLinear13
RENAMED
@@ -1 +1 @@
|
|
1
|
-
The linear dequantization operator. It consumes a quantized tensor, a scale, a zero point to compute the full precision tensor.
|
1
|
+
The linear dequantization operator. It consumes a quantized tensor, a scale, and a zero point to compute the full precision tensor.
|
2
|
-
The dequantization formula is y = (x - x_zero_point) * x_scale.
|
2
|
+
The dequantization formula is y = (x - x_zero_point) * x_scale. x_scale and x_zero_point must have same shape, and can be either a scalar
|
3
|
+
for per-tensor / per layer quantization, or a 1-D tensor for per-axis quantization.
|
3
|
-
|
4
|
+
x_zero_point and x must have same type. x and y must have same shape. In the case of dequantizing int32,
|
4
5
|
there's no zero point (zero point is supposed to be 0).
|
6
|
+
|
7
|
+
### Attributes
|
8
|
+
|
9
|
+
* **axis - INT** (default is '1'):
|
10
|
+
|
11
|
+
(Optional) The axis of the dequantizing dimension of the input tensor. Ignored for per-tensor quantization. Negative value means counting dimensions from the back. Accepted range is [-r, r-1] where r = rank(input).
|
5
12
|
### Inputs
|
6
13
|
Between 2 and 3 inputs.
|
7
14
|
- **x** (heterogeneous) - **T**:
|
8
15
|
N-D quantized input tensor to be de-quantized.
|
9
16
|
- **x_scale** (heterogeneous) - **tensor(float)**:
|
10
|
-
Scale for input 'x'. It
|
17
|
+
Scale for input 'x'. It can be a scalar, which means a per-tensor/layer dequantization, or a 1-D tensor for per-axis dequantization.
|
11
18
|
- **x_zero_point** (optional, heterogeneous) - **T**:
|
12
|
-
Zero point for input 'x'.
|
19
|
+
Zero point for input 'x'. Shape must match x_scale. It's optional. Zero point is 0 when it's not specified.
|
13
20
|
### Outputs
|
14
21
|
- **y** (heterogeneous) - **tensor(float)**:
|
15
22
|
N-D full precision output tensor. It has same shape as input 'x'.
|
16
23
|
### Type Constraints
|
17
24
|
* **T** in ( tensor(int32), tensor(int8), tensor(uint8) ):
|
18
25
|
Constrain 'x_zero_point' and 'x' to 8-bit/32-bit integer tensor.
|