#include <gpr/ml/gp/PairLocalKernel.h>
Public Member Functions | |
| TileEvaluator (const Geometry &geometry, const Weights &weights) | |
| TileEvaluator (const Geometry &left, const Geometry &right, const Weights &weights) | |
| TileEvaluator (const Geometry &geometry, const Weights &weights, const std::vector< Eigen::Index > &derivative_groups) | |
| TileEvaluator (const Geometry &left, const Geometry &right, const Weights &weights, const std::vector< Eigen::Index > &derivative_groups) | |
| Eigen::Index | tileSize () const noexcept |
| Eigen::Index | parameterCount () const noexcept |
| 1 + number of log lengths. | |
| void | prepare (Eigen::Index i, Eigen::Index j) |
| void | tile (Eigen::Index parameter, Eigen::MatrixXd &out) const |
| void | directional (const Eigen::VectorXd &direction, Eigen::MatrixXd &first, Eigen::MatrixXd &second) const |
| void | contract (const double *W, Eigen::Index row_stride, Eigen::Index col_stride, bool lower_only, Eigen::VectorXd &out) const |
| void | quadratic (const double *alpha_i, const double *alpha_j, Eigen::VectorXd &out) const |
| void | action (const double *vector, bool transpose, Eigen::MatrixXd &out) const |
| void | diagonals (Eigen::MatrixXd &out) const |
One configuration pair of the joint covariance and its derivatives with respect to log m (parameter 0) and each log length (parameters 1..P, or the single parameter 1 for a shared length).
Definition at line 82 of file PairLocalKernel.h.
Definition at line 165 of file PairLocalKernel.cpp.
| gpr::pairlocal::TileEvaluator::TileEvaluator | ( | const Geometry & | left, |
| const Geometry & | right, | ||
| const Weights & | weights ) |
Cross tiles between the configurations of two geometries of the same atoms: i indexes left, j indexes right.
Definition at line 170 of file PairLocalKernel.cpp.
| gpr::pairlocal::TileEvaluator::TileEvaluator | ( | const Geometry & | geometry, |
| const Weights & | weights, | ||
| const std::vector< Eigen::Index > & | derivative_groups ) |
Compact derivative groups, indexed by fine pair type. Each group parameter moves all of its members' log lengths together. Group IDs must cover 0..G-1; an empty map retains the fine-coordinate workspace.
Definition at line 176 of file PairLocalKernel.cpp.
| gpr::pairlocal::TileEvaluator::TileEvaluator | ( | const Geometry & | left, |
| const Geometry & | right, | ||
| const Weights & | weights, | ||
| const std::vector< Eigen::Index > & | derivative_groups ) |
Definition at line 182 of file PairLocalKernel.cpp.
| void gpr::pairlocal::TileEvaluator::action | ( | const double * | vector, |
| bool | transpose, | ||
| Eigen::MatrixXd & | out ) const |
Apply every derivative tile to one channel vector without materializing the tiles. out(p, c) is the c-th component of (dK/dtheta_p) vector; transpose=true applies each transposed tile. Workspace is O(G D).
Definition at line 488 of file PairLocalKernel.cpp.
| void gpr::pairlocal::TileEvaluator::contract | ( | const double * | W, |
| Eigen::Index | row_stride, | ||
| Eigen::Index | col_stride, | ||
| bool | lower_only, | ||
| Eigen::VectorXd & | out ) const |
Frobenius products of a weight tile with the covariance tile and every derivative tile: out(p) = <W, dK/dtheta_p>, out(0) = <W, K>. Entry (c, c') of W sits at W[c * row_stride + c' * col_stride]. When lower_only the tile is the diagonal tile i == j and only the entries with c >= c' are read.
Definition at line 373 of file PairLocalKernel.cpp.
| void gpr::pairlocal::TileEvaluator::diagonals | ( | Eigen::MatrixXd & | out | ) | const |
Diagonal of every parameter tile: out(p, c). Meaningful for i == j, where the kernel nugget scales the diagonal.
Definition at line 545 of file PairLocalKernel.cpp.
| void gpr::pairlocal::TileEvaluator::directional | ( | const Eigen::VectorXd & | direction, |
| Eigen::MatrixXd & | first, | ||
| Eigen::MatrixXd & | second ) const |
Exact first and second derivatives along one packed log-parameter direction. Pair products use their six-entry Cartesian support.
Definition at line 309 of file PairLocalKernel.cpp.
|
inlinenodiscardnoexcept |
1 + number of log lengths.
Definition at line 103 of file PairLocalKernel.h.
| void gpr::pairlocal::TileEvaluator::prepare | ( | Eigen::Index | i, |
| Eigen::Index | j ) |
Definition at line 218 of file PairLocalKernel.cpp.
| void gpr::pairlocal::TileEvaluator::quadratic | ( | const double * | alpha_i, |
| const double * | alpha_j, | ||
| Eigen::VectorXd & | out ) const |
alpha_i^T (dK/dtheta_p) alpha_j for every parameter, with the tiles of the two weight vectors given channel-contiguous.
Definition at line 448 of file PairLocalKernel.cpp.
| void gpr::pairlocal::TileEvaluator::tile | ( | Eigen::Index | parameter, |
| Eigen::MatrixXd & | out ) const |
The dense tile of parameter parameter (0 is the covariance itself, which equals its derivative with respect to log m).
Definition at line 251 of file PairLocalKernel.cpp.
|
inlinenodiscardnoexcept |
Definition at line 98 of file PairLocalKernel.h.