tv_precompute_apply_frame_sweep_jets#
- t3toolbox.backend.sampling_derivatives.tv_precompute_apply_frame_sweep_jets(frame, ww, pp, order)#
def tv_precompute_apply_frame_sweep_jets( frame: typ.Tuple[ typ.Sequence[NDArray], typ.Sequence[NDArray], typ.Sequence[NDArray], typ.Sequence[NDArray], ], # = T3Frame.data = (U, O, P, Q) ww: typ.Sequence[NDArray], # probe vectors X, len=d, elm_shape=W+(Ni,) pp: typ.Sequence[NDArray], # perturbation vectors P, len=d, elm_shape=W+(Ni,) order: int, # highest derivative order ) -> typ.Tuple[ typ.Sequence[NDArray], # xi_jets. len=d, elm_shape=(2,)+W+C+(nUi,) typ.Sequence[NDArray], # mu_jets. len=d, elm_shape=(order+1,)+W+C+(rLi,) ]: # lean frame sweep -- (xi, mu) only
The apply-derivative frame sweep (lean): the up-index jet
build_input_jets(U_i x_i, U_i p_i)+ the leftmujets. The all-modes apply forward and its adjoint-state transpose use ONLY(xi, mu)(nonu/eta), so this skips the right + central sweeps – a per-step saving in a stochastic solve. Reused across the forward / transpose of an inner solve (theSamplingKind.precomputehook).- Parameters:
frame (t3toolbox.backend.common.typ.Tuple[t3toolbox.backend.common.typ.Sequence[NDArray], t3toolbox.backend.common.typ.Sequence[NDArray], t3toolbox.backend.common.typ.Sequence[NDArray], t3toolbox.backend.common.typ.Sequence[NDArray]])
ww (t3toolbox.backend.common.typ.Sequence[NDArray])
pp (t3toolbox.backend.common.typ.Sequence[NDArray])
order (int)
- Return type:
t3toolbox.backend.common.typ.Tuple[t3toolbox.backend.common.typ.Sequence[NDArray], t3toolbox.backend.common.typ.Sequence[NDArray]]