TorchLean API

NN.Widgets.Runtime.Autograd

Autograd #

Autograd widgets (tapes + gradients).

This module provides infoview panels for TorchLean’s eager-mode autograd tape:

Main definitions #

Implementation notes #

References #

Tags #

autograd, reverse-mode, gradients, tape, widgets

def NN.Widgets.tapeHtml {α : Type} [ToString α] (t : Runtime.Autograd.Tape α) (maxDotChars : := 6000) :

Render a tape as an HTML panel (nodes + DOT).

Instances For

    Render gradients from a scalar output id (like loss.backward()).

    Instances For

      Reverse-Pass Trace #

      #tape_grads_view answers "which nodes received a gradient?".

      When you need to understand why a gradient was produced (or why it is missing), it is useful to see the reverse traversal itself:

      This viewer runs reverse-mode and renders a step-by-step trace in reverse id order.

      Render a reverse-pass trace for a tape, starting from a scalar output node outId.

      Instances For

        Commands #