struct gpr::TrainingKernelGeometry¶
Overview¶
#include <gpr/ml/GaussianProcessRegression.h>
struct TrainingKernelGeometry {
// fields
std::vector<TrainingKernelGeometryBlock> blocks;
bool shared_coordinates = true;
std::vector<FieldMatrixd> shared_distance_neg_per_pt;
Eigen::VectorXd uDdim;
Index_t num_repetitive_indices = 0;
Eigen::Index n = 0;
bool valid = false;
std::map<std::pair<Index_t, Index_t>, std::size_t> block_index_by_nm;
Index_t n_pairtypes = 0;
TrainingKernelGeometrySubset rows_cols;
TrainingKernelGeometrySubset cols_rows;
bool has_per_rank_subset = false;
bool streamed = false;
std::vector<FieldMatrixd> x_loc_by_dim;
FactoredTrainingGeometry factors;
std::shared_ptr<LazyFactoredTrainingGeometry> lazy_factors;
pairlocal::Geometry pair_local;
// methods
void clear();
const TrainingKernelGeometryBlock* find(Index_t block_n, Index_t block_m) const;
};
Detailed Documentation¶
Fields¶
bool shared_coordinates = true
Channel blocks carry the same Cartesian positions.
bool streamed = false
Streamed geometry: the per-block derivative tensors (three per-pair-type n_conf x n_conf fields for each of the (1+D)(2+D)/2 blocks) are not cached; each consumer rebuilds a block’s tensors from the stored per-dimension coordinate blocks as it walks the blocks. Chosen for distinct channel positions or when the cache would not fit the available memory (16_h2po4_anion: 15 GB at 225 rows and 22 dof, the OOM killer at 300); costs one geometry build per assembly instead of one per prepare.
std::vector<FieldMatrixd> x_loc_by_dim
indexed by dimension value
FactoredTrainingGeometry factors
streamed blocks come from here
pairlocal::Geometry pair_local
Pair-local tiles: the joint covariance and its hyperparameter contractions per configuration pair, the assembly and gradient of choice whenever it is valid.