[object Object]

[object Object][object Object]undefined
[object Object]
  • Description: Converts the input scale data from FLOAT32 type to UINT64 type required by the hardware, and stores the data in quantParam.
  • Formula:
    1. [object Object] is in 64-bit format and is initialized to 0.

    2. The higher 19 bits of [object Object] are truncated and stored in bit 32 of [object Object], and bit 46 is changed to 1.

      out=out  (scale & 0xFFFFE000)  (146)out = out\ |\ (scale\ \&\ 0xFFFFE000)\ |\ (1\ll46)
    3. The subsequent computation is performed based on the value of [object Object].

      • If [object Object] does not exist, no subsequent computation is performed.
      • If [object Object] exists:
        1. The value of [object Object] is converted to an int value in the range of [–256, 255].

          offset=Max(Min(INT(Round(offset)),255),256)offset = Max(Min(INT(Round(offset)),255),-256)
        2. Nine bits of [object Object] are retained and stored in bits 37 to 45 of out.

          out=(out & 0x4000FFFFFFFF)  ((offset & 0x1FF)37)out = (out\ \&\ 0x4000FFFFFFFF)\ |\ ((offset\ \&\ 0x1FF)\ll37)
[object Object]
[object Object]
[object Object]
  • Parameters:

    [object Object]
  • Returns:

    [object Object]: status code. For details, see .

    The API implements input parameter verification. The following errors may be thrown:

    [object Object]
[object Object]
  • Deterministic compute:
    • aclnnTransQuantParam defaults to a deterministic implementation.
[object Object]

The following example is for reference only. For details, see .

[object Object]