[Paper Review] Is it time to swish? Comparing activation functions in solving the Helmholtz equation using physics-informed neural networks
This paper investigates the impact of different activation functions on the performance of physics-informed neural networks (PINNs) for solving the Helmholtz equation in seismic wavefield modeling. It demonstrates that the swish activation function significantly improves convergence speed and solution accuracy compared to commonly used alternatives like tanh, atan, and elu, particularly in models with sharp velocity heterogeneities.
Solving the wave equation numerically constitutes the majority of the computational cost for applications like seismic imaging and full waveform inversion. An alternative approach is to solve the frequency domain Helmholtz equation, since it offers a reduction in dimensionality as it can be solved per frequency. However, computational challenges with the classical Helmholtz solvers such as the need to invert a large stiffness matrix can make these approaches computationally infeasible for large 3D models or for modeling high frequencies. Moreover, these methods do not have a mechanism to transfer information gained from solving one problem to the next. This becomes a bottleneck for applications like full waveform inversion where repeated modeling is necessary. Therefore, recently a new approach based on the emerging paradigm of physics informed neural networks (PINNs) has been proposed to solve the Helmholtz equation. The method has shown promise in addressing several challenging associated with the conventional algorithms, including flexibility to model additional physics and the use of transfer learning to speed up computations. However, the approach still needs further developments to be fully practicable. Foremost amongst the challenges is the slow convergence speed and reduced accuracy, especially in presence of sharp heterogeneities in the velocity model. Therefore, with an eye on exploring how improved convergence can be obtained for the PINN Helmholtz solvers, we study different activation functions routinely used in the PINN literature, in addition to the swish activation function - a variant of ReLU that has shown improved performance on a number of data science problems. Through a comparative study, we find that swish yields superior performance compared to the other activation functions routinely used in the PINN literature.
Motivation & Objective
- To address the slow convergence and reduced accuracy of PINN-based Helmholtz solvers in the presence of sharp velocity heterogeneities.
- To evaluate the impact of different activation functions on the training dynamics and solution quality of PINNs for wavefield modeling.
- To determine whether the swish activation function, known for improved performance in deep learning, enhances PINN performance for solving the Helmholtz equation.
- To provide empirical evidence for selecting optimal activation functions to accelerate convergence and improve accuracy in physics-informed deep learning for wave propagation.
Proposed method
- The study employs a physics-informed neural network (PINN) to solve the Lippmann-Schwinger form of the Helmholtz equation in a two-scatter velocity model.
- The PINN is trained using a loss function that enforces the residual of the Helmholtz equation, with automatic differentiation used to compute spatial derivatives.
- Eight fully connected hidden layers with 20 neurons each are used, and training is performed using the Adam optimizer for 15,000 epochs with a batch size of 256.
- Five activation functions are compared: tanh, atan, elu, and swish (a smooth, non-monotonic ReLU variant), with all hyperparameters kept constant for fair comparison.
- The SciANN package, a high-level Keras/TensorFlow wrapper, is used to implement the PINN and compute the loss function.
- Convergence is evaluated via loss history curves, and solution accuracy is quantified using L2 and L∞ norms for both real and imaginary parts of the wavefield.
Experimental results
Research questions
- RQ1Does the swish activation function improve convergence speed and accuracy in PINN-based Helmholtz solvers compared to standard activation functions like tanh, atan, and elu?
- RQ2How do different activation functions affect the training dynamics of PINNs when solving the Helmholtz equation with sharp velocity contrasts?
- RQ3Can the improved gradient flow properties of swish mitigate the vanishing gradient problem in PINNs trained on high-frequency wavefield problems?
- RQ4To what extent does the choice of activation function influence the feasibility of using PINNs for repeated wavefield modeling in applications like full waveform inversion?
Key findings
- The swish activation function achieves the fastest convergence rate, with the loss decreasing more rapidly in the first 2000 epochs compared to tanh, atan, and elu.
- Swish yields the lowest L2 error for both real and imaginary wavefield components: 3.65×10⁻⁵ (real) and 4.7×10⁻⁵ (imaginary), outperforming all other activation functions.
- Swish also produces the smallest L∞ error: 9.86×10⁻³ for the real part and 1.58×10⁻² for the imaginary part, indicating better maximum error control.
- The PINN with swish activation produces visibly lower wavefield error magnitudes in spatial distribution compared to other activation functions, as shown in Figure 3.
- The loss curves indicate that swish reaches a lower plateau faster, enabling earlier switching to second-order optimizers like L-BFGS, which could further accelerate convergence.
- Among the standard activation functions, elu performs worst, with the highest L2 and L∞ errors, while tanh and atan show similar but less favorable performance than swish.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.