[object Object]

[object Object][object Object]undefined
[object Object]
  • Description: Computes the logarithm of the sum of exponents (power of e) of input tensors.

  • Formula:

    out=log(ex+ey)=log[em(1+exy)]=m+log(1+exy),wherem=max(x,y)out = \log(e^x+e^y) = \log[e^m(1+e^{-|x-y|})] = m+\log(1+e^{-|x-y|}) \quad, where m = \max(x, y)

    xx indicates self, and yy indicates other.

[object Object]

Each operator has calls. First, aclnnLogAddExpGetWorkspaceSize is called to obtain the workspace size required for computation and the executor that contains the operator computation process. Then, aclnnLogAddExp is called to perform computation.

  • [object Object]

  • [object Object]

[object Object]
  • Parameters:

    • [object Object] (aclTensor*, compute input): xx in the formula, aclTensor on the device. The shape supports 0 to 8 dimensions. The data type must be convertible to that of out. For details, see . The shapes of self and other meet the . are supported. The can be ND.
      • [object Object]Atlas inference products[object Object] and [object Object]Atlas training products[object Object]: The data type can be FLOAT16, FLOAT, DOUBLE, UINT8, INT8, UINT16, INT16, UINT32, INT32, UINT64, INT64, or BOOL.
      • [object Object]Atlas A2 training products/Atlas A2 inference products[object Object] and [object Object]Atlas A3 training products/Atlas A3 inference products[object Object]: The data type can be FLOAT16, FLOAT, DOUBLE, UINT8, INT8, UINT16, INT16, UINT32, INT32, UINT64, INT64, BOOL, or BFLOAT16.
    • [object Object] (aclTensor*, compute input): yy in the formula, aclTensor on the device. The shape supports 0 to 8 dimensions. The data type must be convertible to that of out. For details, see . The shapes of self and other meet the . are supported. The can be ND.
      • [object Object]Atlas inference products[object Object] and [object Object]Atlas training products[object Object]: The data type can be FLOAT16, FLOAT, DOUBLE, UINT8, INT8, UINT16, INT16, UINT32, INT32, UINT64, INT64, or BOOL.
      • [object Object]Atlas A2 training products/Atlas A2 inference products[object Object] and [object Object]Atlas A3 training products/Atlas A3 inference products[object Object]: The data type can be FLOAT16, FLOAT, DOUBLE, UINT8, INT8, UINT16, INT16, UINT32, INT32, UINT64, INT64, BOOL, or BFLOAT16.
    • [object Object] (aclTensor*, compute output): outout in the formula, aclTensor on the device. The shape supports 0 to 8 dimensions, and must be the same as that after broadcasting is performed for self and other. are supported. The can be ND.
      • [object Object]Atlas inference products[object Object] and [object Object]Atlas training products[object Object]: The data type can be FLOAT16 or FLOAT.
      • [object Object]Atlas A2 training products/Atlas A2 inference products[object Object] and [object Object]Atlas A3 training products/Atlas A3 inference products[object Object]: The data type can be FLOAT16, FLOAT, or BFLOAT16.
    • [object Object] (uint64_t*, output): size of the workspace to be allocated on the device.
    • [object Object] (aclOpExecutor**, output): operator executor, covering the operator computation process.
  • Returns:

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

    [object Object]
[object Object]
  • Parameters:

    • [object Object] (void*, input): address of the workspace to be allocated on the device.
    • 'workspaceSize' (uint64_t, input): size of the workspace to be allocated on the device, which is obtained by calling the first-phase API aclnnLogAddExpGetWorkspaceSize.
    • [object Object] (aclOpExecutor*, input): operator executor, covering the operator computation process.
    • [object Object] (aclrtStream, input): stream for executing the task.
  • Returns:

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

[object Object]
  • Deterministic computation:
    • [object Object] defaults to deterministic implementation.
[object Object]

The following examples are for reference only. For details, see .

[object Object]