jax_sn.operators.transport_operator.implementations.transport_operator_warp module¶
Warp strategies and convenience constructors for the transport operator.
- class WarpSequentialSweep[source]¶
Bases:
SingleAngleInversionStrategySingle-angle inverse via the sequential Warp sweep kernel (no batching).
- invert(data: TransportData, b)[source]¶
- class WarpLevelSweep(maximum_number_of_levels: Optional[int] = None)[source]¶
Bases:
SingleAngleInversionStrategySingle-angle inverse via the level-based-parallelism Warp sweep kernel. Requires sweep data providing the
ProvidesLevelscapability (the level setup for both sweep directions). The basecheck_compatible()enforces that capability; this strategy only adds the warp-data-layout check. The minimal concrete builder isLeveledSweepData.- maximum_number_of_levels: Optional[int] = None¶
Width the level arrays are padded to when this strategy builds its sweep data.
Nonereads it off the levels themselves, which is a tracer whenever the domain the sweep is derived from is one – so pin it (to a width at least as large as the domain needs; too small is a clean equinox runtime error) whenever the sweep data is rebuilt under a trace, e.g. by a builder differentiating through a mesh deformation.
- invert(data: TransportData, b)[source]¶
- classmethod required_capabilities()[source]¶
Sweep-data capability interfaces this strategy requires (e.g.
(ProvidesLevels,)). Empty (the default) means anySweepDatais acceptable.
- build_default_sweep_data(geometric_domain, angle)[source]¶
The minimal sweep data this strategy needs, built for
geometric_domainandangle(single or batched – dispatched onangle.ndim).This builds rather than naming a type because a strategy may carry build-time knobs of its own (a level-padding width, say): those are properties of how this kernel sweeps, so they live as static fields on the strategy and are applied right here. Nothing upstream has to know they exist.
- class WarpSequentialAngles[source]¶
Bases:
MultiAngleInversionStrategyNative multi-angle inverse: fused sequential Warp sweep.
- single_angle_strategy()[source]¶
The single-angle
SingleAngleInversionStrategythis angle inversion corresponds to (used for composited strategy, error if does not exist)
- invert(data: TransportData, b)[source]¶
Invert over the angle axis:
datais a batchedTransportData(angle axis leading).
- class WarpLevelAngles(maximum_number_of_levels: Optional[int] = None)[source]¶
Bases:
MultiAngleInversionStrategyNative multi-angle inverse: fused level-based-parallelism Warp sweep. Requires sweep data providing the
ProvidesLevelscapability.- maximum_number_of_levels: Optional[int] = None¶
Level-array padding width; see
WarpLevelSweep.maximum_number_of_levels.
- single_angle_strategy()[source]¶
The single-angle
SingleAngleInversionStrategythis angle inversion corresponds to (used for composited strategy, error if does not exist)
- invert(data: TransportData, b)[source]¶
Invert over the angle axis:
datais a batchedTransportData(angle axis leading).
- required_capabilities()[source]¶
Sweep-data capability interfaces this strategy requires (e.g.
(ProvidesLevels,)). Empty (the default) means anySweepDatais acceptable.
- build_default_sweep_data(geometric_domain, angle)[source]¶
The minimal sweep data this strategy needs, built for
geometric_domainandangle(single or batched – dispatched onangle.ndim).This builds rather than naming a type because a strategy may carry build-time knobs of its own (a level-padding width, say): those are properties of how this kernel sweeps, so they live as static fields on the strategy and are applied right here. Nothing upstream has to know they exist.