ttnn.tilize

ttnn.tilize(input_tensor: ttnn.Tensor, *, memory_config: ttnn.MemoryConfig | None = None, dtype: data type | None = None, use_multicore: bool | None = True, queue_id: int | None = 0) ttnn.Tensor

Changes data layout of input tensor to TILE.

Input tensor must be on TT accelerator device, in ROW_MAJOR layout, and have BFLOAT16 data type.

Output tensor will be on TT accelerator device, in TILE layout, and have BFLOAT16 data type.

Parameters:

input_tensor (ttnn.Tensor) – the input tensor.

Keyword Arguments:
  • memory_config (ttnn.MemoryConfig, optional) – Memory configuration for the operation. Defaults to None.

  • dtype (data type, optional) – Data type of the output tensor. Defaults to None.

  • use_multicore (bool, optional) – Whether to use multicore. Defaults to True.

  • queue_id (int, optional) – command queue id. Defaults to 0.

Returns:

ttnn.Tensor – the output tensor.