bitwise_and

dragon.bitwise.bitwise_and(
  inputs,
  **kwargs
)[source]

Compute the element-wise AND bitwise operation.

\[\text{out} = \text{input1} \mathbin{\&} \text{input2} \]

Examples:

a = dragon.constant([0, -1, 2, -3, 4])
b = dragon.constant([-4, 3, -2, 1, 0])
print(dragon.bitwise.bitwise_and([a, b]))  # [0, 3, 2, 1, 0]
Parameters:
  • inputs (Sequence[dragon.Tensor]) – The input1 and input2 tensor.
Returns:

dragon.Tensor – The output tensor.