Contents

init(scalars:shape:)

Creates a shaped array type from an array of values.

Declaration

init<S>(scalars: S, shape: [Int]) where S : Sequence, Self.Scalar == S.Element

Parameters

  • scalars:

    A sequence of values.

  • shape:

    An integer array. Each element represents the size of the shaped array’s corresponding dimension.

See Also

Creating a shaped array type