nirspipe.pipeline.hyper._helpers

nirspipe.pipeline.hyper._helpers#

What the coherence modules share: the channel axis, the sampling rate, row z-scoring.

Module Contents#

Functions#

long_axis_over

The axis a dyad’s channel-by-channel matrix is indexed by: the union of the members’ montages, in the first member’s order.

API#

nirspipe.pipeline.hyper._helpers.long_axis_over(raws: Iterable[mne.io.Raw], ch_type: str = 'hbo', sep_bands=None) → list[str]#

The axis a dyad’s channel-by-channel matrix is indexed by: the union of the members’ montages, in the first member’s order.

member A: S1_D1, S2_D2        member B: S2_D2, S3_D3
-> ["S1_D1", "S2_D2", "S3_D3"]

A label only the other member carries still has a row or a column of its own.

Bads are kept, unlike in _long_by_label(), so two dyads that lost different channels still produce matrices of one shape, and an empty cell stays distinct from a channel that was never in the montage. A 20-channel montage with 2 rejected gives 20 labels, of which 2 index an all-blank row or column.

One recording is a group of one, so long_axis_over([raw], ch_type) is the same rule over a single montage.