postgkyl.group_blocks¶
- postgkyl.group_blocks(datasets)¶
Partition datasets into block families: one field’s blocks together.
A family is the set of datasets that agree on
(tag, sim, quantity, frame)and differ only inctx["block"]– i.e. the pieces of one field on a decomposed domain, which terminal verbs (plot,animate) should treat as a single thing to draw. Datasets with no block index are each returned as their own singleton family, so single-block input maps 1:1 onto the ungrouped list it was before.- Parameters:
datasets – Datasets, groups, or nested iterables of them (flattened via
flatten_datasets()).- Returns:
A list of lists, in first-appearance order; each family is sorted by ascending block index.