Skip to contents

Element-wise log(1 + x), more accurate for small x.

Usage

nv_log1p(x)

Arguments

x

(arrayish)
Input array.

Value

arrayish
Has the same shape and data type as the input.

See also

prim_log1p() for the underlying primitive.

Examples

x <- nv_array(c(0, 0.001, 1))
nv_log1p(x)
#> AnvlArray
#>  0.0000
#>  0.0010
#>  0.6931
#> [ CPUf32{3} ]