Idris2Doc : NN.Training.Training

NN.Training.Training

(source)

Definitions

optimiseStep : InterfaceOnPositionslNum=>p=%> (e>@l) ->Costate (IO<!>e) ->OptimiserpstateTy->Costate (IO<!>Const (p.Shp, stateTy))
  Performs a single step of optimisation of some differentiable function
`f : p -> l`, additionally handling some effect `e`
The optimiser used is allowed to be stateful meaning the result of the
optimisation is both the final parameter and the state of the optimiser

Totality: total
Visibility: public export
evalFw : (a->Exteb) ->Costate (IO<!>e) ->Costate (IO<!>Const2ab)
  Evaluates a the forward pass of some effectful lens

Totality: total
Visibility: public export
optimise : InterfaceOnPositionslNum=> {default100_ : Nat} -> {defaultNothing_ : Maybe (p.Shp)} ->Show (p.Shp) =>Show (l.Shp) =>ShowstateTy=>p=%> (e>@l) ->Costate (IO<!>e) ->OptimiserpstateTy->Nat->IO (p.Shp, stateTy)
  Iterates `optimiseStep` `numSteps` times, and logs the progress to the 
console

Totality: total
Visibility: public export
buildSupervisedLearningSystem : Num (l.Shp) =>IsFlatl=> (f : ParaAddDLensxy) ->Lossy->GetParamf=%> (pushDown (x><y) >@l)
  Given
a) a parametric lens `f : x >< p =%> y`
b) a loss function `loss : y >< y =%> l`
builds an effectful lens `p =%> l`

Totality: total
Visibility: public export
totalLoss : Show (l.Shp) =>Num (l.Shp) => (f : ParaAddDLensx (e>@y)) ->Lossy-> (GetParamf) .Shp->Costate (IO<!>e) ->Costate (IO<!>Const2 (Vectn (x.Shp, y.Shp)) (l.Shp))
  When it comes to effects which involve sampling, where the 'correct' answer
is stored in the test data, there are different ways of evaluating the loss
One is to use that correct label to force the correct branch to run, but
that is impossible with the current type signature
Instead, we opt out for the more accurate method of sampling during loss
evaluation

Totality: total
Visibility: public export
averageLoss : Show (l.Shp) =>Num (l.Shp) =>Fractional (l.Shp) =>CastNat (l.Shp) => (f : ParaAddDLensx (e>@y)) ->Lossy-> (GetParamf) .Shp->Costate (IO<!>e) ->Costate (IO<!>Const2 (Vectn (x.Shp, y.Shp)) (l.Shp))
Totality: total
Visibility: public export
evalWithLoss : Show (x.Shp) =>Show (y.Shp) =>Show (l.Shp) => (f : ParaAddDLensx (e>@y)) ->Lossy-> (GetParamf) .Shp->Costate (IO<!>e) ->Costate (IO<!>Const2 (Vectn (x.Shp, y.Shp)) ())
  Eval a model and loss with specific parameters, in the presence of an effect

Totality: total
Visibility: public export
eval : Show (x.Shp) =>Show (y.Shp) => (f : ParaAddDLensx (e>@y)) -> (GetParamf) .Shp->Costate (IO<!>e) ->Costate (IO<!>Const2 (Vectn (x.Shp)) ())
  Eval a model with specific parameters, in the presence of an effect

Totality: total
Visibility: public export
trivialEffect : ParaAddDLensxy->ParaAddDLensx (Scalar>@y)
Totality: total
Visibility: public export
handleTrivial : Costate (IO<!>Scalar)
Totality: total
Visibility: public export
eval : Show (x.Shp) =>Show (y.Shp) => (f : ParaAddDLensxy) -> (GetParamf) .Shp->Costate (IO<!>Const2 (Vectn (x.Shp)) ())
  Eval a model with specific parameters

Totality: total
Visibility: public export
averageLoss : Show (l.Shp) =>Num (l.Shp) =>Fractional (l.Shp) =>CastNat (l.Shp) => (f : ParaAddDLensxy) ->Lossy-> (GetParamf) .Shp->Costate (IO<!>Const2 (Vectn (x.Shp, y.Shp)) (l.Shp))
Totality: total
Visibility: public export