klyn.math.nn.layers.Dense.backwardTraining
method
public override backwardTraining(context as LayerPass<T>, upstream as NDArray<T>) as LayerGradients<T>
Description

Differentiates the saved affine result without repeating its matrix product.

Parameters
ParameterDescription
contextForward context from this layer.
upstreamOutput derivative, including the activation.
Returns

Input and ordered parameter derivatives.

Example

gradients = layer.backwardTraining(context, upstream)