ttnn.log

ttnn.log = FastOperation(python_fully_qualified_name='ttnn.log', function=<ttnn._ttnn.operations.unary.log_t object>, preprocess_golden_function_inputs=<function default_preprocess_golden_function_inputs>, golden_function=<function register_ttnn_cpp_unary_function.<locals>._golden_function>, postprocess_golden_function_outputs=<function default_postprocess_golden_function_outputs>, is_cpp_operation=True, is_experimental=False)

Applies log to input_tensor element-wise.

\[\mathrm{output\_tensor}_i = log(\mathrm{input\_tensor}_i)\]
Parameters:

input_tensor (ttnn.Tensor) – the input tensor.

Keyword Arguments:
  • fast_and_approximate_mode (bool, optional) – Use the fast and approximate mode. Defaults to False.

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

  • output_tensor (ttnn.Tensor, optional) – preallocated output tensor. Defaults to None.

  • sub_core_grids (ttnn.CoreRangeSet, optional) – sub core grids for the operation. Defaults to None.

Returns:

ttnn.Tensor – the output tensor.

Note

Supported dtypes and layouts:

Dtypes

Layouts

BFLOAT16, BFLOAT8_B, FLOAT32

TILE, ROW_MAJOR