contractions#
The grouped-einsum interpreter: contract('WCa,Caib,WCi->WCb', *operands, len_W=...).
An einsum whose UPPERCASE letters each stand for a GROUP of zero or more axes (W probe stack,
K tangent stack, C frame stack, …); lowercase letters are single axes as usual. This is
the machinery for independent batch blocks living on DIFFERENT operand subsets – what a single
leading '...' einsum cannot express. Group sizes are solved from the operand ndims; each group
expands into fresh single-axis letters; ONE ordinary einsum runs on the operands exactly as given.
Full design: docs/batching_and_stacking.md (esp. §4).
(Until 2026-07-17 this module instead enumerated ~104 named contraction functions –
WCa_Caib_WCi_to_WCb-style, each a hand-written flatten + fixed-subscript einsum. The
interpreter replaced them: the old name is the string argument, and the old n_probe/n_frame
parameters are len_W=/len_C=.)
Functions#
|
Grouped einsum: an einsum whose UPPERCASE letters each stand for a GROUP of zero or more axes. |