Rounded Convolution #
Forward- and reverse-mode error bounds for channels-first convolution at arbitrary spatial rank.
The bounds replay the exact ordered folds in Spec.convSpec and Spec.convBackwardSpec; no
associativity of rounded addition is assumed.
Ordered rounded sums #
Error budget after one rounded addition.
Instances For
Error budget after one rounded multiplication.
Instances For
Replay a rounded sum while carrying its absolute-error budget.
Instances For
Error budget for a rounded sum beginning at zero.
Instances For
A fold of individually bounded rounded terms is bounded by foldError.
Replay bound for a dot product whose two arguments are already approximated pointwise.
Instances For
An ordered rounded dot product is enclosed by productFoldError.
Arbitrary-rank index traversal #
The nested index loop equals a single fold over the flattened index list.
This is the workhorse of the file. The implementation loops over dimensions recursively, whereas an error bound is much easier to state as one sum over coordinates; turning one into the other once, here, keeps every later bound free of nested inductions.
Same flattening one level up, for the channel loop wrapped around the spatial loop.
Tensor coordinates #
Total tensor lookup preserves a uniform tensor approximation.
Forward convolution #
The input element a convolution reads for one output position and one (channel, offset) pair,
or zero when the strided, padded index falls outside the input.
Naming the read explicitly is what lets the approximation proof treat padding as an exact zero rather than as another rounded value.
Instances For
The weight a given input coordinate is multiplied by, as the implementation reads it.
Named so the error bound can talk about the summands of the accumulation in the same order the code produces them, which is what makes the bound tight rather than merely valid.
Instances For
Absolute-error budget for one coordinate of a rounded arbitrary-rank convolution.
The budget follows the implementation's multiplication and accumulation order, then accounts for the final bias addition.
Instances For
One coordinate of rounded convolution is enclosed by convolutionPointError.
Backward convolution #
The input value entering one term of the kernel-gradient accumulation, zero outside the padding.
Instances For
The output-gradient value entering that same term.
Instances For
Error budget for one coordinate of the rounded convolution kernel gradient.
Instances For
Every coordinate of the rounded kernel gradient encloses its ideal real value.
Error budget for one coordinate of the rounded convolution bias gradient.
Instances For
Every coordinate of the rounded bias gradient encloses its ideal real value.
One summand of the input-gradient accumulation: an output gradient times the kernel weight that connected them, or zero when the transposed index falls outside the input.
Instances For
Error budget for one coordinate of the rounded convolution input gradient.
Instances For
Every coordinate of the rounded input gradient encloses its ideal real value.