How to set right strides in MLMultiArray in Core ML? What's the strides' values' meaning?

325 Views Asked by At

How to set right strides in MLMultiArray in Core ML? What's the EVERY strides' values' meaning?

For example, assume a Core ML model input shape is (1, 3, 1280, 720), so how to set strides when create MLMultiArray object by using initWithDataPointer:shape:dataType:strides:deallocator:error:?

I set strides as (720 * 1280, 720 * 1280, 720, 1) from some websites, but I don't know why set as this, or if it's right. What's the connection between shape and strides. No more documentation about it on Apple Developer website.

0

There are 0 best solutions below