Squared Euclidean distance with one length scale, or one per coordinate. More...
#include <gpr/bo/StationaryKernel.h>
Public Member Functions | |
| ScaledEuclideanDistance (Eigen::VectorXd length_scales) | |
| ScaledEuclideanDistance (Eigen::VectorXd length_scales, std::vector< bool > categorical) | |
| Distance with unordered coordinates. | |
| template<typename Left, typename Right> | |
| double | squared (const Left &left, const Right &right) const |
| const std::vector< bool > & | categorical () const noexcept |
| Unordered-coordinate flags. Empty: every coordinate is ordered. | |
| const Eigen::VectorXd & | lengthScales () const noexcept |
| The stored length scales: one, or one per coordinate. | |
Squared Euclidean distance with one length scale, or one per coordinate.
Definition at line 32 of file StationaryKernel.h.
|
inlineexplicit |
Definition at line 34 of file StationaryKernel.h.
|
inline |
Distance with unordered coordinates.
A coordinate whose categorical entry is true holds a label. Two rows are then zero apart on that coordinate when the labels are equal and one length-scale unit apart otherwise, so the term is (a != b) / l^2. That is the squared Euclidean distance of a one-hot encoding up to a factor two in l^2, so a radial kernel of it stays positive definite. categorical has one entry per length scale.
Definition at line 58 of file StationaryKernel.h.
|
inlinenodiscardnoexcept |
Unordered-coordinate flags. Empty: every coordinate is ordered.
Definition at line 102 of file StationaryKernel.h.
|
inlinenodiscardnoexcept |
The stored length scales: one, or one per coordinate.
Definition at line 108 of file StationaryKernel.h.
|
inline |
One stored scale applies to every coordinate. Otherwise the count matches the vector.
Definition at line 74 of file StationaryKernel.h.