Contents

allocate(repeating:shape:batchSize:)

Returns a new n-dimensional array descriptor that’s initialized with a single, repeated scalar value.

Declaration

static func allocate<T>(repeating repeatedValue: T, shape: BNNS.Shape, batchSize: Int = 1) -> BNNSNDArrayDescriptor where T : BNNSScalar

Parameters

  • repeatedValue:

    The element to repeat.

  • shape:

    The shape of n-dimensional array descriptor.

  • batchSize:

    The number of batches of data.

See Also

Allocating and Deallocating Memory