Skip to main content

ClikaRT::ops::bitwise_right_shift

function

bitwise_right_shift()

Tensor bitwise_right_shift(Tensor a, ScalarOrTensor other)

Elementwise a >> other. Integer dtypes only (Bool refuses); otherwise dtype law as bitwise_and. ARITHMETIC (sign-propagating) for signed dtypes, logical for unsigned; the shift is a TOTAL function; a count outside [0, bit_width), negative included, yields the fully shifted-out value (sign fill 0/-1 for signed, 0 for unsigned), identically on every backend.

Returns: the broadcast-shaped shifted values at the shared dtype.

Throws

  • ClikaRT::Error: (INVALID_ARGUMENT) when the operand dtypes differ, for a floating-point or Bool operand, or broadcast-incompatible shapes.

Declared in ClikaRT/compute/ops.h, line 1616