[object Object]

[object Object][object Object]undefined
[object Object]
  • Operator function: searches for the position where a given scalar value (self) should be inserted into a sorted 1D tensor (sortedSequence). Returns a tensor with shape [1], indicating the position where the given scalar value should be inserted into the original tensor. If self is of the tensor type, see the document.
  • The calculation formula is as follows: Assume that the length of the sequence to be searched is NN, and the scalar input is x=selfx = self.
    • When [object Object], the left insertion point is returned.
    out=min{j[0,N]sortedSequencejx}out=\min\{j\in[0,N]\mid sortedSequence_j\ge x\}
    • When [object Object], the right insertion point is returned.
    out=min{j[0,N]sortedSequencej>x}out=\min\{j\in[0,N]\mid sortedSequence_j>x\}

    If no jj that meets the condition exists, NN is returned.

[object Object]

Each operator has calls. First, the [object Object] API is called to obtain the workspace size required for computation and the executor that contains the operator computation flow. Then, the [object Object] API is called to perform computation.

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

    [object Object]
  • Return Value

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

    The first-phase API implements input parameter verification. The following errors may be thrown.

    [object Object]
[object Object]
  • Parameters

    [object Object]
  • Return Value

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

[object Object]
  • Deterministic description: The default deterministic implementation of [object Object] is used.
[object Object]

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

[object Object]