api / koma.internal.default.generated.ndarray / DefaultFloatNDArray / <init>
<init>
DefaultFloatNDArray(vararg shape:
Int
, init: (
IntArray
) ->
Float
)
An (unoptimized) implementation of NDArray in pure Kotlin, for portability between the different platforms koma supports.
Parameters
shape
- A vararg specifying the size of each dimension, e.g. a 3D array with size 4x6x8 would pass in 4,6,8)
init
- A function that takes a location in the new array and returns its initial value.