swizzle.m

From Spinach Documentation Wiki
Revision as of 13:33, 17 May 2025 by Kuprov (talk | contribs) (Created page with "{{DISPLAYTITLE:swizzle.m}} __NOTOC__ Flattens out nested index lists and outputs them as an array of tuples in random order, useful for parallel loop vectorisation. ==Syntax=...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
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

Housekeeping functions


Version 2.11, authors: Ilya Kuprov