The workspace at /app contains sdpa_parity.py, grounded in
intermediate_source/scaled_dot_product_attention_tutorial.py. It defines a
run(B, H, L, D, is_causal, seed) driver that:
Generates seeded Q, K, V of shape (B, H, L, D).
Computes F.scaled_dot_product_attention(Q, K, V, is_causal=...) under
with sdpa_kernel([SDPBackend.MATH]):.
Computes the same value manually as
softmax(QK^T / sqrt(D)) V (with an upper-triangular mask of -inf when
is_causal=True).