## 4 Experimental Demonstration
### Result
#### 4.4.3 Experiment III: Noise Immunity Experiment of the Model  
Since most of the noise is Gaussian white noise, the standard for evaluating the strength of noise in a signal is the Signal Noise Ratio (SNR). Let \(P_{s}\) and \(P_{n}\) denote the energies of the signal and noise, respectively; then, the SNR formula is given in Equation (3). The more noise the signal contains, the smaller the SNR value will be. The signal and noise contain equal energy when the SNR value is 0 dB. \[SNR_{dB}=\frac{P_{s}}{P_{n}} \tag{3}\]  
In addition to Gaussian noise, practical applications may encounter other types of noise. We have also incorporated non-stationary signals and harmonic interference into our analysis. To simulate non-stationary signals, we added a component to the original signal that changes linearly over time. This addition alters the statistical properties, such as mean and variance, making them time-variant. Furthermore, we generated harmonic interference by defining specific frequencies, amplitudes, and phases to disrupt the periodicity of the original signal. This process mimics the variety of interferences encountered in real-world settings. In the noise immunity experiment, we first normalized the two datasets. We used the signal-to-noise ratio to measure the noise when adding white Gaussian noise to the dataset. We set the signal-to-noise ratio (SNR) in the range of \(-\)10 dB to 6 dB with a 2 dB interval. Then, different levels of white Gaussian noise were added to the normalized  
Figure 11: Accuracy of the individual models in HUST. dataset according to the range of the SNR. Then, we added non-stationary components and harmonic interference. Finally, the ratio of the training set, validation set, and test set was 7:1:2, the number of training iterations was 30, and the learning rate was set to 0.001. Figure 12a shows the image of the HUST dataset data after preprocessing by t-SNE dimensionality reduction visualization. The preprocessing of the data included the addition of various noises and so on. The image of the t-SNE dimensionality reduction visualization after model processing and classification is shown in Figure 12b. The training sets of the two datasets were used to train the model, and then the test set's prediction accuracy in the four models' noisy environment was compared. Its comprehensive average accuracy and standard deviation after five experiments are shown in Table 2.  
As illustrated in Table 2, the results of the model runs show that the traditional model takes a long time and the diagnostic results are low. Although the diagnostic results of the 1 DCNN-based LSTM and GRU models are close to 90%, these results may cause some trouble when applied to the industrial field. Our models in both datasets have good performance, with prediction accuracies of over 98%, and over 95% for the model that removes the multinomial self-attention mechanism. The difference between the two indicates that the multi-head self-attention mechanism has a good effect on noise immunity. In practice, since the model learns to deal with diverse noisy data, it improves its robustness and adaptability in practical applications. After conducting basic anti-noise experiments, we evaluated the performance of the multi-head attention mechanism. We are now set to further investigate the effect of varying the number of heads within the multi-head self-attention framework. Our unique internal configuration of the multi-head attention mechanism maintains a constant number of parameters at 686,023, regardless of the number of heads, occupying 5359.5 KB of memory. The experimental results in Table 3 show that under identical