Implicit Stochastic Gradient Descent for Training Physics-Informed Neural Networks

Ye Li, Songcan Chen, Sheng-Jun Huang

Abstract

Physics-Informed Neural Networks (PINNs) have emerged as a transformative approach for solving partial differential equations (PDEs) by embedding physical laws directly into the loss function. Despite their potential, PINNs often suffer from numerical stiffness, leading to training instability or failure when using standard explicit optimizers like Adam. This paper explores the application of Implicit Stochastic Gradient Descent (ISGD) to address these challenges. By utilizing an implicit update rule based on the Backward Euler method, ISGD provides superior stability and robustness, enabling the training of PINNs on complex, multi-scale problems where traditional methods fail.

Introduction

The integration of deep learning with scientific computing has led to the development of Physics-Informed Neural Networks (PINNs). By incorporating governing equations—such as conservation laws or boundary conditions—into the neural network's loss function, PINNs can solve complex PDEs without requiring traditional mesh-based discretization. However, the optimization landscape of PINNs is notoriously difficult to navigate.

The primary obstacle is "numerical stiffness." In the context of optimization, stiffness refers to a massive disparity in the curvature of the loss function. Mathematically, this is characterized by a high condition number in the Hessian matrix (the ratio between the largest and smallest eigenvalues). When a PINN attempts to resolve multi-scale features—such as high-frequency oscillations or sharp boundary layers—standard explicit optimizers like SGD or Adam require prohibitively small learning rates to prevent divergence. This results in slow convergence or a total failure to find the global minimum.

Methodology: From Explicit to Implicit Updates

To overcome the limitations of explicit methods, this research proposes an Implicit Gradient Descent (IGD) framework. The core innovation lies in the transition from the standard explicit update rule to the Backward Euler method.

The Implicit Update Rule

In standard Gradient Descent (GD), the next parameter state $\theta_{n+1}$ is calculated using the gradient at the current position: $$\theta_{n+1} = \theta_n - \alpha \nabla L(\theta_n)$$

In contrast, IGD calculates the next step based on the gradient at the future position: $$\theta_{n+1} = \theta_n - \alpha \nabla L(\theta_{n+1})$$

The Proximal Point Algorithm

Because $\theta_{n+1}$ appears on both sides of the equation, it cannot be solved analytically for non-linear loss functions. The authors reformulate this as a sub-optimization problem, known as a proximal point iteration: $$\theta_{n+1} = \arg \min_{\theta} \left\{ \frac{1}{2} \|\theta - \theta_n\|^2 + \alpha L(\theta) \right\}$$

To make this computationally feasible, the researchers employ a hybrid approach (e.g., "ISGD,Adam" or "ISGD,L-BFGS"). A standard optimizer is used to solve the "inner" sub-optimization problem for a limited number of iterations, which then informs the "outer" implicit step. This structure allows the algorithm to benefit from the stability of implicit methods while leveraging the speed of existing optimizers.

Theoretical Insights

The research provides a rigorous theoretical foundation for the effectiveness of ISGD:

  1. Stability by Design: The authors prove that for IGD, the loss is guaranteed to decay regardless of the stiffness of the gradient flow. While explicit GD can explode if the learning rate $\alpha$ is too large, the implicit update naturally damps the stiff components of the system.
  2. Global Convergence: For two-layer networks with quadratic loss, the authors demonstrate that randomly initialized ISGD converges to a globally optimal solution at a linear rate.
  3. Hyperparameter Robustness: ISGD significantly reduces the sensitivity of the model to the learning rate. Experiments show that ISGD can converge stably even with learning rates 100 times larger than those required by Adam.

Experimental Results

The method was evaluated across several challenging benchmarks, demonstrating its superiority over traditional optimizers.

Multi-scale Poisson Problems

In a 1D Poisson test featuring high-frequency oscillations, the Hessian's maximum eigenvalue reached $4.6 \times 10^8$. In this highly stiff environment, both Adam and L-BFGS failed to converge. ISGD, however, successfully trained the model using a large learning rate ($\alpha = 0.1$), effectively capturing the multi-scale features of the solution.

Singularly Perturbed ODEs

For ordinary differential equations (ODEs) containing sharp boundary layers—where the solution changes abruptly over a very small interval—ISGD maintained stability at $\alpha = 0.5$. In comparison, SGD and Adam required a learning rate of $\alpha = 0.001$ or smaller to avoid divergence, making the training process significantly more fragile.

Generalization to MNIST

To demonstrate that these benefits extend beyond physics problems, the authors tested ISGD on the MNIST classification dataset. ISGD achieved over 97% accuracy across a wide range of learning rates (0.1 to 10.0) and various batch sizes. Adam’s performance, by contrast, plummeted as soon as the learning rate exceeded 0.1.

Discussion and Conclusion

While ISGD offers significant advantages in stability and robustness, it introduces a higher computational cost per "outer" step due to the need to solve the inner proximal sub-problem. However, the authors argue that the total wall-clock time remains competitive because ISGD requires far fewer total iterations to reach convergence compared to explicit methods.

In conclusion, Implicit Stochastic Gradient Descent provides a powerful solution to the numerical stiffness that frequently plagues PINN training. By shifting the optimization paradigm from explicit to implicit updates, researchers can train more accurate models for complex physical systems with significantly less hyperparameter tuning. Future work will focus on scaling this approach to large-scale industrial PDE simulations and further optimizing the efficiency of the inner solver.

Summary updated

BibTeX
@inproceedings{li2023implicit,
  author = {Ye Li and Songcan Chen and Sheng-Jun Huang},
  title = {{Implicit Stochastic Gradient Descent for Training Physics-Informed Neural Networks}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2023},
  doi = {10.1609/aaai.v37i7.26046},
}
Figure