jax_sn.operators.scatter_operator.gather_scatter_operator_strategies module¶
Concrete gather-scatter strategies, mirroring the transport pattern (per-angle kernel + concrete vmap lift):
BroadcastedSingleGroupGather– the per-group kernel (aSingleGroupGatherScatterStrategy), one operation for both directions;sum_over_outgoingonly selects which group axis of \(\sigma_{g_{out}g_{in}}\) is contracted.VmapGatherScatterStrategy– a concreteComposedGatherScatterStrategythat lifts the single-group block over the group axis byvmap(the group-axis analogue ofVmapAnglesForward).
- class BroadcastedSingleGroupGather[source]¶
Bases:
SingleGroupGatherScatterStrategyBroadcasted (vmap-over-elements) single-group gather kernel.
- gather_group(data: GatherScatterData, x: Array, g: int, sum_over_outgoing: bool)[source]¶
- Return type:
Array
- class VmapGatherScatterStrategy(single_group_strategy: SingleGroupGatherScatterStrategy)[source]¶
Bases:
ComposedGatherScatterStrategyFull \(\mathbf{U}\) / \(\mathbf{U}^T\) by vmapping the single-group block over the group axis.
- forward(data: GatherScatterData, x: Array)[source]¶
- Return type:
Array
- transpose(data: GatherScatterData, x: Array)[source]¶
- Return type:
Array