This document is relevant for: Trn2, Trn3

nki.language.left_shift#

nki.language.left_shift(x, y, dtype=None)[source]#

Left shift the bits of x by y positions element-wise.

((Similar to numpy.left_shift))

Warning

This API is experimental and may change in future releases.

Inputs must be integer typed.

Parameters:
  • x – a tile or a scalar value.

  • y – a tile or a scalar value. At least one of x, y must be a tile.

  • dtype – (optional) data type to cast the output type to (see Supported Data Types for more information);

Returns:

a tile with the left-shifted result.

This document is relevant for: Trn2, Trn3