strides
An array of strides, in elements, one for each dimension of this tensor, if applicable.
Declaration
var strides: MTLTensorExtents? { get }Discussion
You are responsible for ensuring strides meets the following requirements:
The first element of
stridesmust be 1.If usage contains machineLearning, the second element of
stridesmust be aligned to 64 bytes, and for anyilarger than 1,strides[i]must equalstrides[i-1] * dimensions[i-1].If dataType is a format MTLTensorDataType, for any
igreater than or equal to 1,strides[i]must be aligned to 128 bytes. This is not a requirement for non-format data types, but following this convention improves performance.
This property is non-nil only for tensors created from a buffer.