This API is used to compute the bitwise OR of each element in the input tensor self and the input scalar other. The input
[object Object]and[object Object]must be of the INT or BOOL type. For the BOOL type, the operator computes the logical OR.Formula:
[object Object] and [object Object] implement the same function in different ways. Select a proper operator based on your requirements.
[object Object]: An output tensor object needs to be created to store the computation result.[object Object]: No output tensor object needs to be created, and the computation result is written in place to the input tensor's memory.
Each operator is divided into two phases (../common/two-phase-api.md). You must call aclnnBitwiseOrScalarGetWorkspaceSize or aclnnInplaceBitwiseOrScalarGetWorkspaceSize to obtain the workspace size required for computation and the executor that contains the operator execution process, and then call aclnnBitwiseOrScalar or aclnnInplaceBitwiseOrScalar to perform the computation.
Parameters:
[object Object]Returns:
[object Object]: status code. For details, see .The first-phase API performs input parameter validation. The following errors may be returned:
[object Object]
Parameters:
[object Object]Returns:
[object Object]: status code. For details, see .The first-phase API performs input parameter validation. The following errors may be returned:
[object Object]
- Deterministic computation:
[object Object]and[object Object]each default to a deterministic implementation.
The following example is for reference only. For details, see .
aclnnInplaceBitwiseOrScalar sample code: