[object Object]

[object Object][object Object]undefined
[object Object]

Description: Takes selfRef as a one-dimensional tensor and uses the element value in the index tensor as the index. If accumulate is true, the elements in source and the elements in the corresponding positions of selfRef are accumulated. If accumulate is false, the elements in source replace the elements in the corresponding positions of selfRef.

[object Object]

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

  • [object Object]
  • [object Object]
[object Object]
  • Parameters:

    • selfRef (aclTensor*, compute input): aclTensor on the device. The supported data types are as follows:
      • When accumulate is true, the data type can be FLOAT16, FLOAT, BOOL, INT8, UINT8, INT16, INT32, INT64, DOUBLE, COMPLEX64, or COMPLEX128.
      • When accumulate is false, are supported, and the supports ND. The supported data types are as follows:
        • [object Object]Atlas A2 training products/Atlas A2 inference products[object Object] and [object Object]Atlas A3 training series products/Atlas A3 inference series products[object Object]: The data type can be BOOL, FLOAT, FLOAT16, BFLOAT16, DOUBLE, INT8, INT16, INT32, INT64, UINT8, COMPLEX64, or COMPLEX128.
        • [object Object]Atlas inference series products[object Object] and [object Object]Atlas training series products[object Object]: The data type can be BOOL, FLOAT, FLOAT16, DOUBLE, INT8, INT16, INT32, INT64, UINT8, COMPLEX64, or COMPLEX128.
    • index (aclTensor*, compute input): aclTensor on the device. The data type can be INT32 or INT64. The number of elements must be the same as that of source. are supported, and the supports ND. Index data in index cannot be out of range.
    • source (aclTensor*, compute input): aclTensor on the device. The data type is the same as that of selfRef, and the number of elements is the same as that of index. are supported, and the supports ND.
    • accumulate (bool, compute input): Boolean type on the host.
    • workspaceSize (uint64_t*, output): size of the workspace to be allocated on the device.
    • executor (aclOpExecutor**, output): operator executor, containing the operator computation process.
  • Returns:

    aclnnStatus: status code. For details, see .

[object Object]
[object Object]
  • Parameters:

    • workspace: 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 the first-phase API aclnnInplacePutGetWorkspaceSize.
    • stream (aclrtStream, input): stream for executing the task.
    • executor (aclOpExecutor *, input): operator executor, containing the operator computation process.
  • Returns:

    aclnnStatus: status code. For details, see .

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

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

[object Object]