swizzle.m

From Spinach Documentation Wiki
Revision as of 12:31, 25 April 2026 by Kuprov (talk | contribs) (Normalise sequential blank lines)
Jump to: navigation, search

Flattens out nested index lists and outputs them as an array of tuples in random order, useful for parallel loop vectorisation.

Syntax

   tuples=swizzle(index_arrays)

Arguments

   index_arrays  - a cell array of row vectors

Outputs

   tuples        - matrix of tuples in random order, with tuples listed as rows

See also

Parallelisation and GPUs

Version 2.11, authors: Ilya Kuprov