warp.randn ========== .. currentmodule:: warp._src.lang .. function:: randn(state: uint32) -> float .. wp-function-tags:: :kernel: true :python: true :differentiable: false Sample the standard normal (Gaussian) distribution with mean 0 and variance 1. Uses the Box-Muller transform, consuming two uniform draws. In a kernel, this advances ``state`` in place; called from the Python scope, it does not modify ``state``, so repeated calls with the same ``state`` return the same value (see :func:`rand_init`). For a general normal, scale and shift the result: ``mean + stddev * wp.randn(state)``.