3.2.8. Quantizer parameters¶
The quantizer is a module that ensures the real numbers transformation from a floating-point representation to a fixed-point representation. This module is enabled only if the receiver part of the communication chain works on a fixed-point representation (cf. the --sim-prec, -p parameter).
Warning
Some decoders are not fixed-point ready, please refer to the decoders documentation for more details.
3.2.8.1. --qnt-type
¶
- Type
text
- Allowed values
CUSTOM
POW2
- Default
POW2
- Examples
--qnt-type CUSTOM
Select the quantizer type.
Description of the allowed values (\(Y_i\) stands for a floating-point representation and \(Q_i\) for the fixed-point representation of a real number):
Value |
Description |
---|---|
|
\(Q_i = \begin{cases} +v_{sat} & \text{when } v_i > +v_{sat} \\ -v_{sat} & \text{when } v_i < -v_{sat} \\ v_i & \text{else} \end{cases}\), with \(v_i = \lfloor \frac{Y_i}{\Delta} \rceil \text{ and } v_{sat} = 2^{p_b - 1} - 1 \text{ and } \Delta = \frac{|p_r|}{v_{sat}}\) |
|
\(Q_i = \begin{cases} +v_{sat} & \text{when } v_i > +v_{sat} \\ -v_{sat} & \text{when } v_i < -v_{sat} \\ v_i & \text{else} \end{cases}\), with \(v_i = \lfloor Y_i * F \rceil \text{ and } v_{sat} = 2^{p_b - 1} - 1 \text{ and } F = 2^{p_d}\) |
Where \(p_r\), \(p_b\) and \(p_d\) are respectively given through the --qnt-range, --qnt-bits and --qnt-dec parameters.
3.2.8.2. --qnt-implem
¶
- Type
text
- Allowed values
STD
FAST
- Default
STD
- Examples
--qnt-implem FAST
Select the implementation of the quantizer.
Description of the allowed values:
Value |
Description |
---|---|
|
Select a standard implementation. |
|
Select a fast implementation, only
available for the |
3.2.8.3. --qnt-range
¶
- Type
real number
- Examples
--qnt-range 1.0
Select the min/max bounds for the CUSTOM
quantizer.
3.2.8.4. --qnt-bits
¶
- Type
integer
- Default
8 else see Table 3.8
- Examples
--qnt-bits 1
Set the number of bits used in the fixed-point representation.
Note
If the amplitude of the current number exceeds the maximum amplitude that can be represented with the current quantization, then a saturation is applied (c.f. the --qnt-type parameter).
Code |
Value |
---|---|
|
6 |
|
6 |
|
6 |
|
6 |
|
6 |
|
6 on 8-bit and 8 on 16-bit |
|
6 |
|
6 |
3.2.8.5. --qnt-dec
¶
- Type
integer
- Default
3 else see Table 3.9
- Examples
--qnt-dec 1
Set the position of the decimal point in the quantified representation.
Code |
Value |
---|---|
|
2 |
|
1 |
|
2 |
|
1 on 8-bit and 3 on 16-bit |
|
1 on 8-bit and 3 on 16-bit |
|
2 on 8-bit and 3 on 16-bit |
|
2 on 8-bit and 3 on 16-bit |
|
2 on 8-bit and 3 on 16-bit |