NDArray::clip
public static function clip(NDArray|array|float|int $array, float $min, float $max): NDArray|float|int;
Clips the values of an array between a minimum and maximum value, returning a new array with the values clipped within the specified range.
Notes
tip
GPU SUPPORTED
This operation is supported by GPU (VRAM) and contains a custom CUDA kernel.