Large model metal material fatigue life prediction method based on auto-encoder and Fourier transform enhancement
By introducing autoencoder and Fourier transform technology in the fatigue life prediction of metal materials, combined with the GPT2 model, the problems of low prediction accuracy and weak generalization ability of the traditional S-N curve method are solved, and higher prediction accuracy and generalization ability are achieved.
Patent Information
- Application Number
- CN202411625358.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-14
- Publication Date
- 2025-03-04
AI Technical Summary
The traditional S-N curve method has problems with low prediction accuracy and weak generalization ability in the prediction of fatigue life of metal materials.
The fatigue life prediction method of large-model metal materials based on autoencoder and Fourier transform enhancement is adopted. The original input data is reconstructed through the autoencoder, and the frequency domain characteristics of time series data are extracted in combination with Fourier transform technology, and the GPT2 large pre-trained language model is used for feature extraction and prediction.
It improves the accuracy and generalization ability of material fatigue life prediction, reduces the error of prediction results, and can better adapt to fatigue life prediction under complex materials and operating conditions.
Smart Images

Figure CN119560072A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of fatigue life prediction of metal materials, and relates to a large-model metal material fatigue life prediction method based on autoencoder and Fourier transform enhancement. Background Art
[0002] With the rapid development of modern industry, materials are increasingly used in various fields, and their reliability and life in service have become the focus of attention of engineers and technicians. At present, the main technical means of predicting material fatigue life is the SN curve, which was first proposed by August Wohler through a locomotive axle test in 1870. The curve reflects the fatigue life of materials under different stress levels.
[0003] Since then, researchers have continued to study the SN curve. In 1910, Basquin analyzed Based on the σ-N data obtained, an exponential equation type σ-N curve model for material fatigue life prediction was proposed. In 1914, Stromeyer analyzed Wohler's data and conducted bending and torsion fatigue tests on various materials. He proposed the concept that the σ-N curve would infinitely approach the fatigue limit, and improved the Basquin model into a relationship model that considers the fatigue limit. In order to be suitable for different fatigue load conditions, σ-N curve models such as the Gaussian-σ-N curve considering peak stress and error function and the Max-σ-N curve using the maximum likelihood value were gradually derived. In the middle of the 20th century, Coffin and Manson realized the important value of plastic strain to material fatigue life through cyclic thermal stress tests, and independently proposed a low-cycle fatigue failure model with strain amplitude as the control life parameter, that is, the ε-N curve that is widely used in addition to the σ-N curve. Until recently, some researchers have further improved the SN curve by modifying or adding parameters to achieve accurate prediction.
[0004] In addition, in order to prevent fatigue failure accidents, various fields usually formulate replacement cycles based on SN curves. However, according to later tests, most components that were disassembled due to reaching the replacement cycle still meet the conditions for continued use. In addition, in order to reduce the failure risk caused by low prediction accuracy and poor adaptability to unknown data, material strength design often adopts redundant design strategies. All of these have caused huge waste of resources and environmental problems.
[0005] The emergence of the SN curve has reduced the occurrence of fatigue failure accidents to a certain extent. However, due to the existence of material and load dispersion, and the fact that the SN curve model is based on linear or approximately linear assumptions, the fatigue life prediction for complex materials or working conditions is not accurate enough, resulting in large errors in the prediction results and difficulty in widespread application.
[0006] Therefore, a new method for predicting fatigue life of metal materials is urgently needed to solve the problems of low prediction accuracy and weak generalization ability of the traditional SN curve method. Summary of the invention
[0007] In view of this, the purpose of the present invention is to provide a large-model metal material fatigue life prediction method based on autoencoder and Fourier transform enhancement, to solve the problems of large error and low stability in predicting material fatigue life in the traditional S / N curve method, and propose a new AE-FELM model, which uses autoencoder to reconstruct the original input data, and reduces the dimension and preliminarily extracts the original data features. According to the time series attributes of the data features, a Fourier transform enhancement module is added to each feature extraction layer of the GPT2 large model to further improve the model's feature extraction ability for time series data.
[0008] In order to achieve the above object, the present invention provides the following technical solutions:
[0009] A large-model metal material fatigue life prediction method based on autoencoder and Fourier transform enhancement specifically comprises the following steps:
[0010] S1: Data acquisition and preprocessing: Obtain material stress loading deformation data through experiments and clean it to remove invalid and abnormal data;
[0011] S2: Data segmentation: Use sliding window technology to process data in blocks;
[0012] S3: Label generation: for each data block, a label of the remaining life percentage is generated according to the ratio of its corresponding loading times to the total loading times;
[0013] S4: Build and train the AE-FELM model: input the generated data blocks and their corresponding labels into the AE-FELM model for training, select the optimal model parameters, and save the trained optimal model; wherein the AE-FELM model represents a large model enhanced by an autoencoder and Fourier transform, including an autoencoder module and a Fourier transform enhancement module, and uses the GPT2 large pre-trained language model as a backbone network; the autoencoder module includes an encoder and a decoder;
[0014] S5: Prediction process: The block-processed test set is input into the trained AE-FELM model to output the material remaining life prediction result.
[0015] Furthermore, in step S1, the original data is cleaned, specifically including: firstly simplifying the data using a periodic aggregation method, and then normalizing the data using a Z-Score to remove the dimensional differences between different features or different time points, so that all features or time points have the same scale.
[0016] Further, in step S4, the encoder adopts a multi-layer perceptron (MLP) structure, including multiple hidden layers, and uses dropout technology to prevent overfitting; the input of the encoder is the length of the time series data, and the output is a feature vector matching the dimension of the hidden layer of the GPT2 model; the activation function uses ReLu;
[0017] The expression of the encoder is:
[0018]
[0019] Among them, h is the final output of the encoder, x is the input sequence, and They represent the weight and bias of the encoder layer l, L is the number of encoder layers, and σ is the activation function.
[0020] Further, in step S4, the output of the encoder is input to the position embedding layer, the output of the position embedding layer is input to the GPT2 unit, and the data output by the GPT2 unit is input to the normalization layer; the decoder receives the output of the normalization layer and attempts to reconstruct the original time series data.
[0021] Furthermore, in step S4, the position embedding layer implements position embedding through sine and cosine functions, and its expression is:
[0022]
[0023] Among them, P pos,i represents the position embedding of position pos on dimension i, d model is the dimension of the embedding vector in the model, pos is the position of the data in the sequence, and i is the dimension index of the embedding vector.
[0024] Furthermore, in step S4, the GPT2 unit has 12 recurrent links in the model. The data received from the position embedding layer will pass through a normalization layer and then enter the attention mechanism module and the Fourier transform module respectively. By considering the normalized features provided by the normalization layer, the attention mechanism can better model the contextual relationship in the sequence and capture long-distance dependencies. The output of the attention mechanism and the output of the Fourier transform module will be fused, then passed through a feedforward neural network, and finally passed through a Gaussian error unit activation function.
[0025] Further, in step S4, the expression of the normalization layer used in the GPT2 unit is:
[0026]
[0027] in, is the hth feature in the i-th sample, H is the number of features, μ (i) is the average value of all features of the i-th sample, σ 2(i) is the variance of all features of the ith sample, ε is a small constant for numerical stability; γ (i) and β (i) are learnable parameters, used for scaling and offset normalization respectively; is the normalized value, is the output of the normalization layer.
[0028] Further, in step S4, the decoder receives the output of the normalization layer and attempts to reconstruct the original time series data; the expression of the decoder is:
[0029]
[0030] in, is the final output of the decoder, is the output of the pre-trained model, and They represent the weight and bias of the lth layer of the decoder, L is the number of decoder layers, and σ is the activation function.
[0031] The beneficial effects of the present invention are as follows: the AE-FELM model constructed by the present invention adopts the autoencoder structure in deep learning, and realizes efficient feature extraction of time series data. Secondly, the Fourier transform technology is introduced to capture the frequency domain characteristics in the material fatigue process, thereby enhancing the model's understanding of the material fatigue behavior. The problems of low prediction accuracy and weak generalization ability of the traditional SN curve method are solved. In addition, the model of the present invention further improves the accuracy of prediction by utilizing the sequence modeling capability of the pre-trained GPT2 large model. The AE-FELM model can effectively extract features from time series data, and deeply mine frequency domain information in combination with Fourier transform, thereby improving the accuracy of prediction. In addition, the model shows good convergence on various data sets, avoids overfitting, and shows strong generalization ability. Compared with traditional methods, the AE-FELM model has better generalization and processing capabilities for complex data while maintaining high prediction accuracy.
[0032] Other advantages, objectives and features of the present invention will be described in the following description to some extent, and to some extent, will be obvious to those skilled in the art based on the following examination and study, or can be taught from the practice of the present invention. The objectives and other advantages of the present invention can be realized and obtained through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] In order to make the purpose, technical solutions and advantages of the present invention more clear, the present invention will be described in detail below in conjunction with the accompanying drawings, wherein:
[0034] Figure 1 To visualize the data;
[0035] Figure 2 It is the overall structural diagram of the AE-FELM model of the present invention;
[0036] Figure 3 It is the structural block diagram of Fourier transform module;
[0037] Figure 4 Detailed structural diagram of the AE-FELM model of the present invention;
[0038] Figure 5 It is a flow chart of the data changes within the AE-FELM model;
[0039] Figure 6 Flowchart of the AE-FELM model training process;
[0040] Figure 7 Flow chart of the prediction process for the AE-FELM model;
[0041] Figure 8 Loss plots for training, validation, and test sets;
[0042] Fig. 9 This is a comparison chart between the prediction results of the AE-FELM model of the present invention and the actual labels;
[0043] Fig.10 Confusion matrix for health level classification;
[0044] Fig.11 It is the box plot of different stress errors;
[0045] Fig.12 This is a comparative experimental display effect diagram of the AE-FELM of the present invention and the original SN. DETAILED DESCRIPTION
[0046] The following describes the embodiments of the present invention by specific examples, and those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the illustrations provided in the following embodiments only illustrate the basic concept of the present invention in a schematic manner, and the following embodiments and features in the embodiments can be combined with each other without conflict.
[0047] See also Figures 1 to 12 The present invention provides a large-model metal material fatigue life prediction method based on autoencoder and Fourier transform enhancement, which mainly includes the following parts:
[0048] 1. Dataset
[0049] (1) Data introduction
[0050] Based on a set of material stress loading deformation data obtained through experiments. This data set was obtained by stress loading experiments on 45 steel at a loading frequency of 20Hz, covering the deformation under different stress levels. The importance of experimental data lies in that it provides real and detailed information for analyzing material fatigue behavior. Table 1 shows some of the original stress loading data. The stress and displacement data at each time point are recorded.
[0051] Table 1 Stress loading raw data
[0052] Time / s Stress / N Displacement / mm 701.2031 2.40978 20.09094 701.2109 1.11607 20.07767 701.2188 11.53717 20.1668 701.2266 24.64837 20.28632 701.2344 28.96485 20.32958 701.2422 20.30875 20.25327 701.25 6.43677 20.12823 701.2578 -0.00161 20.06764
[0053] Visual data display such as Figure 1 As shown, from Figure 1 It can be clearly seen that the displacement changes of 45 steel at different stress levels show significant regularity. Over time, the displacement of the material shows a slight growth trend. Especially in the stage where the material is close to fracture, the displacement will increase sharply for a period of time. This phenomenon provides a key characteristic signal for the prediction of fatigue life.
[0054] The regularity of this displacement change indicates that the fatigue process of the material can be quantified and modeled. Therefore, the present invention proposes to use artificial intelligence methods to learn these characteristics, and on this basis, to achieve the prediction of the remaining life of the material in any time period.
[0055] (2) Data processing
[0056] The original data includes the entire process from the start of loading to the fracture of the material, and the number of data points is usually in the millions to tens of millions. Due to the huge amount of data, in order to facilitate analysis and processing, the present invention uses a periodic aggregation method to simplify the data, such as formula (1). Through periodic aggregation, time series data can be simplified and the amount of data can be reduced.
[0057]
[0058] Among them, x t is the tth data point in period T. Time series data often contain periodic patterns, and periodic aggregation can help the model better identify and capture these patterns. Then the data is normalized using Z-Score, as shown in formula (2). Through Z-Score normalization, the dimensional differences between different features or different time points can be removed, so that all features or time points have the same scale.
[0059]
[0060] Among them, x is the original data point, μ is the mean of the data set, and σ is the variance of the data set. This can reduce the noise in the data and improve the stability of the model, especially when dealing with noisy time series data.
[0061] Then, it is necessary to generate labels for the data set, taking the percentage of the remaining material loading times as the label, where the label allows a fluctuation range. The final generated label f(T) is shown in formula (3). This ensures that the output of the model has practical significance and can directly reflect the predictive value of time series data.
[0062] f(T)=[T(1-Δ),T(1+Δ)] (3)
[0063] Where T is the percentage of remaining loading times, and Δ is the allowable fluctuation range. By allowing a certain fluctuation range, the model will not focus too much on individual data points when fitting the data, but will be able to better capture the overall trends and patterns of the data. This helps the model better generalize to unseen data and improves the accuracy of predictions.
[0064] 2. AE-FELM model structure
[0065] like Figure 2 As shown in Figure 2, the AE-FELM model combines the autoencoder structure and Fourier transform enhancement technology, and is based on the GPT2 large pre-trained language model as the backbone network. The AE-FELM model contains an autoencoder module for extracting key features of time series data, and a Fourier transform module for enhancing the model's understanding of frequency domain features.
[0066] (1) Autoencoder module
[0067] The autoencoder module is added to the model because time series data itself has complex time dependencies and dynamic change characteristics. The autoencoder can convert these characteristics into internal representations that GPT2 can understand, thereby optimizing the model's training process and enabling the model to show stronger adaptability and robustness when facing practical problems. Therefore, the introduction of the autoencoder module is not only an innovation in the model structure, but also an improvement in the ability to analyze time series data.
[0068] The construction of the autoencoder module is divided into two parts: encoder and decoder. The encoder adopts a multi-layer perceptron (MLP) structure, whose input is the length of the time series data and output is a feature vector that matches the dimension of the hidden layer of the GPT-2 model.
[0069] In the specific implementation process, the encoder contains multiple hidden layers and uses dropout technology to prevent overfitting.
[0070]
[0071] Among them, x i is the i-th element of the input vector, r i is the value corresponding to x i A random Bernoulli variable, p is the retention probability of the Dropout layer.
[0072] The activation function uses ReLu, which helps alleviate the gradient vanishing problem and enables the neural network to be trained faster. Its formula can be expressed as:
[0073] f(x) = max(0,x) (5)
[0074] The ReLu function will output the larger value between 0 and x.
[0075] The encoder is responsible for extracting key features from the original time series data. These features capture the intrinsic structure and temporal dependencies of the time series, are compressed representations of the data, and can convert the time series into a text embedding form that is suitable for GPT2 input.
[0076] The encoder formula can be expressed as:
[0077]
[0078] Among them, h is the final output of the encoder, x is the input sequence, and Represent the weight and bias of the encoder layer l, L is the number of encoder layers, and σ is the activation function. The output of the encoder is input to the position embedding layer. The output of the encoder may already contain the content information of the data, but does not contain the position information of the element in the sequence. The position embedding layer adds position information to each element, which is crucial for understanding the time order and pattern in sequence data. Position embedding in GPT2 is achieved through sine and cosine functions, and its formula can be expressed as follows:
[0079]
[0080] Among them, P pos,i represents the position embedding of position pos on dimension i, d model is the dimension of the embedding vector in the model, pos is the position of the data in the sequence, and i is the dimension index of the embedding vector. The position embedding layer ensures that the model can take into account the position of each element in the original sequence, which is a key factor for prediction tasks.
[0081] Then, it will enter the GPT2 unit, and the data output by the GPT2 unit will be input into the normalization layer, which helps to stabilize the learning process of the neural network. Through normalization, the internal covariate shift can be reduced so that the input data of each layer maintains a similar distribution. The layer normalization formula used in GPT2 can be expressed as:
[0082]
[0083] in, is the hth feature in the i-th sample, H is the number of features, μ (i) is the average value of all features of the i-th sample, σ 2(i) is the variance of all features of the ith sample, ε is a small constant for numerical stability, and γ (i) and β (i) are learnable parameters, used for scaling and offset normalization, is the normalized value, is the output of the normalization layer. The normalization layer is crucial to maintaining the stability and efficiency of network training. It not only accelerates the convergence speed of the model, but also improves the generalization ability of the model for time series data.
[0084] The decoder receives the output of the normalization layer and attempts to reconstruct the original time series data. This process helps verify whether the autoencoder has effectively learned the intrinsic structure of the data. The formula for the decoder can be expressed as:
[0085]
[0086] in, is the final output of the decoder, is the output of the pre-trained model, and They represent the weight and bias of the lth layer of the decoder, L is the number of decoder layers, and σ is the activation function.
[0087] (2) GPT2 unit
[0088] The GPT2 unit has 12 recurrent links in the model. It receives data from the position embedding layer, passes through a normalization layer, and then enters the attention mechanism module and the Fourier transform module respectively. By considering the normalized features provided by the normalization layer, the attention mechanism can better model the contextual relationship in the sequence and capture long-distance dependencies. The attention mechanism is shown in formula (10).
[0089]
[0090] Among them, Q, K, V are the matrices of query, key and value respectively, and each row corresponds to an element of the input sequence. k is the dimension of the key vector. Through the attention mechanism, the model can focus on the most relevant part of the sequence while capturing long-distance dependencies, and can also improve the efficiency and accuracy of the model when processing time series data.
[0091] Fourier transform can effectively extract periodic features in time series data, which is crucial for many time series prediction tasks. By analyzing in the frequency domain, it can reveal features of the data that are not easily observed in the time domain, thereby improving the prediction accuracy and generalization ability of the model.
[0092] The detailed principle diagram of Fourier transformation is as follows: Figure 3 As shown in the figure, the Fourier transform module is introduced in parallel to enhance the model's understanding of the frequency domain characteristics of time series data. The framework structure of the Fourier transform module is designed to be consistent with the input and output shapes of the attention mechanism module of the original pre-trained model, ensuring that the new module can be seamlessly integrated into the existing model.
[0093] like Figure 3 , perform Fourier transform on the original time domain signal x input to the Fourier transform module. Through Fourier transform, we can reveal the characteristics of the signal in the frequency domain, which provides an additional information dimension for the model and helps improve the understanding of time series data and the prediction accuracy. First:
[0094]
[0095] Among them, x(t) is the signal in the time domain, and X(f) is the signal in the frequency domain. The result is a complex array that represents the amplitude and phase of the signal at each frequency component. Because complex signals cannot be directly processed in neural networks, we need to decompose this complex array into two independent real arrays: real part and imaginary part.
[0096]
[0097] Among them, real_art represents the real part and imag_art represents the imaginary part. By extracting the real and imaginary parts, we ensure that the frequency component information revealed by the Fourier transform is not lost.
[0098] Then the real part and the imaginary part are concatenated to achieve information integration. Concatenating the real part and the imaginary part can create a composite feature representation FDF, which combines the amplitude and phase information of the signal, providing richer input features for the neural network.
[0099] FDF=[real_art,imag_art] (13)
[0100] Then, FDF and x(t) are input into the fully connected neural network f 1 and f 2 In a fully connected network, feature learning is usually performed through multiple hidden layers, each of which provides a more abstract representation of the input data. In the process of converting from the input layer to the hidden layer, the network gradually extracts and combines features through a combination of weights and activation functions. This allows each network to independently learn features from the input data and output its learned representation. Finally, the outputs of the two networks are fused to obtain the final output X fft :
[0101]
[0102] in, Represents the fusion coefficient. This multi-angle feature extraction not only enhances the expressiveness of the model, but also allows each network to be optimized for its specific input by independent processing. Ultimately, the learning results of the two networks can be fused in the high-level layers of the model to generate more accurate and robust predictions.
[0103] Next, the output of the attention mechanism and the output of the Fourier transform module are fused, then passed through a feedforward neural network, and finally through a Gaussian error unit activation function, as shown in formula (15), which can provide nonlinear and regularization effects and help improve the performance of the model.
[0104]
[0105] Among them, erf(x) is the error function. Compared with other activation functions, the Gaussian error unit activation function can better avoid the problem of gradient disappearance or explosion when processing large models, which is crucial for model training and convergence.
[0106] So far, the detailed structure of the AE-FELM model is as follows Figure 4 As shown in the figure, through this structure, the AE-FELM model can not only utilize the powerful ability of GPT2 to process complex sequence data, but also enhance its feature extraction ability through FFT, thereby achieving higher accuracy and stability in material fatigue life prediction.
[0107] 3. Hyperparameter settings
[0108] In terms of feature extraction, the present invention adopts the GPT2 pre-trained model as the basis, while freezing its original parameters, and only updates the encoder and decoder connected to GPT2, as well as the newly added Fourier transform module to enhance the model's understanding of frequency domain features.
[0109] During the model training process, the sliding window method was used, and the input time series length was set to 1024, which included three features: time, stress, and displacement. The output result length was a 2-dimensional array, which contained the upper and lower limits of the predicted remaining material life. The mean square error loss was used as the loss function to evaluate the prediction performance of the model. The Adam optimizer was used during the training process, and the initial learning rate was set to 0.0001. The entire training process includes 100 cycles, and an early stopping strategy is introduced. If the loss does not improve significantly within 5 consecutive cycles, the training is stopped in advance to prevent overfitting. Through these experimental steps, we aim to test the predictive ability of the AE-FELM model in practical applications and its superiority over traditional methods. For the above settings, it can be obtained by Figure 5 To understand in detail how the data changes as it passes through the AE-FELM model.
[0110] Figure 5 Taking the input time length of 1024 and the input features of time, stress, and displacement as an example, a detailed transformation view of the data is shown. The output shape 2x1 represents the upper and lower limits of the predicted output result. Figure 5 The detailed changes of the input data after preprocessing through each network layer of the model are shown in detail. It details the process from input to encoder, position embedding, normalization layer, feedforward neural network, Gaussian error linear unit activation function, normalization layer, decoder, and the relationship between these components.
[0111] 4. Training and prediction
[0112] (1) The specific steps of AE-FELM model training are as follows:
[0113] ① Data preprocessing: First, the raw data is cleaned to remove invalid and abnormal data to ensure data quality.
[0114] ② Data Blocking: The cleaned raw data has a matrix structure with a dimension of (n,3). Taking 1024 time windows as an example, the sliding window technology is used to block the data. Through this method, n-1024+1 data blocks with a dimension of (1024×3) can be extracted from the raw data.
[0115] ③ Label generation: For each data block, a label of the remaining life percentage is generated according to the ratio of its corresponding loading times to the total loading times. For example, if the current loading times account for 35% of the total loading times, the remaining life percentage is 65%. In this embodiment, the fluctuation range of the label value is set to ±5%, so the generated label value range is (0.6, 0.7).
[0116] ④Model training and saving: Input the above generated data blocks and their corresponding labels into the training model for model training. During the training process, select the optimal model parameters, and save the best model after the training is completed for subsequent use.
[0117] (2) Prediction process:
[0118] ① Sample construction: Using the test set, with 1024 data points as the window length, aggregate the 1024 data points in the window into one sample. According to this method, n samples containing 1024 data points can be constructed from the processed data set.
[0119] ② Prediction process: Input each sample into the trained model one by one. The model will process each input sample and output a prediction result.
[0120] ③Result output: For each sample of 1024 data points, the model outputs the corresponding predicted value, which represents the remaining life percentage of the sample. Through this process, each of the n samples in the entire data set will obtain their own prediction results, thereby realizing the prediction of the remaining life of the material.
[0121] 5. Experimental results
[0122] (1) Experimental results and analysis
[0123] The loss during model training is as follows: Figure 8 As shown in Figure 1, we can observe that the loss curves of the model on the training set, validation set, and test set all show a trend of gradual convergence and eventually reach the optimal state. These three curves show that the model not only achieves good training results, but also maintains good generalization ability.
[0124] from Figure 8 It can be seen that the loss curve of the training set decreases steadily, indicating that the model has learned effective features on the training data. At the same time, the loss curves of the validation set and the test set are similar to the trend of the training set, and the loss values are relatively close, which shows that the model does not have overfitting and can adapt well to unseen data. This result verifies the stability and reliability of the AE-FELM model in the material fatigue life prediction task.
[0125] To further demonstrate the reliability of the model, this experiment used a uniform sampling method to analyze the test set. Specifically, we randomly selected 100 time series from the data of each material in the test set for prediction. These time series represent the deformation of different materials under specific stress levels. This experiment predicted each time series and compared the model's prediction results with the actual labels.
[0126] like Fig. 9 As shown, Fig. 9 The blue line is the actual life of the material, and the shaded area is the remaining life range predicted by the model. Fig. 9 In , the prediction label is expressed as a range, which represents the range of the remaining life prediction predicted by the model. Fig. 9 It can be clearly seen that under various stress levels, as time goes by, the actual label is basically within the range of the remaining life predicted by the model. This result shows that the AE-FELM model has a strong generalization ability and high prediction accuracy when dealing with the fatigue life prediction problem of 45 steel under different stress conditions.
[0127] (2) Ablation experiment
[0128] The effects of the model with Fourier transform module and without Fourier transform module are compared in detail. Since there are prediction results under various stresses, in order to more intuitively and comprehensively reflect the prediction effects of the two methods under various stresses, a classification method is used here.
[0129] The specific classification method is as follows: when the predicted value of remaining life span is above 0.7, it is classified as "healthy"; when the predicted value is above 0.4 and below 0.7, it is classified as "sub-healthy"; when the predicted value is above 0.2 and below 0.4, it is classified as "unhealthy"; and when the predicted value is below 0.2, it is classified as "dangerous". Through this classification method, Fig.10 , the final prediction results can be plotted as a confusion matrix to intuitively demonstrate the classification accuracy of the model.
[0130] The final confusion matrix result is as follows Fig.10As shown in the confusion matrix, it can be seen that when the AE-FELM model has the Fourier transform module, the prediction results of the model are more accurate and stable, and even the situation of deviating from the true category by one level rarely occurs. This shows that AE-FELM has high classification stability and reliability when predicting the fatigue life of metal materials.
[0131] The ablation experiment further confirmed the potential of the prediction method proposed in this paper in practical applications through the results of the confusion matrix. Through accurate classification, engineers can better assess the health of materials and take corresponding maintenance measures to ensure the safety and reliability of the structure.
[0132] (3) Comparison between AE-FELM model and Autofomer
[0133] In order to comprehensively evaluate the performance of the AE-FELM model in material fatigue life prediction, Autoformer and ANN are used for comparison. ANN is the most widely used neural network in the field of fatigue research, and the Autoformer model has been proven to be very effective in long-term series prediction. All predicted lives are percentages of the remaining life of the material and are compared with the actual labels, with the error as the evaluation indicator.
[0134] like Fig.11 As shown in the figure, a piece of data is randomly selected under each stress data, and the remaining life of the material is predicted through this piece of data. Then, through multiple sampling, the error between the predicted result and the actual result is used as the evaluation index to draw a box plot. Under the same data set, the prediction accuracy, generalization ability, data processing ability and practicality of the AE-FELM model are better than the other two methods. The average error of AE-FELM is 4.62%, which is significantly lower than 12.37% of Autoformer and 22.88% of ANN. This fully demonstrates the superiority and reliability of the AE-FELM model in material fatigue life prediction.
[0135] (4) Comparison between AE-FELM model and SN model
[0136] The SN model makes predictions based on stress values, while the AFLM model requires more loading data to improve the accuracy of the prediction. Prediction experiments were conducted on the SN model and the AE-FELM model, respectively. The amount of input data was gradually increased from 1% to 30% to explore the effect of the amount of data on the prediction performance of the model.
[0137] Implementing SN model prediction:
[0138] ① Input the test set samples into the fitted SN curve one by one.
[0139] ②Record the model output results and calculate the Pearson correlation coefficient between the predicted value and the actual value. Finally, take an average Pearson correlation coefficient for all results.
[0140] Implementing AE-FELM model prediction:
[0141] ① Input the same test set samples into the trained AE-FELM model.
[0142] ②Record the model output results, calculate the Pearson correlation coefficient between the predicted value and the actual value, and finally take an average Pearson correlation coefficient for all results.
[0143] Experimental results:
[0144] ① The comparative experiment between AE-FELM and original SN shows that AE-FELM has a higher relevance in predicting the remaining life of materials.
[0145] ② Using the Pearson Correlation Coefficient as the evaluation index, the correlation of the prediction results of the original SN model is less than 0.7. Fig.12 It can be seen that the prediction results at this time are more divergent and the accuracy is not high.
[0146] ③ When the original SN model was combined with about 5% of the previous data, its correlation increased to 0.9, and the prediction effect was significantly improved.
[0147] ④With the increase of the amount of loaded data, the correlation coefficient of the AE-FELM model gradually increases, and the prediction stability becomes better and better.
[0148] Experimental steps for health status detection and evaluation:
[0149] ① Random data sampling: Randomly extract a certain proportion of data samples from the test set to ensure that the sampling process is representative, so as to facilitate the evaluation of the generalization ability of the model prediction results.
[0150] ②Model prediction: The sampled data set is input into the trained model, and the model generates corresponding prediction values based on the input data. This step is the key to evaluating the performance of the model and ensuring that the model can accurately predict the material state.
[0151] ③ Determination of the classification interval of the predicted value: According to the preset classification criteria, the predicted value of the model is divided into corresponding classification intervals. Specifically, it is determined whether each predicted value belongs to the state of "healthy", "sub-healthy", "unhealthy" or "dangerous".
[0152] ④ Result comparison and confusion matrix drawing: Compare the model’s predicted classification results with the classification intervals of the actual labels to evaluate the model’s classification accuracy.
[0153] Based on the comparison results, a confusion matrix is drawn. The confusion matrix is a specific table layout used to visualize algorithm performance. It shows the relationship between the actual category and the model prediction category, including true positive examples (True Positive, TP), false positive examples (False Positive, FP), true negative examples (True Negative, TN) and false negative examples (False Negative, FN).
[0154] like Fig.10 As shown, through Fig.10 The confusion matrix shown can intuitively observe the performance of the model in each classification interval, and then analyze the classification effect of the model, providing a basis for model optimization and practical application.
[0155] Compared with the SN model, the AFLM model has the following advantages: AFLM can evaluate the remaining life of materials based on fatigue loading test data, while the SN model only relies on stress values and cannot evaluate the life of used materials. Our method can determine the life of any material under this stress through loading data. The application of the AFLM model makes the material health status assessment more comprehensive and provides a basis for use and maintenance. The material status classification standards are as follows:
[0156] Healthy status: Remaining life ≥ 0.5, indicating low fatigue damage and high reliability.
[0157] Sub-health status: 0.2≤Remaining life<0.5, indicating that the material has fatigue damage but can still be used.
[0158] Unhealthy state: 0.01≤Remaining life<0.2, the material is severely damaged and requires monitoring and maintenance.
[0159] Dangerous status: Remaining life <0.01, critical damage, need to be stopped and replaced immediately.
[0160] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solution of the present invention can be modified or replaced by equivalents without departing from the purpose and scope of the technical solution, which should be included in the scope of the claims of the present invention.
Claims
1. A large model metal material fatigue life prediction method based on autoencoder and Fourier transform enhancement, characterized in that: The method specifically comprises the following steps: S1: Data acquisition and preprocessing: Obtain material stress loading deformation data through experiments and clean it to remove invalid and abnormal data; S2: Data segmentation: Use sliding window technology to process data in blocks; S3: Label generation: for each data block, a label of the remaining life percentage is generated according to the ratio of its corresponding loading times to the total loading times; S4: Build and train the AE-FELM model: input the generated data blocks and their corresponding labels into the AE-FELM model for training, select the optimal model parameters, and save the trained optimal model; wherein the AE-FELM model represents a large model enhanced by an autoencoder and Fourier transform, including an autoencoder module and a Fourier transform enhancement module, and uses the GPT2 large pre-trained language model as a backbone network; the autoencoder module includes an encoder and a decoder; S5: Prediction process: The block-processed test set is input into the trained AE-FELM model to output the material remaining life prediction result.
2. The large-model metal material fatigue life prediction method according to claim 1 is characterized in that: In step S1, the original data is cleaned, specifically including: firstly simplifying the data using a periodic aggregation method, and then normalizing the data using a Z-Score to remove the dimensional differences between different features or different time points, so that all features or time points have the same scale.
3. The large-model metal material fatigue life prediction method according to claim 1 is characterized in that: In step S4, the encoder adopts a multi-layer perceptron structure, including multiple hidden layers, and uses dropout technology to prevent overfitting; the input of the encoder is the length of the time series data, and the output is a feature vector matching the dimension of the hidden layer of the GPT2 model; the activation function uses ReLu; The expression of the encoder is: Among them, h is the final output of the encoder, x is the input sequence, and They represent the weight and bias of the encoder layer l, L is the number of encoder layers, and σ is the activation function.
4. The large-model metal material fatigue life prediction method according to claim 3 is characterized in that: In step S4, the output of the encoder is input to the position embedding layer, the output of the position embedding layer is input to the GPT2 unit, and the data output by the GPT2 unit is input to the normalization layer; The decoder takes the output of the normalization layer and tries to reconstruct the original time series data.
5. The large-model metal material fatigue life prediction method according to claim 4 is characterized in that: In step S4, the position embedding layer implements position embedding through sine and cosine functions, and its expression is: Among them, P pos,i represents the position embedding of position pos on dimension i, d model is the dimension of the embedding vector in the model, pos is the position of the data in the sequence, and i is the dimension index of the embedding vector.
6. The large-model metal material fatigue life prediction method according to claim 4 is characterized in that: In step S4, the GPT2 unit has 12 recurrent links in the model. The data received from the position embedding layer will pass through a normalization layer and then enter the attention mechanism module and the Fourier transform module respectively. By considering the normalized features provided by the normalization layer, the attention mechanism can better model the contextual relationship in the sequence and capture long-distance dependencies. The output of the attention mechanism and the output of the Fourier transform module will be fused, then passed through a feedforward neural network, and finally passed through a Gaussian error unit activation function.
7. The large-model metal material fatigue life prediction method according to claim 6, characterized in that: In step S4, the expression of the normalization layer used in the GPT2 unit is: in, is the hth feature in the i-th sample, H is the number of features, μ (i) is the average value of all features of the i-th sample, σ 2(i) is the variance of all features of the ith sample, ε is a small constant for numerical stability; γ (i) and β (i) are learnable parameters, used for scaling and offset normalization respectively; is the normalized value, is the output of the normalization layer.
8. The large-model metal material fatigue life prediction method according to claim 4 is characterized in that: In step S4, the decoder receives the output of the normalization layer and attempts to reconstruct the original time series data; the expression of the decoder is: in, is the final output of the decoder, is the output of the pre-trained model, and They represent the weight and bias of the lth layer of the decoder, L is the number of decoder layers, and σ is the activation function.
Citation Information
Cited By
Thermal fatigue assessment method and device for safety hook rigging based on artificial intelligence
CN119783009A