Changes made in dsp/fourier/internal/fftpack break the formatting used
there, so these are reverted. There will be complaints in CI.
[git-generate]
gofmt -w .
go generate gonum.org/v1/gonum/blas
go generate gonum.org/v1/gonum/blas/gonum
go generate gonum.org/v1/gonum/unit
go generate gonum.org/v1/gonum/unit/constant
go generate gonum.org/v1/gonum/graph/formats/dot
go generate gonum.org/v1/gonum/graph/formats/rdf
go generate gonum.org/v1/gonum/stat/card
git checkout -- dsp/fourier/internal/fftpack
Ruleguard run with ruleguard -c=0 -rules ruleguard.rules.go ./... from
https://github.com/dgryski/semgrep-go with the following rules inactivated
to reduce noise:
- unconvert for floating point values
- oddcomparisons
- floateq
The code was jumping to end when tail == 0, but the correct thing is to jump
when LEN is zero. TAIL == 0 means we can start the summing pipeline. We also
don't need to decrement the TAIL since we overwrite it at start of no_trim.
L2 Distance kernel is a slight modification of the L2 Norm kernel,
taking two vectors and calculating the difference before summing squares.
Same overflow protections as the netlib form of the norm calculation.
Netlib algorithm reduces overflow while calculating the l2norm of a
vector.
Translated incremented vector calculation to asm while reducing
branches in NaN and Inf checks. Overflow protection is equivalent to
the Netlib standard implementation.
Netlib algorithm reduces overflow while calculating the l2norm of a
vector.
Translated to asm while reducing branches in NaN and Inf checks.
Overflow protection is equivalent to the Netlib standard implementation.