xnn.gnn.fast.radial_kernels#

Triton kernels of the fused hidden layers of a radial network (see RadialNet).

Three hidden layers s_i = silu(s_{i-1} A_i) of a per-edge radial network run in one kernel per tile of edges, the intermediate activations in registers; the backward kernel recomputes them and returns the input gradient (forces and stress). When the pass also wants the weights’ gradients, or the backward is itself differentiated (create_graph), the backward is the same formula in PyTorch operations. Products are float32 without TF32. Imported only when the fast path runs.

Module Attributes

BLOCK

Edges per tile.

WARPS

Warps per program.

Functions

fused_hidden(x, a1, a2, a3)

Three hidden SiLU layers with the (scaled) matrices a1, a2, a3; see the module notes.

Classes

FusedHidden(*args, **kwargs)

silu(silu(silu(x A1) A2) A3) for x of shape (E, K) in float32.