MPSGraphWhileBeforeBlock
The block that executes before the condition evaluates for each iteration.
Declaration
typealias MPSGraphWhileBeforeBlock = ([MPSGraphTensor], NSMutableArray) -> MPSGraphTensorParameters
- inputTensors:
Input tensors to the
whileConditionBlock, for the first iteration will be same as initialInputs passed to the while loop. - resultTensors:
A valid
MPSGraphTensorarray with results forwarded to after block or returned from the while loop depending on the predicate tensor. It will be empty and the caller block should fill it up before returning.
Return Value
Tensor MUST be set and have a single scalar value, used to decide between executing the body block or returning from the while loop.