Reconstructing Kernel-based Machine Learning Force Fields with Super-linear Convergence

Stefan Blücher, Klaus-Robert Müller, Stefan ChmielaarXiv 2022 · DOI

Abstract

Kernel machines have sustained continuous progress in the field of quantum chemistry. In particular, they have proven to be successful in the low-data regime of force field reconstruction. This is because many equivariances and invariances due to physical symmetries can be incorporated into the kernel function to compensate for much larger datasets. So far, the scalability of kernel machines has however been hindered by its quadratic memory and cubical runtime complexity in the number of training points. While it is known, that iterative Krylov subspace solvers can overcome these burdens, their convergence crucially relies on effective preconditioners, which are elusive in practice. Effective preconditioners need to partially pre-solve the learning problem in a computationally cheap and numerically robust manner. Here, we consider the broad class of Nyström-type methods to construct preconditioners based on successively more sophisticated low-rank approximations of the original kernel matrix, each of which provides a different set of computational trade-offs. All considered methods aim to identify a representative subset of inducing (kernel) columns to approximate the dominant kernel spectrum.

Introduction

Machine Learning Force Fields (MLFFs) serve as a critical bridge in molecular dynamics simulations, combining the computational efficiency of classical potentials with the high accuracy of ab initio quantum chemistry. Kernel-based methods, such as symmetric Gradient Domain Machine Learning (sGDML), are particularly effective in the low-data regime because they explicitly incorporate physical symmetries like rotational and translational invariance.

However, these methods face a significant "scalability wall." Traditional training requires solving a linear system $K\alpha = y$, which entails $O(n^3)$ time and $O(n^2)$ memory complexity for $n$ training points. While iterative solvers like Conjugate Gradient (CG) can reduce these costs, they are highly sensitive to the condition number of the kernel matrix. In molecular systems, stable bonding patterns lead to highly correlated data and ill-conditioned matrices, creating a loss landscape with narrow valleys that impede convergence.

Methodology: Preconditioned Conjugate Gradient

To overcome these limitations, this work utilizes Preconditioned Conjugate Gradient (PCG). The core idea is to "pre-solve" the most challenging components of the linear system using a computationally inexpensive approximation—a preconditioner $P$. This preconditioner flattens the matrix spectrum, transforming the optimization landscape into one that is easier for the solver to navigate.

Spectral decomposition of the kernel matrix $K$. The preconditioner $P$ targets the dominant, structured eigenvalues, leaving the conjugate gradient solver to handle the fluctuating noise.

As shown in Figure 1, the kernel matrix $K$ can be decomposed into structured and fluctuating components. The preconditioner effectively removes the dominant eigenvalues associated with prototypical molecular shapes (structured eigenvectors). This leaves the CG solver to handle the remaining statistical fluctuations, which converge significantly faster.

We evaluate three Nyström-type column selection strategies for constructing $P$:

  1. Uniform Sampling: Randomly selecting columns as a baseline.
  2. Leverage Score Sampling: Selecting columns that are most informative or unique.
  3. Incomplete Cholesky (IC) Decomposition: A deterministic, greedy approach that selects columns to minimize approximation error while ensuring linear independence.

Results and Discussion

The efficacy of these methods was tested on several benchmarks, including MD17/MD22 (aspirin, ethanol), Azobenzene, and complex systems like the "Catcher" and large-scale Nanotubes ($d=370$ atoms).

Convergence and Speedup

The PCG approach achieved speedups ranging from 1.4x to 5.0x compared to traditional analytic solvers on NVIDIA A100 GPUs. Crucially, the predictive accuracy (Mean Absolute Error) remained identical to exact closed-form solutions. The study also demonstrated super-linear convergence, where the solver converges faster than the theoretical linear limit when an appropriate number of inducing columns $k$ is used.

Iteration counts across different molecular systems as a function of relative preconditioner strength. Incomplete Cholesky (green) consistently outperforms uniform sampling and approaches optimal SVD performance.

As illustrated in Figure 5, Incomplete Cholesky (IC) emerges as the most robust strategy, particularly for complex or highly symmetric systems like nanotubes. While random sampling may suffice for simpler molecules, it often selects redundant, correlated columns in larger systems. IC’s pivoting rule systematically identifies independent columns, making it essential for large-scale chemical applications.

Memory Efficiency and Rule of Thumb

The preconditioned approach significantly reduces memory overhead. For instance, a system requiring 30GB for the full kernel matrix could be solved using only ~3GB. To aid practical application, we propose a "Rule of Thumb" (RoT) formula to predict the optimal $k$ that balances the cost of building the preconditioner against the speedup provided to the solver.

Conclusion

By leveraging Incomplete Cholesky-based Nyström preconditioners, we enable kernel-based MLFFs to scale to much larger systems without sacrificing accuracy. The transition from $O(n^3)$ to iterative methods with super-linear convergence addresses the primary bottleneck of kernel machines in quantum chemistry. Future work will focus on integrating these solvers into automatic differentiation frameworks to facilitate the training of models with complex differential constraints, potentially enabling the simulation of massive biomolecules and material surfaces.

Summary updated

BibTeX
@misc{blucher2022reconstructing,
  author = {Stefan Blücher and Klaus-Robert Müller and Stefan Chmiela},
  title = {{Reconstructing Kernel-based Machine Learning Force Fields with Super-linear Convergence}},
  year = {2022},
  eprint = {2212.12737},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2212.12737},
}
Figure