TorchLean API

NN.Runtime.Autograd.Engine.LibTorch.Ops.Linear

CUDA Tape Operations: Matrix and Loss Nodes #

Linear algebra #

@[inline]

Backend matrix kernel for a single pair of matrices.

Instances For
    @[inline]

    Backend matrix kernel over a flattened leading shape.

    Instances For

      Linear layer / losses #

      @[inline]
      def Runtime.Autograd.LibTorch.Tape.linear {outDim inDim : ℕ} (t : Tape SomeBuffer) (wId bId xId : ℕ) :

      Linear layer: y = W·x + b with W : (outDim,inDim), x : inDim, b : outDim.

      Instances For
        @[inline]

        Mean-squared-error loss with "mean" reduction (single scalar output).

        Instances For