def recorded

bendtorch-core@0.1.0.0 · src/autograd/loss.bend:206

import bendtorch-core@0.1.0.0/src/autograd/loss.bend as Loss
import Base
import bendtorch-core@0.1.0.0/src/tensor/core.bend as Core

206# The loss next to the two tensors the backward reads.
207def recorded(left: Core.Dynamic, right: Core.Dynamic, result: Result<&2, &1, Core.Error, Core.Dynamic>) -> Result<&2, &1, Error, Recorded>:
208  match result:
209    case Fail{error}:
210      Fail{TensorError{error}}
211    case Done{loss}:
212      Done{Recorded{loss, left, right}}

Uses (5)

Used by (2)