A method for composite defect stress distribution inversion
By decoupling dual-mode excitation signals and using a multi-scale deep learning model, the problems of insufficient accuracy and signal coupling interference in the inversion of stress distribution of composite defects in pipelines are solved, realizing high-precision automated inversion of stress distribution of pipeline defects and improving the reliability of pipeline safety assessment.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHENYANG UNIVERSITY OF TECHNOLOGY
- Filing Date
- 2025-12-05
- Publication Date
- 2026-04-14
AI Technical Summary
Traditional non-destructive testing techniques suffer from insufficient stress inversion accuracy, severe signal coupling interference, and a lack of sample data in the inversion of stress distribution in pipeline composite defects, making it difficult to achieve accurate assessment.
By employing a dual-modal excitation signal decoupling and a multi-scale deep learning model, and by constructing an MCL-Net architecture and an improved snow melting optimization algorithm (ISAO), combined with a multi-scale convolutional neural network-long short-term memory network (MCL-Net) and a bidirectional LSTM-multi-head attention module, a stress inversion model is built to achieve automated and high-precision inversion of the stress distribution of composite defects in pipelines.
It significantly improves the accuracy of stress inversion and solves the problems of theoretical model dependence on assumptions, signal coupling interference and lack of sample data in traditional methods, providing reliable technical support for pipeline safety assessment.
Smart Images

Figure CN121457043B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of pipeline nondestructive testing and stress assessment technology, and in particular to a method for inverting the stress distribution of composite defects in pipelines based on dual-modal excitation signals and deep learning. Background Technology
[0002] Oil and gas pipelines, as the "main arteries" of global energy transportation, are directly related to the lifeline of the national economy and the safety of the ecological environment. However, during long-term service, pipelines often develop crack-stress composite defects due to factors such as corrosion, mechanical loads, and geological activities. This is a complex damage morphology where crack defects and stress concentration areas are coupled. Stress concentration accelerates crack propagation, while the high stress field at the crack tip further induces material embrittlement, creating a vicious cycle. The concealment and synergistic destructive effects of such defects significantly increase the risk of pipeline failure. According to statistics from the Pipeline Research Council International (PRCI), the probability of pipeline failure caused by composite defects can be about five times that of single defects. Therefore, how to accurately infer the stress distribution in composite pipeline defects has become a core problem that urgently needs to be solved in the field of oil and gas pipeline safety inspection. Traditional non-destructive testing techniques, including magnetic flux leakage testing (MFLT), eddy current testing (ECT), ultrasonic testing (UT), magnetic memory testing (MMT), and weak magnetic field testing (WMD), are widely used in pipeline defect detection, but they have significant limitations in stress inversion.
[0003] (1) Theoretical model depends on assumptions: Traditional methods based on theoretical derivation result in deviations from measured values, making it difficult to achieve accurate prediction.
[0004] (2) Signal coupling interference: The coupling interference between crack and stress signals is significant, and the magnetic permeability abrupt change and magnetic anisotropy nonlinear superposition are also present.
[0005] (3) Limitations of detection technology: Weak magnetic field detection can preserve stress characteristics but has a low signal-to-noise ratio, while strong magnetic field detection has a high signal intensity but is easily masked by magnetic saturation.
[0006] (4) Scarcity of sample data: This field generally faces the problem of scarce sample data, which severely limits the generalization ability of the algorithm.
[0007] There is an urgent need to develop a stress quantification technology that integrates strong and weak magnetic mechanisms with data-driven methods to bridge the gap between theory and practice and provide reliable support for accurate assessment of pipeline safety status. Summary of the Invention
[0008] The purpose of this invention is to provide a method for inverting the stress distribution of composite defects in pipelines. By decoupling dual-mode excitation signals and using a multi-scale deep learning model, this method solves the problems of insufficient stress inversion accuracy and severe signal coupling interference in traditional methods, thereby achieving automated and high-precision inversion of the stress distribution of pipeline defects.
[0009] To achieve the above objectives, the present invention provides the following solution:
[0010] A method for constructing pipeline coupling signals and inverting stress distribution in pipeline composite defects, the method comprising the following steps:
[0011] Step 1: Obtain the dual-mode magnetic signal data of the target pipeline to be detected, and construct a dual-mode excitation signal training dataset;
[0012] Step 2: Construct a stress inversion model based on the MCL-Net architecture; construct a deep learning model for stress inversion based on a multi-scale convolutional neural network-long short-term memory network (MCL-Net) and a bidirectional LSTM (BiLSTM)-multi-head attention module; use the dual-modal excitation signal training dataset as the input to the stress inversion model, and systematically train the stress inversion model to obtain the trained MCL-Net stress inversion model;
[0013] Step 3: Construct an improved optimization algorithm training framework; Based on the improved snow melting optimization algorithm (ISAO), a model hyperparameter optimization system is constructed. Through dynamic temperature decay mechanism and mixed Gaussian perturbation strategy, the key parameters in the MCL-Net model are intelligently optimized to improve the model convergence speed and generalization ability.
[0014] Step 4: Establish a multi-objective loss function evaluation system.
[0015] Optionally, in step 1, the training dataset includes pipeline magnetic signal data collected under two magnetization levels: high and low. Each complete training sample consists of a composite signal detected by weak excitation (containing superposition information of defect leakage magnetic flux and stress magnetic anisotropy) and a magnetic signal decoupled based on scaling theory. The dual-channel time-series signal retains the hysteresis characteristics of ferromagnetic materials through strict time-series segmentation, thus forming complete pipeline composite defect stress inversion training data.
[0016] Optionally, in step 3, the key parameters include the learning rate, hidden layer dimension, contrastive loss weights, and peak sensitivity coefficient.
[0017] Optionally, in step 4, a multi-objective loss function evaluation system is constructed based on the contrastive learning mechanism and peak sensitivity characteristics, using mean squared error (MSE) and coefficient of determination (R²) as the evaluation criteria. 2The root mean square error (RMSE), mean absolute error (MAE), and mean absolute percentage error (MAPE) are used as performance evaluation indicators to establish a complete stress inversion quality evaluation standard.
[0018] Optionally, the MCL-Net stress inversion model includes a multi-scale CNN feature extraction branch, a bidirectional LSTM temporal modeling branch, a multi-head attention mechanism branch, and a loss function optimization branch; the accuracy evaluation system for stress inversion includes a parameter optimization branch based on the ISAO algorithm, a multi-index performance evaluation branch, and an engineering verification branch.
[0019] Optionally, the multi-scale CNN feature extraction branch adopts a parallel convolutional structure, which includes a 1×1 convolutional kernel responsible for feature channel fusion, a 1×3 convolutional kernel for extracting local detail features, and a 1×5 convolutional kernel for capturing long-range trend features. Multi-scale features are adaptively weighted and fused through a channel attention mechanism.
[0020] Optionally, the improved snow ablation optimization algorithm (ISAO) establishes a dynamic coupling relationship between the temperature decay coefficient and the particle diversity index through a four-dimensional parameter space search and a particle swarm temperature-sensitive update strategy, thereby achieving intelligent exploration of the hyperparameter space.
[0021] Optionally, the four-dimensional parameter space search includes: learning rate, hidden layer dimension, contrastive loss weight, and peak sensitivity coefficient.
[0022] Optionally, the multi-objective loss function evaluation system includes a contrastive loss function and a peak-sensitive loss function. The contrastive loss function enhances the feature decoupling capability by calculating the cosine similarity matrix of all feature pairs, while the peak-sensitive loss function applies a stronger L1 loss weight to peak samples that exceed a threshold, prioritizing the fitting of key stress concentration regions.
[0023] Optionally, the criteria for identifying the key stress concentration region are:
[0024] (1) Determination of stress amplitude threshold:
[0025] When the local stress value exceeds a certain proportion of the material's yield strength (e.g., θ=0.8, corresponding to the normalized stress threshold), the region is defined as a critical stress concentration area.
[0026] (2) Signal morphology matching degree:
[0027] Physical consistency was confirmed by comparing the peak waveform of the decoupled magnetic signal (MFLds) with typical stress concentration patterns (such as single-peak, double-peak, or saddle-shaped features) and combining the correlation coefficient (such as Pearson coefficient > 0.85).
[0028] The process of acquiring dual-mode magnetic signal data of the target pipeline to be detected, using magnetic signal decoupling technology to obtain the input of the MCL-Net model, and using the trained MCL-Net model, combined with the stress distribution inversion and accuracy evaluation criteria, to invert the stress distribution at the composite defect of the target pipeline, specifically includes:
[0029] Acquire dual-mode magnetic signal data of the target pipeline to be inspected;
[0030] A decoupled magnetic signal is obtained using strong magnetic signal decoupling technology, and is used together with the acquired original weak magnetic data as input to the MCL-Net model.
[0031] The magnetomechanical coupling effect of ferromagnetic materials exhibits a characteristic excitation threshold: such as Figure 1 As shown in (a), when the excitation intensity is in region A of the transition zone at the knee of the BH curve, the modulation effect of the magnetoelastic deformation caused by magnetostriction on the leakage magnetic field reaches its peak. At this time, as... Figure 1 As shown in (c), the synergistic effect of domain wall displacement and stress field leads to a significant magnetic-mechanical hybrid characteristic in the detection signal. As the magnetization intensity increases to the saturation region B, the domains complete their directional alignment, and the influence of stress disturbance on the magnetization vector is suppressed, as shown... Figure 1 As shown in (b), the detection signal degenerates into a pure geometric deformation function. By selecting low and high dual-mode excitation conditions, the stress-deformation integrated information and geometric deformation reference data of the composite defect can be obtained separately.
[0032] Optionally, the magnetic signal decoupling process employs dual magnetization state comparison and signal layering processing techniques. The specific process includes:
[0033] (1) Obtaining pure component signals containing only geometric features at high magnetization levels (corresponding to) Figure 1 (d) After normalization, a calibration signal is generated (corresponding to...). Figure 1 (e));
[0034] (2) Acquiring composite signals coupled with geometric and magnetoelastic effects at low magnetization levels (corresponding to) Figure 1 (f));
[0035] (3) Map the calibration signal to a low magnetization level to form a reconstructed signal (corresponding to) Figure 1 (g));
[0036] (4) By decoupling the geometric components, the magnetostrictive distortion signal reflecting the stress distribution is finally extracted (corresponding to) Figure 1 (h)).
[0037] Optionally, the decoupled magnetic signal construction method is based on the principle of dual-mode data fusion, and its mathematical representation is shown in the following equation:
[0038] ;
[0039] In the formula, It is the scaling factor of the magnetic signal during the decoupling process. It is the magnetic field strength at high magnetization. It is the magnetic field strength at low magnetization.
[0040] ;
[0041] In the formula, It is a decoupling signal. It is a magnetic signal detected under a weak excitation magnetic field. It is a magnetic signal detected under a strong excitation magnetic field.
[0042] Optionally, the scaling theory reveals the separation mechanism of magnetic-force coupled signals through a two-dimensional feature map. Figure 2 (a) The magnetic induction intensity B exhibits nonlinear saturation characteristics as it evolves with the magnetic field intensity H. The scaling ratio is determined based on the excitation intensity. Figure 2 (b) Comparative analysis of the axial magnetic field signals shows that the coupled signal components are effectively separated by the signal difference calculation under high and low magnetization states, and the local magnified image clearly shows the unique single-peak fluctuation shape of this component.
[0043] Optionally, constructing the dual-mode magnetic signal training dataset specifically includes:
[0044] Acquire historical pipeline dual-mode magnetic signal data: High and low magnetization level signals under different stress conditions (0-80MPa) and excitation current (0-8A) are collected through an experimental platform (such as WAW-2000 tensile testing machine);
[0045] Extract the magnetic signal matrix of the composite defect: The time window is truncated with the defect as the center. Each sample contains a weak excitation composite signal (MFLsub) and a strong excitation reference signal (MFLsat), forming a data matrix of size (sequence length × 2).
[0046] Construct a standardized training set: Divide the data matrix into training, validation, and test sets in a ratio of 7:1.5:1.5, and perform independent normalization.
[0047] Optionally, the construction of the MCL-Net-based stress inversion model training dataset specifically includes: concatenating the decoupled magnetic signal (MFLds) and the original weak magnetic signal (MFLsub) along the channel dimension to form dual-channel input data (shape [batch size, sequence length 3, feature number 2]). The output labels are the true stress distribution values obtained through finite element simulation or experimental measurement, normalized to the [-1, 1] interval.
[0048] Optionally, the multi-scale feature extraction module of the MCL-Net model specifically includes:
[0049] The preprocessed dual-channel temporal signal is input into a parallel multi-scale convolutional structure, where:
[0050] A 1×1 convolutional kernel is responsible for feature channel fusion and dimension adjustment, with an output channel count of 256.
[0051] The 1×3 convolution kernel focuses on extracting local detailed features and high-frequency components of the axial weak excitation signal;
[0052] A 1×5 convolution kernel is used to capture the long-range trend and overall distribution pattern of the signal;
[0053] The weighting formulas for features at each scale are as follows:
[0054] ;
[0055] ;
[0056] in, Indicates the first The average feature of each branch feature Indicates the length of the time series. Indicates the first Each branch in time Features This represents the learnable weight matrix.
[0057] The adaptive fusion formula dynamically adjusts the weights of features at each scale using a channel attention mechanism:
[0058] ;
[0059] in, This represents the fused feature map. These are the channel attention weights for the convolutional branches.
[0060] Optionally, the bidirectional LSTM (BiLSTM) multi-head attention module specifically includes: a bidirectional LSTM network inputting the fused feature sequence, which is configured with 128 hidden units and a 2-layer bidirectional structure to capture the nonlinear temporal characteristics of the hysteresis loop through the interaction of contextual information;
[0061] The spatiotemporal features are then incorporated into a multi-head attention mechanism, employing four attention heads to learn the temporal correlation patterns of different subspaces in parallel. The calculation formula is as follows:
[0062] ;
[0063] ;
[0064] ;
[0065] in, For each dimension of attention head, For the number of attention heads, This is the output feature matrix of the multi-head attention mechanism. This is a multi-head attention mechanism.
[0066] The loss function co-processing workflow is as follows:
[0067] Step 1: Dual-modal signal input and data augmentation; The preprocessed dual-channel time-series signal (weak excitation composite signal and decoupled magnetic signal) is input into the MCL-Net model. Gaussian noise (mean 0, variance 0.1) is injected to simulate probe lift-off fluctuations and electromagnetic interference, enhancing the model's robustness. The input data dimensions are (batch size, sequence length 3, number of features 2).
[0068] Step 2: Multi-scale feature extraction and contrastive learning; features are extracted through a parallel multi-scale convolution module, and the similarity between the projection vectors of the enhanced sample and the original sample is calculated;
[0069] Step 3: Peak-sensitive loss calculation; calculate the peak-sensitive loss based on the characteristics of the stress concentration region;
[0070] Step 4: Multi-target loss fusion and backpropagation; The contrastive loss and peak-sensitive loss are fused according to their weights to obtain the total loss function;
[0071] Step 5: Dynamic Optimization and Early Stopping Mechanism; After each training round, the validation set MSE of the ISAO algorithm is evaluated, and dynamic temperature decay balance is explored and developed. When the validation set MSE does not decrease for three consecutive rounds, early stopping is triggered to save the historical best model;
[0072] Repeat steps 1-5 multiple times until the model achieves optimal performance on the validation set. Finally, output the optimized MCL-Net model parameters and the ISAO hyperparameter combination.
[0073] Optionally, the loss function branch includes a gradient consistency constraint term, which calculates the gradient difference between the predicted curve and the actual stress distribution using first-order differencing to reduce phase error. Simultaneously, Dropout and weight decay regularization techniques are employed to prevent overfitting.
[0074] Optionally, the ISAO algorithm explores global parameters with a probability of 68% in the high-temperature stage (initial temperature T=1000) and finely adjusts the loss weight with a probability of 22% in the low-temperature stage (T≈659), thereby achieving intelligent optimization of hyperparameters through four-dimensional parameter space search.
[0075] Optionally, the hyperparameter optimization process of the improved snow ablation optimization algorithm (ISAO) specifically includes:
[0076] Establish a four-dimensional parameter search space: learning rate [0.001, 0.01], batch size [16, 128], hidden layer dimension [64, 512], contrastive loss weight [0.1, 1.0], peak sensitivity coefficient [3.0, 8.0];
[0077] Optionally, the iterative control mechanism of the improved snow ablation optimization algorithm (ISAO) specifically includes:
[0078] In terms of algorithm iteration control, the original fixed number of iterations is replaced by a combination of dynamic annealing mechanism and maximum iteration expansion. An exponentially decaying temperature parameter dynamically balances the intensity of global exploration and local exploitation. The temperature update and melting probability in the dynamic annealing mechanism are expressed as:
[0079] ;
[0080] ;
[0081] ;
[0082] in, For the next temperature value, The temperature decay coefficient is The value is 1000. Indicates the first Normalized scores of each sample Indicates the first The original scores of each sample It is a local minimum. Indicates the first The melting probability of a sample. This indicates the current temperature.
[0083] Optionally, the hybrid Gaussian perturbation strategy specifically includes:
[0084] In terms of exploration strategies, Gaussian perturbation (local fine-tuning) and stochastic reinitialization (global exit) cover a more comprehensive solution space. The perturbation amplitude is dynamically adjusted according to the parameter domain to adapt to parameter optimization needs of different magnitudes, always maintaining the historically optimal parameter combination. The Gaussian perturbation exploration and reinitialization exploration strategies are expressed as follows:
[0085] ;
[0086] ;
[0087] ;
[0088] in, This indicates the Gaussian noise added to the current parameter value. The disturbance of each parameter, It follows a Gaussian distribution. and Indicates the first The maximum and minimum values of each parameter. This represents the new parameter value after the perturbation. Indicates the original parameter value. This represents the amount of disturbance.
[0089] Optionally, the total loss function is a weighted fusion of contrastive loss and peak-sensitive loss, and its mathematical expression is:
[0090] ;
[0091] in, To compare the loss weight coefficients, the improved snow ablation optimization algorithm (ISAO) is dynamically optimized within the interval.
[0092] Optionally, the contrastive loss function ( The specific calculation methods include:
[0093] ;
[0094] in, To compare the values of the loss function, For batch size, Indicates the first The first feature and the first The similarity of features is calculated as the dot product of two feature vectors. The value is 0.1 for the temperature coefficient in the model.
[0095] Optionally, the peak-sensitive loss function ( The specific components include:
[0096] Mean squared error loss ( ): This is used as the basic loss term to ensure the overall fitting accuracy, and is expressed as:
[0097] ;
[0098] Mean absolute error in peak region ( A stronger penalty weight is applied to stress peak samples that exceed the threshold θ=0.8, calculated as follows:
[0099] ;
[0100] Gradient consistency loss ( The dynamic trend of the predicted curve and the actual stress distribution is reduced by using first-order difference constraints, thus reducing phase error. The calculation formula is as follows:
[0101] ;
[0102] The complete expression for the peak-sensitive loss function is:
[0103] ;
[0104] Optionally, the collaborative optimization mechanism of the loss function includes:
[0105] Multi-objective balance: By weighted fusion of contrast loss and peak-sensitive loss, the model's generalization ability and key feature capture ability are balanced;
[0106] Gradient clipping: Set the gradient clipping threshold to 1.0 to prevent gradient explosion;
[0107] Dynamic weight adjustment: The ISAO algorithm adaptively optimizes based on validation set performance. and This achieves a balance among the loss items.
[0108] Optionally, the deep learning model is systematically trained using the actual stress distribution value at the composite defect in the pipeline as the target output to obtain an optimized MCL-Net model; simultaneously, a stress distribution inversion accuracy evaluation standard and an abnormal signal identification mechanism are established.
[0109] The specific implementation process includes:
[0110] S41. Data Preparation and Input Configuration: The preprocessed dual-channel time-series data (shape [B, 3, 2]) is used as the model input, where B is the batch size, 3 represents the time step, and 2 represents the dual-channel features (weak excitation composite signal MFL_sub and decoupled magnetic signal MFL_ds). The output target is the true stress distribution value obtained through finite element simulation or experimental measurement, which is normalized and mapped to the [-1, 1] interval.
[0111] S42. Model training and optimization: An improved snow ablation optimization algorithm (ISAO) is used to dynamically adjust the hyperparameter combination.
[0112] Learning rate: Optimize within the range [0.001, 0.01];
[0113] Batch size: Select within the range [16, 128];
[0114] Hidden layer dimension: Automatically adjusted to a multiple of 4 (range 64-512);
[0115] Compare the loss weight λ_CL: optimize within the [0.1, 1.0] interval;
[0116] Peak sensitivity coefficient α: adjusted in the range of [3.0, 8.0];
[0117] During training, an early stopping mechanism (termination if the loss on the validation set does not improve after 3 consecutive rounds) and gradient pruning (threshold 1.0) are used to ensure training stability.
[0118] S43. Accuracy evaluation criteria are established. The stress inversion results must simultaneously meet the following accuracy thresholds (i.e., the aforementioned criteria for determining optimal performance. The criteria for determining optimal performance is a quantitative system based on a comprehensive evaluation of multiple indicators, which aims to ensure that the trained MCL-Net stress inversion model reaches the preset strict thresholds in terms of generalization ability, prediction accuracy, and engineering applicability):
[0119] Coefficient of determination R 2 ≥ 0.90;
[0120] Root mean square error (RMSE) ≤ 0.15;
[0121] Mean absolute error (MAE) ≤ 0.10;
[0122] The relative error in the peak region is ≤ 10%;
[0123] S44. Abnormal signal identification mechanism: The following situations are identified as abnormal signals:
[0124] The peak characteristics of the output signal do not conform to the typical stress concentration pattern (single-peak anomaly, waveform distortion, etc.).
[0125] If any one of the three evaluation indicators fails to meet the threshold (e.g., R), it will be considered as a failure. 2 < 0.90 or peak error > 10%)
[0126] The predicted curve shows a significant phase deviation from the actual stress distribution.
[0127] Optionally, such as Figure 3 As shown, the specific hierarchical structure of the MCL-Net model includes a pooling layer, a projection layer, a weight generator, and a final output layer. These layers together constitute an end-to-end mapping system from the original magnetic signal to the stress distribution value.
[0128] The pooling layer compresses the features from [B, 3, 256] to [B, 512] through temporal pooling operations (mean pooling + max pooling), achieving feature aggregation and dimensionality reduction.
[0129] The projection layer further compresses the feature dimension through a fully connected layer (512→64) for comparative learning of spatial projection.
[0130] The weight generator uses a two-level fully connected network (512→8→2) to dynamically calculate the multi-scale feature fusion weights.
[0131] The final output layer uses a fully connected layer (512→1) to regress and predict the stress distribution value, completing the end-to-end mapping from the original magnetic signal to the stress value.
[0132] Optionally, constructing the dual-mode excitation signal training dataset specifically includes:
[0133] Acquire historically collected dual-mode magnetic signal data of the pipeline;
[0134] The signals containing stress-deformation integrated information and geometric deformation reference data are extracted from the historical pipeline magnetic signal data to obtain several initial pipeline magnetic signal data.
[0135] Optionally, in terms of fitness evaluation, the original single objective function evaluation is replaced by introducing Model Validation Equation (MSE) as the fitness criterion. The improved fitness evaluation method is expressed as follows:
[0136] ;
[0137] ;
[0138] in, Representing the The true value of each sample The prediction function representing the model. Representing the Input features of each sample Represents model parameters, This represents the number of samples in the validation set. Representing the The predicted value for each sample.
[0139] For example, if the actual peak stress at a pipe defect is 210 MPa, and the acquired dual-mode magnetic signal is input into a trained MCL-Net model, the predicted stress value is 198 MPa. Calculations show that this prediction result... , The peak relative error is 5.7%, which meets all accuracy threshold conditions; therefore, the inversion result is considered valid. If any one of the three indicators fails to meet the standard, such as... If the peak error is greater than 10%, the anomaly detection mechanism will be activated. After eliminating sensor malfunctions or environmental interference factors, data acquisition and inversion calculation will be performed again.
[0140] According to specific embodiments provided by the present invention, the present invention discloses the following technical effects:
[0141] This invention uses a composite signal (containing superimposed information of defect leakage magnetic flux and stress magnetic anisotropy) and a decoupled magnetic signal obtained by weak excitation detection as dual-channel time-series inputs. It preserves the hysteresis characteristics of ferromagnetic materials through strict time-series segmentation and eliminates sensor range differences through independent normalization. At the model optimization level, an improved snow ablation optimization algorithm is introduced. This algorithm integrates the global search capability of particle swarm optimization with the adaptive perturbation mechanism of simulated annealing. By establishing a dynamic coupling relationship between the temperature decay coefficient and the particle diversity index, it achieves intelligent exploration of the hyperparameter space. In the data construction stage, a sliding window with a 3-time-step length is used to generate sequence samples, and Gaussian noise is injected simultaneously to simulate probe fluctuations and electromagnetic interference, enhancing model robustness. The multi-scale CNN module fuses feature channels using a 1×1 convolutional kernel, captures short-term fluctuations and abrupt changes in the time series using a 1×3 convolutional kernel, and extracts long-term trend characteristics of the time series using a 1×5 convolutional kernel. Combined with a channel attention mechanism, it adaptively fuses stress-sensitive components and defect perturbation components. The ISAO algorithm effectively balances parameter exploration and development by searching a four-dimensional parameter space (learning rate, hidden layer dimension, contrastive loss weights, and peak sensitivity coefficient) and employing a temperature-sensitive particle swarm optimization update strategy. Spatiotemporal features are captured using a bidirectional LSTM to capture the hysteresis characteristics of the magnetoelastic effect, and multi-head attention is used to focus on key time windows in the material's yielding stage. Finally, the temporal mean and peak features are fused to reconstruct the stress field.
[0142] This invention uses the weak magnetic composite signal and decoupled magnetic signal acquired by the dual-modal excitation collaborative detection system as input to the MCL-Net model, directly constructing the feature space using the original magnetic field time-series data. This method avoids the complex process of converting the magnetic field signal into an image and then extracting features in traditional methods. It not only completely preserves the original physical characteristics of the magnetic-force coupling effect, but also significantly reduces the computational complexity of data preprocessing, achieving efficient and lossless input of defect stress features.
[0143] This invention constructs a multiphysics coupled dataset based on finite element simulation and experimental data, and designs a dynamic data augmentation strategy that integrates the Improved Snow Melting Optimization Algorithm (ISAO). This strategy injects Gaussian noise during training to simulate probe lifting of fluctuations and electromagnetic interference, and uses the ISAO algorithm to adaptively adjust augmentation parameters, effectively expanding the sample diversity under defect-stress coupling conditions and significantly improving the model's generalization ability under real-world complex conditions.
[0144] This invention innovatively employs a cascaded architecture of multi-scale convolutional modules and bidirectional LSTM in the generator branch (i.e., Figure 4The multi-scale CNN module and BiLSTM-attention module extract channel interaction features, local detail features, and long-range trend features through parallel 1×1, 1×3, and 1×5 convolutional kernels, respectively, and combine them with a bidirectional long short-term memory network to capture the temporal dependencies of the hysteresis loop. Furthermore, a dual constraint of contrastive loss and peak-sensitive loss (i.e., similarity loss and gradient consistency loss in the generation loss) is introduced into the loss function to ensure that the generated samples maintain a high degree of consistency with the real data in terms of feature distribution and the shape of key stress response peaks.
[0145] The stress distribution at the target pipeline defect is inverted using the stress distribution prediction branch based on the MCL-Net model. For any target pipeline defect, the inversion result is considered valid if the obtained stress distribution value meets the set stress inversion accuracy evaluation criteria. Multi-scale feature fusion is achieved through adaptive weighting using a channel attention mechanism.
[0146] In engineering experimental data testing, the prediction accuracy is high. This method successfully solves the technical problems of insufficient stress inversion accuracy, severe signal coupling interference, and complex operation of traditional methods, and provides a new theoretical basis and effective technical support for the accurate safety assessment of pipeline composite defects. Attached Figure Description
[0147] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0148] Figure 1 This is a schematic diagram of the magnetic signal decoupling process for a method for inverting stress distribution in pipeline composite defects provided by the present invention.
[0149] Figure 2 This is a schematic diagram illustrating the scaling of the coupling signal acquisition in the method provided by the present invention.
[0150] Figure 3 This is a schematic diagram of the MCL-Net stress inversion model in the method provided in the embodiments of the present invention.
[0151] Figure 4 The ISAO 10-dimensional search trajectory and convergence curve are shown in the method provided in the embodiments of the present invention.
[0152] Figure 5 The ISAO 20-dimensional search trajectory and convergence curve are shown in the method provided in the embodiments of the present invention.
[0153] Figure 6The image shows magnetic signal data of composite defects under different stresses and different external magnetic fields in the method provided in the embodiments of the present invention.
[0154] Figure 7 The diagram shows the stress inversion results of the MCL-Net model of this invention.
[0155] Figure 8 This is a flowchart of the present invention. Detailed Implementation
[0156] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0157] The purpose of this invention is to provide a method for inverting the stress distribution of composite defects in pipelines. By deeply integrating dual-modal excitation signal decoupling with deep learning technology, a precise quantitative assessment of the stress distribution of composite crack-stress defects in pipelines is achieved. This method innovatively solves the technical bottlenecks of traditional non-destructive testing techniques in stress inversion, such as theoretical model dependence assumptions, signal coupling interference, and lack of sample data, providing a reliable means of assessing the mechanical state of oil and gas pipelines for integrity management.
[0158] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0159] Example:
[0160] The embodiment provides a method for inverting the stress distribution of composite defects in pipelines, such as Figure 1 The flowchart shown illustrates the inversion method for stress distribution in pipeline composite defects, which includes the following steps:
[0161] S1. Construct a dual-mode magnetic signal training dataset. Specifically, in this embodiment, a WAW-2000 microcomputer-controlled electro-hydraulic servo universal tensile testing machine is used to apply tensile loads ranging from 0-80 MPa, simultaneously acquiring dual-mode magnetic signals under different excitation currents (0-8 A). Each training sample contains a weak excitation composite signal (MFLsub) and a strong excitation reference signal (MFLsat), forming a data matrix of size (sequence length 3 × feature number 2). Figure 2 The schematic diagram of the magnetic signal decoupling process shown illustrates the complete processing flow from the original signal to the stress component.
[0162] S2. Establish the MCL-Net stress inversion model. In this embodiment, the MCL-Net model includes a multi-scale feature extraction module, a time series modeling module, and an optimization algorithm module.
[0163] like Figure 3 The MCL-Net model framework shown in this embodiment employs a parallel convolutional structure for its multi-scale feature extraction module:
[0164] 1×1 convolution kernel: responsible for feature channel fusion and dimension adjustment, with 256 output channels;
[0165] 1×3 convolution kernel: Extracts local detail features and captures subtle changes in the axial weak excitation signal;
[0166] 1×5 convolution kernel: captures long-range dependencies and learns the global distribution pattern of the stress field;
[0167] The weighting formulas for features at each scale are as follows:
[0168] ;
[0169] ;
[0170] in, Indicates the first The average feature of each branch feature Indicates the length of the time series. Indicates the first Each branch in time Features This represents the learnable weight matrix.
[0171] The adaptive fusion formula dynamically adjusts the weights of features at each scale using a channel attention mechanism:
[0172] ;
[0173] in, This represents the fused feature map. These are the channel attention weights for the convolutional branches.
[0174] Optionally, the temporal modeling and attention enhancement module specifically includes: a bidirectional LSTM network inputting the fused feature sequence, which is configured with 128 hidden units and a 2-layer bidirectional structure to capture the nonlinear temporal characteristics of the hysteresis loop through the interaction of contextual information;
[0175] The spatiotemporal features are then incorporated into a multi-head attention mechanism, employing four attention heads to learn the temporal correlation patterns of different subspaces in parallel. The calculation formula is as follows:
[0176] ;
[0177] ;
[0178] ;
[0179] in, For each dimension of attention head, For the number of attention heads, This is the output feature matrix of the multi-head attention mechanism. This is a multi-head attention mechanism.
[0180] like Figure 3 The diagram shows the network parameter configuration of the MCL-Net model. In this embodiment, the model adopts a hierarchical architecture design to form an end-to-end stress distribution inversion process.
[0181] The input layer receives time-series data of shape [B, 3, 2], where B is the batch size, 3 represents the time step, and 2 represents the dual-channel magnetic signal (weak excitation composite signal and decoupled magnetic signal). The data is first transformed into [B, 2, 3] through dimension permutation before entering the multi-scale CNN module.
[0182] The multi-scale CNN module employs three parallel enhanced causal convolutional branches:
[0183] 1×1 convolutional kernel branch: input channels = 2, output channels = 256, responsible for feature channel fusion and dimension adjustment;
[0184] 1×3 convolutional kernel branch: input channels=2, output channels=256, specifically used to capture local detail features;
[0185] 1×5 convolutional kernel branch: input channels = 2, output channels = 256, focusing on capturing long-range dependencies.
[0186] Each convolutional branch maintains a constant temporal length, and spatial features at different scales are extracted through parallel computation.
[0187] After feature extraction, the data are fed into a bidirectional long short-term memory (BiLSTM) network with 128 hidden units and a two-layer bidirectional structure, which effectively learns the temporal dynamic characteristics of the hysteresis loop.
[0188] The attention mechanism layer adopts a multi-head attention architecture with 256 embedded dimensions and 4 attention heads. The time-first to batch-first conversion is achieved through the dimension permutation operation [3, B, 256]→[B, 3, 256], enabling the model to adaptively focus on stress-sensitive time windows.
[0189] The pooling layer compresses the features from [B, 3, 256] to [B, 512] through temporal pooling operations (mean pooling + max pooling), achieving feature aggregation and dimensionality reduction.
[0190] The projection layer further compresses the feature dimension through a fully connected layer (512→64) for comparative learning of spatial projection.
[0191] The weight generator uses a two-level fully connected network (512→8→2) to dynamically calculate the multi-scale feature fusion weights.
[0192] The final output layer uses a fully connected layer (512→1) to regress and predict the stress distribution value, completing the end-to-end mapping from the original magnetic signal to the stress value.
[0193] The pooling layer corresponds to "reconstructing the stress field by fusing temporal mean and peak features" and "adaptively fusing stress-sensitive components and defect perturbation components through channel attention mechanism".
[0194] The projection layer corresponds to "introducing the dual constraints of contrast loss and peak-sensitive loss into the loss function" and "calculating the similarity between the projection vectors of the enhanced sample and the original sample".
[0195] The weight generator corresponds to "adaptive weighted fusion of multi-scale features through channel attention mechanism" and "adaptive fusion of stress-sensitive components and defect perturbation components by combining channel attention mechanism".
[0196] The final output layer corresponds to the core objectives of "achieving automated and high-precision inversion of the stress distribution of pipeline defects" and "finally fusing time-series mean and peak characteristics to reconstruct the stress field".
[0197] The entire network achieves accurate inversion of the stress distribution of composite defects in pipelines through the synergistic effect of multi-scale feature extraction, temporal modeling, attention mechanism and adaptive fusion.
[0198] In this embodiment, the loss function system includes contrastive loss and peak-sensitive loss.
[0199] The total loss function is a weighted fusion of the contrastive loss and the peak-sensitive loss, and its mathematical expression is:
[0200] ;
[0201] in, To compare the loss weight coefficients, the improved snow ablation optimization algorithm (ISAO) is dynamically optimized within the interval.
[0202] Optionally, the contrastive loss function ( The specific calculation methods include:
[0203] ;
[0204] in, To compare the values of the loss function, For batch size, Indicates the first The first feature and the first The similarity of features is calculated as the dot product of two feature vectors. The value is 0.1 for the temperature coefficient in the model.
[0205] Optionally, the peak-sensitive loss function ( The specific components include:
[0206] Mean squared error loss ( ): This is used as the basic loss term to ensure the overall fitting accuracy, and is expressed as:
[0207] ;
[0208] Mean absolute error in peak region ( A stronger penalty weight is applied to stress peak samples that exceed the threshold θ=0.8, calculated as follows:
[0209] ;
[0210] Gradient consistency loss ( The dynamic trend of the predicted curve and the actual stress distribution is reduced by using first-order difference constraints, thus reducing phase error. The calculation formula is as follows:
[0211] ;
[0212] The complete expression for the peak-sensitive loss function is:
[0213] ;
[0214] Optionally, the collaborative optimization mechanism of the loss function includes:
[0215] Multi-objective balance: By weighted fusion of contrast loss and peak-sensitive loss, the model's generalization ability and key feature capture ability are balanced;
[0216] Gradient clipping: Set the gradient clipping threshold to 1.0 to prevent gradient explosion;
[0217] Dynamic weight adjustment: The ISAO algorithm adaptively optimizes based on validation set performance. and This achieves a balance among the loss items.
[0218] S3. Improved Snow Melting Optimization Algorithm (ISAO): The improved ISAO algorithm is used for parameter optimization. Regarding algorithm iteration control, the original fixed number of iterations is replaced with a dynamic annealing mechanism and a maximum iteration count expansion, dynamically balancing the intensity of global exploration and local exploitation. In terms of exploration strategy, the original random exploration is replaced with a mixture of Gaussian perturbation exploration (local) and re-initialization exploration (global), combining Gaussian perturbation (local fine-tuning) and random re-initialization (global exit) to cover a more comprehensive solution space. For fitness evaluation, the original single objective function evaluation is replaced with the introduction of Model Validation Estimate (MSE) as the fitness criterion. Eleven similar optimization algorithms were selected for comparison, and multiple repeated tests were conducted. The test results are as follows: Figure 4 , 5 As shown, the ISAO algorithm has a faster convergence speed and better stability, and it has better performance advantages in higher-dimensional problems, enabling it to find the optimal solution more efficiently.
[0219] S4. Using the dual-mode magnetic signal training dataset as the input to the MCL-Net stress inversion model and the actual stress distribution value at the pipeline composite defect as the target output, the deep learning model is systematically trained to obtain the optimized MCL-Net model; simultaneously, a stress distribution inversion accuracy evaluation standard and an abnormal signal identification mechanism are established.
[0220] The specific implementation process includes:
[0221] S41. Data Preparation and Input Configuration: The preprocessed dual-channel time-series data (shape [B, 3, 2]) is used as the model input, where B is the batch size, 3 represents the time step, and 2 represents the dual-channel features (weak excitation composite signal MFL_sub and decoupled magnetic signal MFL_ds). The output target is the true stress distribution value obtained through finite element simulation or experimental measurement, which is normalized and mapped to the [-1, 1] interval.
[0222] S42. Model training and optimization: An improved snow ablation optimization algorithm (ISAO) is used to dynamically adjust the hyperparameter combination.
[0223] Learning rate: Optimize within the range [0.001, 0.01];
[0224] Batch size: Select within the range [16, 128];
[0225] Hidden layer dimension: Automatically adjusted to a multiple of 4 (range 64-512);
[0226] Compare the loss weight λ_CL: optimize within the [0.1, 1.0] interval;
[0227] Peak sensitivity coefficient α: adjusted in the range of [3.0, 8.0];
[0228] During training, an early stopping mechanism (termination if the loss on the validation set does not improve after 3 consecutive rounds) and gradient pruning (threshold 1.0) are used to ensure training stability.
[0229] S43. Accuracy evaluation criteria are established, and the stress inversion results must simultaneously meet the following accuracy thresholds:
[0230] Coefficient of determination R 2 ≥ 0.90;
[0231] Root mean square error (RMSE) ≤ 0.15;
[0232] Mean absolute error (MAE) ≤ 0.10;
[0233] The relative error in the peak region is ≤ 10%;
[0234] S44. Abnormal signal identification mechanism: The following situations are identified as abnormal signals:
[0235] The peak characteristics of the output signal do not conform to the typical stress concentration pattern (single-peak anomaly, waveform distortion, etc.).
[0236] If any one of the three evaluation indicators fails to meet the threshold (e.g., R), it will be considered as a failure. 2 < 0.90 or peak error > 10%)
[0237] The predicted curve shows a significant phase deviation from the actual stress distribution;
[0238] The example dataset consists of three steel bar specimens with different defect sizes (1 mm wide 1 mm deep, 1 mm wide 2 mm deep, and 2 mm wide 1 mm deep) detected by a dual magnetic field detector. Tensile forces of 0-72 kN were applied to the steel bars, corresponding to pressures of 0-80 MPa. As the excitation current increased from 0 A to 8 A, the corresponding external magnetic field strength ranged from 0-31.2 kA / m. The magnetic signal characteristics of the composite defects in the steel bars were measured under different external magnetic field strengths, and the resulting strong and weak magnetic data are shown below. Figure 6 As shown.
[0239] Results analysis:
[0240] Table 1. Comparison of metrics for different models on the same dataset
[0241] ;
[0242] As can be seen from Table 1, after using the MCL-Net model of this invention combined with the ISAO optimization algorithm to invert the stress distribution of composite defects in pipelines, the prediction accuracy of stress distribution and model performance are significantly improved.
[0243] Specific examples are used in this invention, but the above description is only to illustrate the principles and implementation methods of this invention. The description of the above embodiments is only for the purpose of helping to understand the method and core ideas of this invention. Those skilled in the art should understand that the various modules or steps of this invention described above can be implemented using general-purpose computer devices. Optionally, they can be implemented using computer-executable program code, thereby storing them in a storage device for execution by a computer device, or fabricating them separately as individual integrated circuit modules, or fabricating multiple modules or steps into a single integrated circuit module. This invention is not limited to any specific combination of hardware and software.
[0244] Furthermore, those skilled in the art will recognize that, based on the principles of this invention, there will be variations in the specific implementation methods and application scope. Therefore, the content of this specification should not be construed as limiting the invention.
Claims
1. A method for inverting stress distribution in pipeline composite defects, characterized in that, Includes the following steps: Step 1: Obtain the dual-mode magnetic signal data of the target pipeline to be detected, and construct a dual-mode excitation signal training dataset; Step 2: Construct a stress inversion model based on the MCL-Net architecture; A deep learning model for stress inversion is constructed based on a multi-scale convolutional neural network-long short-term memory network and a bidirectional LSTM-multi-head attention module; the stress inversion model is systematically trained using the dual-modal excitation signal training dataset as input to obtain a trained MCL-Net stress inversion model. Step 3: Construct an improved optimization algorithm training framework; A model hyperparameter optimization system is built based on the improved snow ablation optimization algorithm ISAO. Through a dynamic temperature decay module and a mixed Gaussian perturbation strategy, the key parameters in the MCL-Net model are intelligently optimized to improve the model's convergence speed and generalization ability. Step 4: Establish a multi-objective loss function evaluation system; The MCL-Net stress inversion model includes a multi-scale CNN feature extraction module, a bidirectional LSTM temporal modeling module, a multi-head attention module, and a loss function optimization. The multi-scale feature extraction module of the MCL-Net model specifically includes: The preprocessed dual-channel temporal signal is input into a parallel multi-scale convolutional structure, where: A 1×1 convolutional kernel is responsible for feature channel fusion and dimension adjustment, with an output channel count of 256. The 1×3 convolution kernel focuses on extracting local detailed features and high-frequency components of the axial weak excitation signal; A 1×5 convolution kernel is used to capture the long-range trend and overall distribution pattern of the signal; The weighting formulas for features at each scale are as follows: ; ; in, Indicates the first The average feature of each branch feature Indicates the length of the time series. Indicates the first Each branch in time Features Represents the learnable weight matrix; The weights of features at each scale are dynamically adjusted using the channel attention module, and the adaptive fusion formula is as follows: ; in, This represents the fused feature map. These are the channel attention weights for the convolutional branches; The bidirectional LSTM-multi-head attention module specifically includes: a bidirectional LSTM network inputting the fused feature sequence, which is configured with 128 hidden units and a 2-layer bidirectional structure to capture the nonlinear temporal characteristics of the hysteresis loop through the interaction of contextual information. The spatiotemporal features are then fed into a multi-head attention module, which uses four attention heads to learn the temporal correlation patterns of different subspaces in parallel. The calculation formula is as follows: ; ; ; in, For each dimension of attention head, For the number of attention heads, This is the output feature matrix of the multi-head attention module. For multi-head attention modules; H represents magnetic field strength; The workflow for loss function optimization is as follows: Step 1: Dual-modal signal input and data augmentation; The preprocessed dual-channel time-series signal is input into the MCL-Net model. Gaussian noise is injected to simulate the probe's ability to lift out fluctuations and electromagnetic interference, thereby enhancing the model's robustness. The input data dimensions are batch size, sequence length 3, and feature number 2. Step 2: Multi-scale feature extraction and contrastive learning; features are extracted through a parallel multi-scale convolution module, and the similarity between the projection vectors of the enhanced sample and the original sample is calculated; Step 3: Peak-sensitive loss calculation; calculate the peak-sensitive loss based on the characteristics of the stress concentration region; Step 4: Multi-target loss fusion and backpropagation; The contrastive loss and peak-sensitive loss are fused according to their weights to obtain the total loss function; Step 5: Dynamic optimization and early stopping module; After each round of training, the validation set MSE of the ISAO algorithm is evaluated, and dynamic temperature decay balance is explored and developed; When the validation set MSE does not decrease for 3 consecutive rounds, early stopping is triggered to save the best historical model; Repeat steps 1-5 multiple times until the model achieves optimal performance on the validation set; finally, output the optimized MCL-Net model parameters and ISAO hyperparameter combination.
2. The method for inverting stress distribution of composite defects in pipelines according to claim 1, characterized in that... In step 1, the training dataset includes pipeline magnetic signal data collected under two magnetization levels: high and low. Each complete training sample consists of a composite signal detected by weak excitation and a magnetic signal decoupled based on scaling theory. The dual-channel time-series signal retains the hysteresis characteristics of the ferromagnetic material through strict time-series segmentation, thus forming complete pipeline composite defect stress inversion training data. The composite signal contains information on the superposition of defect leakage magnetic flux and stress magnetic anisotropy. In step 3, the key parameters include the learning rate, hidden layer dimension, contrastive loss weights, and peak sensitivity coefficient. In step 4, a multi-objective loss function evaluation system is constructed based on the contrast learning module and the peak sensitivity characteristics, with mean square error (MSE), determination coefficient (R 2 , root mean square error (RMSE), mean absolute error (MAE), and mean absolute percentage error (MAPE) as model performance evaluation indicators to establish a complete stress inversion quality evaluation standard.
3. The method for inverting stress distribution in pipeline composite defects according to claim 1, characterized in that... The accuracy evaluation system for stress inversion includes parameter optimization based on the ISAO algorithm, multi-index performance evaluation, and engineering verification. The improved snow ablation optimization algorithm ISAO searches the four-dimensional parameter space and adopts a particle swarm temperature-sensitive update strategy to establish a dynamic coupling relationship between the temperature decay coefficient and the particle diversity index, thereby achieving intelligent exploration of the hyperparameter space. The four-dimensional parameter space search includes: learning rate, hidden layer dimension, contrastive loss weight, and peak sensitivity coefficient; The multi-objective loss function evaluation system includes a contrastive loss function and a peak-sensitive loss function. The contrastive loss function enhances the feature decoupling ability by calculating the cosine similarity matrix of all feature pairs, while the peak-sensitive loss function applies a stronger L1 loss weight to peak samples that exceed the threshold and prioritizes fitting key stress concentration regions. The process of acquiring dual-mode magnetic signal data of the target pipeline to be detected, using magnetic signal decoupling technology to obtain the input of the MCL-Net model, and using the trained MCL-Net model, combined with the stress distribution inversion and accuracy evaluation criteria, to invert the stress distribution at the composite defect of the target pipeline, specifically includes: Acquire dual-mode magnetic signal data of the target pipeline to be inspected; A decoupled magnetic signal is obtained using strong magnetic signal decoupling technology, and is used together with the acquired original weak magnetic data as input to the MCL-Net model. By selecting low and high dual-mode excitation conditions, stress-deformation integrated information and geometric deformation reference data of composite defects are obtained respectively. The magnetic signal decoupling process employs dual magnetization state comparison and signal layering processing techniques; the specific process includes: (1) Obtain pure component signals containing only geometric features under high magnetization levels, and generate calibration signals after normalization; (2) Acquire composite signals coupled with geometric and magnetoelastic effects at low magnetization levels; (3) Map the calibration signal to a low magnetization level to form a reconstructed signal; (4) By decoupling the geometric components, the magnetostrictive distortion signal reflecting the stress distribution is finally extracted; The decoupled magnetic signal construction method is based on the principle of dual-modal data fusion, and its mathematical representation is shown in the following equation: ; In the formula, It is the scaling factor of the magnetic signal during the decoupling process. It is the magnetic field strength at high magnetization. It is the magnetic field strength at low magnetization; ; In the formula, It is a decoupling signal. It is a magnetic signal detected under a weak excitation magnetic field. It is a magnetic signal detected under a strong excitation magnetic field.
4. The method for inverting stress distribution of composite defects in pipelines according to claim 2, characterized in that... The scaling theory reveals the separation modules of magnetic-force coupled signals through two-dimensional feature mapping; Constructing a dual-modal magnetic signal training dataset, specifically including: Acquire historical dual-mode magnetic signal data of pipelines: High and low magnetization level signals under different stress conditions and excitation currents are collected through the experimental platform; Extracting the magnetic signal matrix of composite defects: The time window is truncated with the defect as the center. Each sample contains the weak excitation composite signal MFLsub and the strong excitation reference signal MFLsat, forming a data matrix. Construct a standardized training set: Divide the data matrix into training, validation, and test sets, and perform independent normalization.
5. The method for inverting stress distribution in pipeline composite defects according to claim 1, characterized in that... The training dataset for the stress inversion model based on MCL-Net is constructed. Specifically, the decoupled magnetic signal MFLds and the original weak magnetic signal MFLsub are concatenated along the channel dimension to form dual-channel input data. The output label is the real stress distribution value obtained by finite element simulation or experimental measurement, normalized to the interval [-1,1].
6. The method for inverting stress distribution of composite defects in pipelines according to claim 1, characterized in that... The loss function includes a gradient consistency constraint term, which calculates the gradient difference between the predicted curve and the actual stress distribution through first-order difference to reduce phase error; at the same time, Dropout and weight decay regularization techniques are used to prevent overfitting. The ISAO algorithm explores global parameters with a 68% probability during the high-temperature stage and finely adjusts the loss weight with a 22% probability during the low-temperature stage, achieving intelligent hyperparameter optimization through four-dimensional parameter space search. The hyperparameter optimization process of the improved snow ablation optimization algorithm ISAO specifically includes: Establish a four-dimensional parameter search space: learning rate [0.001, 0.01], batch size [16, 128], hidden layer dimension [64, 512], contrastive loss weight [0.1, 1.0], peak sensitivity coefficient [3.0, 8.0]; The iterative control module of the improved snow ablation optimization algorithm ISAO specifically includes: In terms of algorithm iteration control, the original fixed number of iterations is replaced by a combination of a dynamic annealing module and a maximum iteration count extension. An exponentially decaying temperature parameter is used to dynamically balance the intensity of global exploration and local exploitation. The temperature update and melting probability in the dynamic annealing module are expressed as: ; ; ; in, For the next temperature value, The temperature decay coefficient is The value is 1000. Indicates the first Normalized scores of each sample Indicates the first The original scores of each sample It is a local minimum; Indicates the first The melting probability of a sample. This indicates the current temperature.
7. The method for inverting stress distribution in pipeline composite defects according to claim 1, characterized in that... The hybrid Gaussian perturbation strategy specifically includes: In terms of exploration strategies, Gaussian perturbation and random reinitialization cover a more comprehensive solution space; the perturbation amplitude is dynamically adjusted according to the parameter domain to adapt to parameter optimization needs of different magnitudes, always maintaining the historically optimal parameter combination; the Gaussian perturbation exploration and reinitialization exploration strategies are expressed as follows: ; ; ; in, This indicates the Gaussian noise added to the current parameter value. The disturbance of each parameter, It follows a Gaussian distribution. and Indicates the first The maximum and minimum values of each parameter; This represents the new parameter value after the perturbation. This represents the original parameter value. This represents the amount of disturbance.
8. The method for inverting stress distribution of composite defects in pipelines according to claim 1, characterized in that... The total loss function is a weighted fusion of the contrastive loss and the peak-sensitive loss, and its mathematical expression is: ; in, To compare the loss weight coefficients, the improved snow ablation optimization algorithm ISAO was dynamically optimized within the interval. Contrast loss function The specific calculation methods include: ; in, To compare the values of the loss function, For batch size, Indicates the first The first feature and the first The similarity of features is calculated as the dot product of two feature vectors; This is the temperature coefficient, and its value in the model is taken as 0.
1. The peak-sensitive loss function The specific components include: Mean square error loss As a basic loss term, it ensures the overall fitting accuracy and is expressed as: ; This represents the true value of the i-th sample. The predicted value represents the i-th sample; the mean absolute error of the peak region. A stronger penalty weight is applied to stress peak samples that exceed the threshold θ=0.8, calculated as follows: ; Gradient consistency loss The dynamic trend of the predicted curve and the actual stress distribution is reduced by using first-order difference constraints, thus reducing phase error. The calculation formula is as follows: ; The complete expression for the peak-sensitive loss function is: ; Peak sensitivity coefficient; The collaborative optimization of the loss function includes: Multi-objective balance: By weighted fusion of contrast loss and peak-sensitive loss, the model's generalization ability and key feature capture ability are balanced; Gradient clipping: Set the gradient clipping threshold to 1.0 to prevent gradient explosion; Dynamic weight adjustment: The ISAO algorithm adaptively optimizes based on validation set performance. and This achieves a balance among the loss items.
9. The method for inverting stress distribution in pipeline composite defects according to claim 1, characterized in that... The deep learning model is systematically trained using the actual stress distribution value at the composite defect of the pipeline as the target output, and the optimized MCL-Net model is obtained. Simultaneously establish a standard for evaluating the accuracy of stress distribution inversion and an abnormal signal identification module; The specific implementation process includes: S41. Data preparation and input configuration: The preprocessed dual-channel time series data with shape [B, 3, 2] is used as the model input, where B is the batch size, 3 represents the time step, and 2 represents the dual-channel features, namely the weak excitation composite signal MFL_sub and the decoupled magnetic signal MFL_ds; the output target is the real stress distribution value obtained through finite element simulation or experimental measurement, which is normalized and mapped to the [-1,1] interval. S42. Model training and optimization: The improved snow ablation optimization algorithm ISAO is used to dynamically adjust the hyperparameter combination. Learning rate: Optimize within the range [0.001, 0.01]; Batch size: Select within the range [16, 128]; Hidden layer dimensions: automatically adjusted to multiples of 4, ranging from 64 to 512; Compare the loss weight λ_CL: optimize within the [0.1, 1.0] interval; Peak sensitivity coefficient α: adjusted in the range of [3.0, 8.0]; The training process employs an early stopping module, terminating the training if the loss on the validation set fails to improve after three consecutive rounds, and performing gradient pruning with a threshold of 1.0 to ensure training stability. S43. Accuracy evaluation criteria are established, and the stress inversion results must simultaneously meet the following accuracy thresholds: Coefficient of determination R 2 ≥ 0.90; Root mean square error (RMSE) ≤ 0.15; Mean absolute error (MAE) ≤ 0.10; The relative error in the peak region is ≤ 10%; S44. Abnormal signal identification module, which determines an abnormal signal when the following conditions occur: The peak characteristics of the output signal do not conform to the typical stress concentration mode; If any one of the three evaluation indicators fails to meet the threshold; The predicted curve shows a significant phase deviation from the actual stress distribution; The specific hierarchical structure of the MCL-Net model includes a pooling layer, a projection layer, a weight generator, and a final output layer. These layers together constitute an end-to-end mapping system from the original magnetic signal to the stress distribution value. The pooling layer compresses the features from [B, 3, 256] to [B, 512] through temporal pooling operations, achieving feature aggregation and dimensionality reduction; The projection layer further compresses the feature dimension through a fully connected layer, which is used to compare and learn spatial projection; The weight generator uses a two-level fully connected network to dynamically calculate multi-scale feature fusion weights; The final output layer uses a fully connected layer to regress and predict stress distribution values, completing the end-to-end mapping from the original magnetic signal to stress values.
Citation Information
Patent Citations
Pipe jacking construction digital twinning optimization system and method based on high-precision physical simulation
CN120470781A
Intelligent analysis system for magnetic flux leakage detection data in pipeline
WO2020133639A1