Skip to main content

Mojo function

log

log[dtype: DType, width: Int, //](x: SIMD[dtype, width]) -> SIMD[dtype, width]

Performs elementwise natural log (base E) of a SIMD vector.

Parameters:

  • dtype (DType): The dtype of the input and output SIMD vector.
  • width (Int): The width of the input and output SIMD vector.

Args:

  • x (SIMD[dtype, width]): Vector to perform logarithm operation on.

Returns:

Vector containing result of performing natural log base E on x.

Was this page helpful?