Leveraging Influence Functions for Resampling Data in Physics-Informed Neural Networks

Jonas R. Naujoks, Aleksander Krasowski, Moritz Weckbecker, Galip Ümit Yolcu, Thomas Wiegand, Sebastian Lapuschkin, Wojciech Samek, René P. Klausen

Introduction

Physics-Informed Neural Networks (PINNs) have emerged as a powerful framework for solving Partial Differential Equations (PDEs) by integrating physical laws directly into the neural network's loss function. Despite their popularity, PINNs often face significant optimization hurdles, such as gradient pathologies and convergence to poor local minima. The selection of training data—specifically the spatio-temporal coordinates known as collocation points—is a critical factor in overcoming these challenges. While uniform random sampling is standard, adaptive resampling strategies have shown promise in improving model accuracy.

This paper introduces PINNfluence, a novel resampling strategy based on Training Data Attribution (TDA). By leveraging influence functions from the field of Explainable AI (XAI), the authors demonstrate that XAI techniques can be used proactively to guide model training rather than just providing post-hoc explanations.

Methodology: Adaptive Resampling with PINNfluence

The core idea behind PINNfluence is to identify and prioritize the most informative collocation points during the training process. Unlike traditional Residual-based Adaptive Refinement (RAR), which focuses on regions where the PDE residual is high, PINNfluence uses a counterfactual approach. It asks: How would the model's performance change if a specific candidate point were added to the training set?

The PINNfluence workflow involves three key steps:

  1. Influence Scoring: The method calculates an influence score for a pool of candidate points. Crucially, the authors use the absolute value of the score, prioritizing points that cause significant parameter shifts, which helps the model escape local minima.
  2. Distribution-Based Sampling: To ensure diversity and avoid redundant sampling in high-influence regions, scores are converted into a probability mass function for sampling.
  3. Training Integration: Periodically, the training set is updated by either adding these high-impact points or replacing the existing set entirely.

The authors also compare this approach against "Grad-Dot," a first-order heuristic that avoids the computationally expensive Hessian calculations required by true influence functions.

Experimental Evaluation and Results

The performance of PINNfluence was evaluated on four benchmark PDEs: Diffusion, Burgers', Allen-Cahn, and Wave equations. The results indicate that PINNfluence consistently outperforms random sampling and matches or exceeds the performance of state-of-the-art RAR methods.

Relative error ratios of PINNfluence and RAR compared to random sampling across four PDE benchmarks. Lower values indicate better performance relative to the random baseline.

Key findings include:

  • Superior Accuracy: In the Burgers' equation task, PINNfluence achieved a mean $L^2$ relative error of 3.7%, significantly lower than random sampling (8.0%) and Grad-Dot (5.3%).
  • Robustness in Complex Landscapes: For the Wave equation, PINNfluence reduced error to 8.1%, a massive improvement over the 44.3% error seen with random sampling.
  • The Necessity of Second-Order Information: The poor performance of the Grad-Dot baseline confirms that the complex loss landscapes of PINNs require the second-order information provided by the Hessian to accurately identify critical data points.

Discussion and Limitations

While PINNfluence demonstrates the power of XAI in the training loop, it comes with a significant computational trade-off. Calculating influence functions requires approximating the Hessian and performing multiple backward passes, making it much more expensive than the forward-pass-only RAR method.

Future research is needed to develop more efficient approximations of influence functions to scale this approach to higher-dimensional problems. Additionally, exploring the synergy between influence functions and other theoretical frameworks, such as Neural Tangent Kernels (NTK), remains a promising avenue for improving PINN optimization.

Conclusion

PINNfluence represents a shift in how XAI is utilized in scientific machine learning. By transforming an explanatory tool into an active training strategy, the authors provide a robust method for adaptive data selection that rivals current state-of-the-art techniques, paving the way for more reliable and accurate physics-informed models.

Summary updated

BibTeX
@inproceedings{naujoks2025leveraging,
  author = {Jonas R. Naujoks and Aleksander Krasowski and Moritz Weckbecker and Galip Ümit Yolcu and Thomas Wiegand and Sebastian Lapuschkin and Wojciech Samek and René P. Klausen},
  title = {{Leveraging Influence Functions for Resampling Data in Physics-Informed Neural Networks}},
  booktitle = {xAI},
  year = {2025},
  doi = {10.1007/978-3-032-08324-1\_17},
}
Figure