xnn.krnn.common.sgdml_iterative.PairFactors#
- class xnn.krnn.common.sgdml_iterative.PairFactors(model, x, u, energy_constraint=False)[source]#
Bases:
objectK vfrom the kernel factors of every training pair, formed once.The geometry does not change during the solve, so
g,t(andkwith energy rows) of every pair of a training geometry and a permuted training term are kept (from exact distances); a product then needs three matrix products over the(M, M Q)pairs: the dot productsD . wasx_i . w - x_j . wand the gradient terms likewise. Those differences cancel to about 1e-12 relative, far below the solver’s tolerance.- Parameters: