CUDA tape hooks for Fourier transforms and diagonal scans #
CPU execution declines these hooks before recording anything, allowing the generic differentiable program to run on its ordinary operations. CUDA execution validates reference identities, selects the corresponding backend capsule, and records a TorchLean tape node. Fourier adjoints are composed in Lean; scans call native backward primitives. This keeps provider selection and cross-session checks on the same path as the other eager operations.
Record a LibTorch tape operation only for a CUDA session, preserving reference identity.
Instances For
Native real-transform hook; CPU interpreters use the generic matrix reference.
Instances For
Native shared-coefficient scan hook with gradients for coefficients, input, and state.
Instances For
Native token-dependent scan hook, including coefficient and continuation-state gradients.