hawk.diff#
IR -> IR autodiff, symbolic and in both directions. vjp()
and jvp() synthesise
a NEW IR from a primal one, driven by the per-node-KIND rule table
(hawk.diff.rules); the result is an ordinary HAWK IR that goes through
the same canonical walk, emitter and cache as any primal.
param_planes() reads a kernel’s uniforms from one-cell
planes, so a recorded launch can change them without re-capture;
tape(), step_vjp(), step_jvp() and
refine_entry() build
the kernels a launching runtime needs to reverse a whole rollout of a step
kernel and to refine its stop time; hawk.diff.event reads a stop rule
as a smooth guard.
Functions
|
The reverse-mode derivative IR of |
|
The forward-mode derivative IR of |
ONE kernel that computes |
|
|
The taping twin of |
|
The vjp of ONE step of an in-place step kernel (one that updates |
|
The forward-mode twin of ONE step of an in-place step kernel, for a tangent carried across launches: a kernel that commits each state plane |
|
The REFINE entry |
|
|
Classes
The sink tuple |