Marine corrosion real-time monitoring method and system, terminal and storage medium
Through the kernel function and attention mechanism mapping data to high-dimensional space, combined with the weighted fusion of the LSTM model, the problem that the existing technology cannot monitor marine corrosion in real time is solved, and multi-dimensional accurate prediction of marine corrosion state is achieved, which improves monitoring Accuracy and reliability support the adoption of targeted maintenance measures.
Patent Information
- Application Number
- CN202411707606.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-27
- Publication Date
- 2024-12-27
- Estimated Expiration
- 2044-11-27
AI Technical Summary
Existing marine corrosion detection technologies cannot monitor the initial changes in corrosion in real time, and it is difficult to effectively process complex, nonlinear, and multi-dimensional time series data, affecting the timeliness of maintenance decisions.
The real-time monitoring method of marine corrosion based on nuclear function and attention mechanism is adopted, and electrochemical, environmental and physical state data is obtained through sensing devices, mapped to high-dimensional space, and the LSTM model is used to combine enhanced features and local time series features for weighted fusion. Predict corrosion rate, depth, and risk scores.
It realizes multi-dimensional accurate prediction of marine corrosion state, improves monitoring accuracy and reliability, timely grasps the corrosion conditions of marine structures, provides a basis for taking targeted maintenance measures, and improves the safety and service life of marine structures.
Smart Images

Figure CN119198525A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of marine corrosion monitoring, and in particular relates to a real-time marine corrosion monitoring method, system, terminal and storage medium. Background Art
[0002] Marine corrosion is the corrosion of components in the marine environment. In the marine environment, seawater itself is a strong corrosive medium. At the same time, waves, tides, and currents produce low-frequency reciprocating stress and impact on metal components. In addition, marine microorganisms, attached organisms, and their metabolites directly or indirectly accelerate the corrosion process. Marine corrosion is mainly local corrosion, that is, corrosion that starts from the surface of the component and occurs in a very small area, such as galvanic corrosion, pitting corrosion, crevice corrosion, etc. Marine corrosion has a significant impact on the safety, stability, and service life of marine structures (such as offshore platforms, ships, submarine pipelines, etc.).
[0003] Existing marine corrosion detection technologies mainly rely on electrochemical methods (such as electrochemical impedance spectroscopy, linear polarization resistance) and basic machine learning models (such as linear regression, BP neural network). Although these methods can detect the presence of corrosion, they often have the following problems.
[0004] Traditional corrosion monitoring methods cannot detect the early stages of corrosion; they rely on linear regression and simple neural networks, which are difficult to effectively process complex, nonlinear, and multi-dimensional time series data; and electrochemical methods usually require a long time for data collection and processing, and cannot reflect changes in the corrosion process in real time, affecting the timeliness of maintenance decisions. Summary of the invention
[0005] In view of the above-mentioned deficiencies in the prior art, the present invention provides a marine corrosion real-time monitoring system, terminal and storage medium to solve the above-mentioned technical problems.
[0006] In a first aspect, the present invention provides a method for real-time monitoring of marine corrosion, comprising: S1, based on the sensor equipment deployed on the marine structure to obtain real-time raw data, the raw data includes electrochemical data, environmental data, physical state data and corrosion state data; S2, maps the original data to a high-dimensional space based on the kernel function, and obtains the most relevant enhanced features of the corrosion state in the original data mapped to the high-dimensional space based on the attention mechanism; S3, establish an LSTM model based on the time dependency of the corrosion state. The LSTM model inputs the reinforcement features and outputs the local time series features. S4, weighted fusion of the enhanced features and local time series features is performed to obtain a corrosion state prediction model, which inputs the enhanced features and local time series features and outputs the corrosion rate prediction value, corrosion depth prediction value and corrosion risk score value.
[0007] In an optional implementation, in step S2, mapping the original data to a high-dimensional space based on a kernel function includes: Preprocess the original data to obtain the original data feature matrix; Based on the Gaussian kernel, the original data feature matrix is mapped to a high-dimensional space to obtain a kernel matrix that reflects the similarity between the feature vectors of the original data, which is calculated as:
[0008] in is the original data feature vector of the i-th time step, is the original data feature vector of the jth time step, represents the Euclidean distance between two eigenvectors, is the bandwidth parameter of the kernel function.
[0009] In an optional embodiment, obtaining the most relevant enhanced features of the corrosion state in the original data mapped to the high-dimensional space based on the attention mechanism includes: The attention score of each original data feature vector is calculated based on the kernel matrix, which is calculated as:
[0010] in, is the attention score of the original data feature vector at the i-th time step, is the weight of the similarity between the original data feature vector of the i-th time step and the original data feature vector of the j-th time step, and T is the total length of the time series; The attention score is normalized based on the softmax function to obtain the weight of the original data feature vector, which is calculated as:
[0011] in, is the weight of the i-th original data feature vector; All original data feature vectors are weighted and integrated to obtain the enhanced feature vector, which is calculated as:
[0012] in is the reinforcement feature vector; A reinforced feature matrix is obtained based on the reinforced feature vector.
[0013] In an optional implementation, step S3 specifically includes: S3-1, calculate the forget gate output to control the reinforcement features that need to be retained or forgotten in the memory unit of the previous time step, calculated as:
[0014] in, is the weight matrix of the forget gate, is the hidden state at the previous moment, is the input reinforcement feature of the current time step, is the bias term of the forget gate, S is the sigmoid activation function, is the output of the forget gate at the current time step; S3-2, calculate the input gate output to determine the extent to which the reinforcement feature of the current time step needs to be written into the memory unit, calculated as: ,
[0015] in, is the weight matrix of the input gate, is the bias term of the input gate, is the weight matrix used to generate candidate values, is the corresponding bias term used to generate candidate values, is the new candidate value at the current moment, is the output of the input gate at the current time step; S3-3, candidate memory cells based on the memory cell state at the previous time step and the current input Update the memory cell state of the current time step, calculated as:
[0016] in, is the memory cell state at the current time step, is the memory cell state at the previous time step; S3-4, calculate the output gate output to obtain the hidden layer state of the current time step, which is calculated as: ,
[0017] in, is the weight matrix of the output gate, is the bias term of the output gate, is the output of the output gate at the current time step, is the hidden state of the current time step; S3-5, based on the hidden layer states of all time steps, obtain the local time series features.
[0018] In an optional implementation, step S4 specifically includes: The weighted combination of enhanced features and local time series features is calculated as:
[0019] in, is the weight parameter, is the reinforcement feature matrix, is the local time series feature, and F is the fused feature vector; Based on the fully connected layer, the fused feature vector is mapped to a low-dimensional space and calculated as:
[0020] in, is the weight matrix of the fully connected layer; is the bias of the fully connected layer, is the output of the fully connected layer; Based on the output layer, the output of the fully connected layer is combined with the weight parameter corresponding to the corrosion rate to obtain the corrosion rate prediction result; the output of the fully connected layer is combined with the weight parameter corresponding to the corrosion depth to obtain the corrosion depth prediction result; the output of the fully connected layer is combined with the weight parameter corresponding to the corrosion risk score to obtain the corrosion risk score prediction result; The prediction matrix output by the output layer is obtained by integrating the corrosion rate prediction results, corrosion depth prediction results and corrosion risk score prediction results.
[0021] In an optional implementation, the weight parameter corresponding to the corrosion rate, the weight parameter corresponding to the corrosion depth, and the weight parameter corresponding to the corrosion risk score are all obtained through model training, specifically including: The weight parameters include weight matrices and bias items, and all weight matrices and bias items are randomly initialized; Based on the forward propagation algorithm, the corrosion rate prediction value, corrosion depth prediction value and corrosion risk score prediction value under the current parameters are calculated; Based on the mean square error loss function, the corrosion rate prediction loss value, the corrosion depth prediction loss value, and the corrosion risk score prediction loss value are calculated respectively; Calculate the gradient of the loss value with respect to the weight matrix and bias term based on the back-propagation algorithm; The weight matrix and bias terms are updated based on the stochastic gradient descent method combined with the calculated gradients.
[0022] In an optional implementation, the severity of corrosion is obtained, and the corrosion risk prediction score is evaluated for the severity of corrosion, where the severity of corrosion includes low risk, medium risk, and high risk.
[0023] In a second aspect, the present invention provides a marine corrosion real-time monitoring system, which, when implemented, executes the above-mentioned marine corrosion real-time monitoring system, including: The data acquisition module acquires real-time raw data based on the sensor equipment deployed on the marine structure. The raw data includes electrochemical data, environmental data, physical state data and corrosion state data. The KAN module maps the original data to a high-dimensional space based on the kernel function, and obtains the most relevant enhanced features of the corrosion state in the original data mapped to the high-dimensional space based on the attention mechanism; LSTM module, which builds an LSTM model based on the time dependency of the corrosion state. The LSTM model inputs reinforcement features and outputs local time series features. The comprehensive prediction module performs weighted fusion of the enhanced features and local time series features to obtain a corrosion state prediction model, inputs the enhanced features and local time series features, and outputs the corrosion rate prediction value, corrosion depth prediction value and corrosion risk score value.
[0024] In a third aspect, a terminal is provided, including: processor, memory, wherein: The memory is used to store computer programs. The processor is used to call and run the computer program from the memory, so that the terminal executes the above-mentioned terminal method.
[0025] In a fourth aspect, a computer storage medium is provided, wherein the computer-readable storage medium stores instructions, and when the computer-readable storage medium is run on a computer, the computer executes the methods described in the above aspects.
[0026] The beneficial effect of the present invention is that the real-time monitoring method, system, terminal and storage medium for marine corrosion provided by the present invention obtain multiple types of raw data through sensor equipment deployed on marine structures, providing a rich source of information for a comprehensive understanding of the status of marine structures. By using kernel function mapping and attention mechanism, the most relevant enhanced features of the corrosion state are effectively mined to enhance the value of data. The LSTM model established based on the time dependency of the corrosion state can accurately capture the temporal changes of features, and the output local time series features are more targeted. The corrosion state prediction model constructed by weighted fusion of enhanced features and local time series features combines the advantages of multiple features, and can output corrosion rate, corrosion depth and corrosion risk score values, to achieve multi-dimensional and accurate prediction of marine corrosion state, which is helpful to timely grasp the corrosion of marine structures, provide a strong basis for taking targeted maintenance measures, improve the safety and service life of marine structures, and at the same time improve the accuracy and reliability of real-time monitoring of marine corrosion, which is of great significance in the field of marine engineering.
[0027] In addition, the invention has a reliable design principle, a simple structure and a very broad application prospect. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0029] Figure 1 It is a schematic flow chart of a method for real-time monitoring of marine corrosion according to an embodiment of the present invention.
[0030] Figure 2 It is a schematic block diagram of a real-time monitoring system for marine corrosion according to an embodiment of the present invention.
[0031] Figure 3 yes Figure 2 Detailed expansion diagram of the KAN module and LSTM module.
[0032] Figure 4 A schematic diagram of the structure of a terminal provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0033] In order to enable those skilled in the art to better understand the technical solutions in the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0034] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art of the present invention. The terms used in the specification of the present invention herein are only for the purpose of describing specific embodiments and are not intended to limit the present invention.
[0035] The real-time monitoring method for marine corrosion provided by the embodiment of the present invention is executed by a computer device, and accordingly, the real-time monitoring system for marine corrosion runs in the computer device.
[0036] Figure 1 : is a schematic flow chart of a method for real-time monitoring of marine corrosion according to an embodiment of the present invention. Figure 1 The execution subject can be a marine corrosion real-time monitoring system. According to different requirements, the order of the steps in the flow chart can be changed, and some can be omitted.
[0037] like Figure 1 As shown, the method includes: S1, based on the sensor equipment deployed on the marine structure to obtain real-time raw data, the raw data includes electrochemical data, environmental data, physical state data and corrosion state data; Various types of data cover electrochemistry, environment, physical state and corrosion state, just like drawing a detailed panoramic picture of the health of marine structures, which can fully reflect the real state of marine structures in complex marine environments. Real-time data acquisition ensures the timeliness of information, so that subsequent analysis can timely capture the dynamic changes of marine structure corrosion, making it possible to timely discover potential corrosion problems.
[0038] S2, maps the original data to a high-dimensional space based on the kernel function, and obtains the most relevant enhanced features of the corrosion state in the original data mapped to the high-dimensional space based on the attention mechanism; Kernel function mapping can dig out the nonlinear relationships hidden in the original data, making the originally complex and difficult to distinguish data features clear and identifiable in high-dimensional space, which helps to discover those characteristic patterns that are not easy to detect in low-dimensional space but have an important impact on the corrosion state. The attention mechanism automatically focuses on the features most relevant to the corrosion state, reducing the impact of irrelevant or interfering information, allowing the model to grasp key information more accurately, thereby improving the accuracy and efficiency of subsequent prediction models, and providing more valuable feature inputs for accurately predicting the corrosion state.
[0039] S3, establish an LSTM model based on the time dependency of the corrosion state. The LSTM model inputs the reinforcement features and outputs the local time series features. The LSTM model can effectively learn the law of corrosion state changes over time and accurately capture the dependencies between features at different time steps. The output local time series features not only contain the information of the current moment, but also contain the key trends in historical data, providing a dynamic and forward-looking basis for predicting future corrosion states, making the prediction results more in line with the evolution of the actual corrosion process, greatly improving the reliability and accuracy of corrosion state prediction, and helping to formulate reasonable maintenance strategies in advance.
[0040] S4, weighted fusion of the enhanced features and local time series features is performed to obtain a corrosion state prediction model, which inputs the enhanced features and local time series features and outputs the corrosion rate prediction value, corrosion depth prediction value and corrosion risk score value.
[0041] The weights can be reasonably allocated according to the importance of the two features, so that the model can fully absorb the key information in the enhanced features and the temporal dynamic information in the local time series features. The corrosion rate, corrosion depth and corrosion risk score values finally output provide a quantitative and intuitive description of the corrosion status of marine structures from different angles, helping relevant personnel to fully understand the severity, development speed and potential risks of corrosion, so that maintenance plans can be formulated more accurately, resources can be allocated reasonably, and the safety, stability and service life of marine structures can be effectively guaranteed.
[0042] Optionally, as an embodiment of the present invention, in step S1, the sensing device includes an electrochemical sensor (such as electrochemical impedance spectroscopy EIS and linear polarization resistance LPR), a temperature and humidity sensor, a salinity sensor, a stress sensor, and a vibration sensor, etc. The collected raw data includes electrochemical data (such as current density, potential change), environmental data (such as temperature, humidity, salinity), physical state data (such as stress, vibration, etc.), and corrosion state data (such as corrosion rate, corrosion depth, etc.).
[0043] Optionally, as an embodiment of the present invention, in step S2, mapping the original data to a high-dimensional space based on a kernel function includes: The original data is preprocessed to complete denoising, standardization and normalization to obtain the original data feature matrix;
[0044] in, is the length of the time series; is the dimension of the feature; Indicates The time step feature values.
[0045] Based on the Gaussian kernel, the original data feature matrix is mapped to a high-dimensional space to generate an enhanced representation of the features and obtain a kernel matrix that reflects the similarity between the feature vectors of the original data. , calculated as:
[0046] in is the original data feature vector of the i-th time step, is the original data feature vector of the jth time step, represents the Euclidean distance between two eigenvectors, is the bandwidth parameter of the kernel function.
[0047] Core Matrix for:
[0048] Optionally, as an embodiment of the present invention, in step S2, obtaining the most relevant enhanced features of the corrosion state in the original data mapped to the high-dimensional space based on the attention mechanism includes: The attention score of each original data feature vector is calculated based on the kernel matrix, which is calculated as:
[0049] in, is the attention score of the original data feature vector at the i-th time step, is the weight of the similarity between the original data feature vector of the i-th time step and the original data feature vector of the j-th time step, and T is the total length of the time series; The attention score is normalized based on the softmax function to obtain the weight of the original data feature vector, which is calculated as:
[0050] in, is the weight of the i-th original data feature vector; All original data feature vectors are weighted and integrated to obtain the enhanced feature vector, which is calculated as:
[0051] in is the reinforcement feature vector; Get the enhanced feature matrix based on the enhanced feature vector : .
[0052] Each column in the enhanced feature matrix corresponds to an important dimension of the original feature set. After being enhanced by the attention mechanism, its relevance and weight can better reflect the dynamic characteristics of the corrosion process.
[0053] Optionally, as an embodiment of the present invention, step S3 specifically includes: S3-1, calculate the forget gate output to control the reinforcement features that need to be retained or forgotten in the memory unit of the previous time step, calculated as:
[0054] in, is the weight matrix of the forget gate, is the hidden state at the previous moment, is the input reinforcement feature of the current time step, is the bias term of the forget gate, S is the sigmoid activation function, is the output of the forget gate at the current time step and is between 0 and 1; S3-2, calculate the input gate output to determine the extent to which the reinforcement feature of the current time step needs to be written into the memory unit, calculated as: ,
[0055] in, is the weight matrix of the input gate, is the bias term of the input gate, is the weight matrix used to generate candidate values, is the corresponding bias term used to generate candidate values, is the new candidate value at the current moment, is the output of the input gate at the current time step and is between 0 and 1; S3-3, candidate memory cells based on the memory cell state at the previous time step and the current input Update the memory cell state of the current time step, calculated as:
[0056] in, is the memory cell state at the current time step, is the memory cell state at the previous time step; S3-4, calculate the output gate output to obtain the hidden layer state of the current time step, which is calculated as: ,
[0057] in, is the weight matrix of the output gate, is the bias term of the output gate, is the output of the output gate at the current time step and is between 0 and 1, is the hidden state of the current time step; S3-5, based on the hidden state of all time steps, obtain the local time series features .
[0058] Optionally, as an embodiment of the present invention, step S4 specifically includes: The weighted combination of enhanced features and local time series features is calculated as:
[0059] in, is the weight parameter, is the reinforcement feature matrix, is the local time series feature, and F is the fused feature vector; Based on the fully connected layer, the fused feature vector is mapped to a low-dimensional space and calculated as:
[0060] in, is the weight matrix of the fully connected layer; is the bias of the fully connected layer, is the output of the fully connected layer; Based on the output layer, the output of the fully connected layer is combined with the weight parameter corresponding to the corrosion rate to obtain the corrosion rate prediction result; the specific corrosion rate prediction model is:
[0061] in, is the corrosion rate, is the corrosion rate weight matrix, is the corrosion rate bias term. According to this model, the corrosion rate prediction value can be obtained. .
[0062] The output of the fully connected layer is combined with the weight parameter corresponding to the corrosion depth to obtain the corrosion depth prediction result;
[0063] in, is the corrosion depth, is the erosion depth weight matrix, is the corrosion depth bias term. According to this model, the corrosion depth prediction value can be obtained. .
[0064] The output of the fully connected layer is combined with the weight parameter corresponding to the corrosion risk score to obtain the corrosion risk score prediction result;
[0065] in, is the corrosion risk score, is the corrosion risk score weight matrix, is the corrosion risk score bias term. According to this model, the corrosion risk score prediction value can be obtained. .
[0066] The prediction matrix of the output layer is obtained by integrating the corrosion rate prediction results, corrosion depth prediction results and corrosion risk score prediction results. : .
[0067] Real-time monitoring and updating are the key dynamic response mechanisms of this method, which can adapt to changes in the environment. After being processed by the data preprocessing module, it is passed through the above method to generate the latest feature representation. At the same time, the module updates the prediction value in real time based on these features to ensure that the prediction result can reflect the dynamic changes of the current environment. In addition, combining historical data with real-time input, the system can adaptively adjust the fusion weight and other key parameters, thereby further enhancing the robustness and accuracy of the prediction.
[0068] Optionally, as an embodiment of the present invention, the weight parameter corresponding to the corrosion rate, the weight parameter corresponding to the corrosion depth, and the weight parameter corresponding to the corrosion risk score are all obtained through model training, specifically including: Weight parameters include weight matrices and bias items. All weight matrices and bias items are randomly initialized. Normal distribution or uniform distribution is used to randomly assign values within a small range to ensure that the initial parameters have a certain degree of randomness, but are not too large or too small to avoid affecting the training effect of the model.
[0069] Based on the forward propagation algorithm, the corrosion rate prediction value, corrosion depth prediction value and corrosion risk score prediction value under the current parameters are calculated; the training data (including input features and corresponding real corrosion rate, corrosion depth, corrosion risk score and other labels) are passed through the forward propagation process of the entire system, that is, the data is obtained from the data acquisition module, through preprocessing, KAN module, LSTM module, weighted fusion, fully connected layer, and finally to the output layer, to calculate the corrosion rate, corrosion depth and corrosion risk score prediction values under the current parameters.
[0070] Based on the mean square error loss function, the corrosion rate prediction loss value, the corrosion depth prediction loss value, and the corrosion risk score prediction loss value are calculated respectively; The gradient of the loss value to the weight matrix and bias term is calculated based on the back-propagation algorithm; back-propagation starts from the output layer, and gradually calculates the parameter gradient of each layer according to the chain rule, and propagates the error back from the output layer to the previous layers, thereby obtaining the gradient value of each weight matrix and bias term.
[0071] Update the weight matrix and bias terms based on the stochastic gradient descent method combined with the calculated gradient:
[0072]
[0073] in, is the learning rate, which controls the step size of parameter updates, Loss of predicted corrosion rate.
[0074] Optionally, as an embodiment of the present invention, the severity of corrosion is obtained, and the corrosion severity is evaluated for the corrosion risk prediction score value, and the corrosion severity includes low risk, medium risk and high risk.
[0075] Low risk (0.0-0.3): No immediate maintenance required.
[0076] Medium risk (0.3-0.7): Regular monitoring is recommended.
[0077] High risk (0.7-1.0): It is recommended to take maintenance measures as soon as possible. Specific maintenance measures include detailed inspection of specific areas, repair or replacement of severely corroded parts, adding anti-corrosion coatings or replacing highly corrosion-resistant materials.
[0078] Optionally, as an embodiment of the present invention, a curve chart is drawn based on the corrosion rate data, the corrosion depth data, and the corrosion risk score, specifically: Corrosion rate curve, with time on the horizontal axis and rate on the vertical axis, showing the corrosion rate Trends over time, marking outliers or areas of rapid change.
[0079] Corrosion depth variation diagram, cumulative corrosion depth The growth trend of the prediction is shown in the bar chart, with each bar corresponding to the predicted time step in the future.
[0080] Risk score heat map, uses heat map to show the corrosion risk distribution in different areas, and uses color gradient (from green to red) to show the risk level of different areas, highlighting high-risk areas.
[0081] Optionally, as an embodiment of the present invention, the prediction results are sorted and organized according to corrosion rate, corrosion depth and risk score. Time information is added to clarify the prediction time step and report generation time. The generated report is stored in a database and classified by time and region to facilitate query and analysis of historical records. Users can export reports to common formats (such as PDF, Excel, JSON) for offline use and sharing.
[0082] The system automatically records and stores historical data for long-term corrosion status trend analysis.
[0083] In some embodiments, the marine corrosion real-time monitoring system may include a plurality of functional modules composed of computer program segments. The computer programs of the various program segments in the marine corrosion real-time monitoring system may be stored in a memory of a computer device and executed by at least one processor to perform (see Figure 1 Description) Function of real-time monitoring of marine corrosion.
[0084] In this embodiment, the marine corrosion real-time monitoring system can be divided into multiple functional modules according to the functions it performs, such as Figure 2 and Figure 3 As shown. The functional modules of the system may include: a data acquisition module, a KAN module, an LSTM module and a comprehensive prediction module. The module referred to in the present invention refers to a series of computer program segments that can be executed by at least one processor and can complete fixed functions, which are stored in a memory. In this embodiment, the functions of each module will be described in detail in subsequent embodiments.
[0085] The data acquisition module acquires real-time raw data based on the sensor equipment deployed on the marine structure. The raw data includes electrochemical data, environmental data, physical state data and corrosion state data. The KAN module maps the original data to a high-dimensional space based on the kernel function, and obtains the most relevant enhanced features of the corrosion state in the original data mapped to the high-dimensional space based on the attention mechanism; LSTM module, which builds an LSTM model based on the time dependency of the corrosion state. The LSTM model inputs reinforcement features and outputs local time series features. The comprehensive prediction module performs weighted fusion of the enhanced features and local time series features to obtain a corrosion state prediction model, inputs the enhanced features and local time series features, and outputs the corrosion rate prediction value, corrosion depth prediction value and corrosion risk score value.
[0086] Figure 3 for Figure 2 Detailed expansion diagram of the KAN module and the LSTM module. During the detailed expansion process, the above-mentioned real-time monitoring method for marine corrosion is realized.
[0087] Figure 4 A schematic diagram of the structure of a terminal provided in an embodiment of the present invention, which can be used to execute the real-time monitoring method for marine corrosion provided in an embodiment of the present invention.
[0088] The terminal may include: a processor, a memory and a communication unit. These components communicate via one or more buses. Those skilled in the art will appreciate that the server structure shown in the figure does not limit the present invention. It may be a bus structure or a star structure, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.
[0089] The memory can be used to store the execution instructions of the processor, and the memory can be implemented by any type of volatile or non-volatile storage terminal or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk. When the execution instructions in the memory are executed by the processor, the terminal is enabled to execute some or all of the steps in the following method embodiments.
[0090] The processor is the control center of the storage terminal, which uses various interfaces and lines to connect various parts of the entire electronic terminal, and executes various functions and / or processes data of the electronic terminal by running or executing software programs and / or modules stored in the memory, and calling data stored in the memory. The processor can be composed of an integrated circuit (IC), for example, it can be composed of a single packaged IC, or it can be composed of multiple packaged ICs with the same or different functions. For example, the processor can only include a central processing unit (CPU). In the embodiment of the present invention, the CPU can be a single computing core or multiple computing cores.
[0091] The communication unit is used to establish a communication channel so that the storage terminal can communicate with other terminals, receive user data sent by other terminals or send user data to other terminals.
[0092] The present invention also provides a computer storage medium, wherein the computer storage medium may store a program, and when the program is executed, the program may include some or all of the steps in each embodiment provided by the present invention. The storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM).
[0093] Therefore, the technical effects that can be achieved by this embodiment can be found in the description above and will not be repeated here.
[0094] Those skilled in the art can clearly understand that the technology in the embodiments of the present invention can be implemented by means of software plus a necessary general hardware platform. Based on this understanding, the technical solution in the embodiments of the present invention, in essence or in other words, the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, and other media that can store program codes, including several instructions for enabling a computer terminal (which can be a personal computer, a server, or a second terminal, a network terminal, etc.) to execute all or part of the steps of the methods described in each embodiment of the present invention.
[0095] In this specification, the same or similar parts between the various embodiments can be referred to each other. In particular, for the terminal embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the description in the method embodiment.
[0096] In the several embodiments provided by the present invention, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the system embodiments described above are only schematic. For example, the division of the modules is only a logical function division. There may be other division methods in actual implementation, such as multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of systems or modules, which can be electrical, mechanical or other forms.
[0097] The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed on multiple network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0098] In addition, each functional module in each embodiment of the present invention may be integrated into one processing module, or each module may exist physically separately, or two or more modules may be integrated into one module.
[0099] Although the present invention has been described in detail with reference to the accompanying drawings and in combination with the preferred embodiments, the present invention is not limited thereto. Without departing from the spirit and essence of the present invention, a person of ordinary skill in the art may make various equivalent modifications or substitutions to the embodiments of the present invention, and these modifications or substitutions shall be within the scope of the present invention. Any person of ordinary skill in the art may easily think of changes or substitutions within the technical scope disclosed by the present invention, and these shall be within the scope of protection of the present invention.
Claims
1. A real-time monitoring method for marine corrosion, characterized in that: include: S1, based on the sensor equipment deployed on the marine structure to obtain real-time raw data, the raw data includes electrochemical data, environmental data, physical state data and corrosion state data; S2, maps the original data to a high-dimensional space based on the kernel function, and obtains the most relevant enhanced features of the corrosion state in the original data mapped to the high-dimensional space based on the attention mechanism; S3, establish an LSTM model based on the time dependency of the corrosion state. The LSTM model inputs the reinforcement features and outputs the local time series features. S4, weighted fusion of the enhanced features and local time series features to obtain a corrosion state prediction model, input the enhanced features and local time series features, and output the corrosion rate prediction value, corrosion depth prediction value and corrosion risk score value.
2. The method for real-time monitoring of marine corrosion according to claim 1, characterized in that: In step S2, mapping the original data to a high-dimensional space based on the kernel function includes: Preprocess the original data to obtain the original data feature matrix; Based on the Gaussian kernel, the original data feature matrix is mapped to a high-dimensional space to obtain a kernel matrix that reflects the similarity between the feature vectors of the original data, which is calculated as: in is the original data feature vector of the i-th time step, is the original data feature vector of the jth time step, represents the Euclidean distance between two eigenvectors, is the bandwidth parameter of the kernel function.
3. The method for real-time monitoring of marine corrosion according to claim 2, characterized in that: In step S2, the enhanced features most relevant to the corrosion state in the original data mapped to the high-dimensional space based on the attention mechanism include: The attention score of each original data feature vector is calculated based on the kernel matrix, which is calculated as: in, is the attention score of the original data feature vector at the i-th time step, is the weight of the similarity between the original data feature vector of the i-th time step and the original data feature vector of the j-th time step, and T is the total length of the time series; The attention score is normalized based on the softmax function to obtain the weight of the original data feature vector, which is calculated as: in, is the weight of the i-th original data feature vector; All original data feature vectors are weighted and integrated to obtain the enhanced feature vector, which is calculated as: in is the reinforcement feature vector; A reinforced feature matrix is obtained based on the reinforced feature vector.
4. The method for real-time monitoring of marine corrosion according to claim 3, characterized in that: Step S3 specifically includes: S3-1, calculate the forget gate output to control the reinforcement features that need to be retained or forgotten in the memory unit of the previous time step, calculated as: in, is the weight matrix of the forget gate, is the hidden state at the previous moment, is the input reinforcement feature of the current time step, is the bias term of the forget gate, S is the sigmoid activation function, is the output of the forget gate at the current time step; S3-2, calculate the input gate output to determine the extent to which the reinforcement feature of the current time step needs to be written into the memory unit, calculated as: , in, is the weight matrix of the input gate, is the bias term of the input gate, is the weight matrix used to generate candidate values, is the corresponding bias term used to generate candidate values, is the new candidate value at the current moment, is the output of the input gate at the current time step; S3-3, candidate memory cells based on the memory cell state at the previous time step and the current input Update the memory cell state of the current time step, calculated as: in, is the memory cell state at the current time step, is the memory cell state at the previous time step; S3-4, calculate the output gate output to obtain the hidden layer state of the current time step, which is calculated as: , in, is the weight matrix of the output gate, is the bias term of the output gate, is the output of the output gate at the current time step, is the hidden state of the current time step; S3-5, based on the hidden layer states of all time steps, obtain the local time series features.
5. The method for real-time monitoring of marine corrosion according to claim 1, characterized in that: Step S4 specifically includes: The weighted combination of enhanced features and local time series features is calculated as: in, is the weight parameter, is the reinforcement feature matrix, is the local time series feature, and F is the fused feature vector; Based on the fully connected layer, the fused feature vector is mapped to a low-dimensional space and calculated as: in, is the weight matrix of the fully connected layer; is the bias of the fully connected layer, is the output of the fully connected layer; Based on the output layer, the output of the fully connected layer is combined with the weight parameter corresponding to the corrosion rate to obtain the corrosion rate prediction result; the output of the fully connected layer is combined with the weight parameter corresponding to the corrosion depth to obtain the corrosion depth prediction result; the output of the fully connected layer is combined with the weight parameter corresponding to the corrosion risk score to obtain the corrosion risk score prediction result; The prediction matrix output by the output layer is obtained by integrating the corrosion rate prediction results, corrosion depth prediction results and corrosion risk score prediction results.
6. The method for real-time monitoring of marine corrosion according to claim 5, characterized in that: The weight parameters corresponding to the corrosion rate, the corrosion depth, and the corrosion risk score are obtained through model training, including: The weight parameters include weight matrices and bias items, and all weight matrices and bias items are randomly initialized; Based on the forward propagation algorithm, the corrosion rate prediction value, corrosion depth prediction value and corrosion risk score prediction value under the current parameters are calculated; Based on the mean square error loss function, the corrosion rate prediction loss value, the corrosion depth prediction loss value, and the corrosion risk score prediction loss value are calculated respectively; Calculate the gradient of the loss value with respect to the weight matrix and bias term based on the back-propagation algorithm; The weight matrix and bias terms are updated based on the stochastic gradient descent method combined with the calculated gradients.
7. The method for real-time monitoring of marine corrosion according to claim 5, characterized in that: The severity of corrosion is obtained and the corrosion risk prediction score is evaluated. The severity of corrosion includes low risk, medium risk and high risk.
8. A real-time monitoring system for marine corrosion, characterized in that: When the system is implemented, the real-time monitoring method for marine corrosion according to any one of claims 1 to 7 is executed, including: The data acquisition module acquires real-time raw data based on the sensor equipment deployed on the marine structure. The raw data includes electrochemical data, environmental data, physical state data and corrosion state data. The KAN module maps the original data to a high-dimensional space based on the kernel function, and obtains the most relevant enhanced features of the corrosion state in the original data mapped to the high-dimensional space based on the attention mechanism; LSTM module, which builds an LSTM model based on the time dependency of the corrosion state. The LSTM model inputs reinforcement features and outputs local time series features. The comprehensive prediction module performs weighted fusion of the enhanced features and local time series features to obtain a corrosion state prediction model, inputs the enhanced features and local time series features, and outputs the corrosion rate prediction value, corrosion depth prediction value and corrosion risk score value.
9. A terminal, characterized in that: include: A memory for storing a real-time marine corrosion monitoring program; A processor is used to implement the steps of the real-time marine corrosion monitoring method as described in any one of claims 1 to 7 when executing the real-time marine corrosion monitoring program.
10. A computer-readable storage medium storing a computer program, characterized in that: The readable storage medium stores a real-time monitoring program for marine corrosion, which, when executed by a processor, implements the steps of the real-time monitoring method for marine corrosion as described in any one of claims 1 to 7.
Citation Information
Patent Citations
Physical model and data fusion driven pipeline corrosion depth prediction method
CN113094934A
Submarine cable state prediction method based on time sequence
CN113468764A
LSTM stock price prediction optimization method based on 3D-CNN and Hash attention mechanism
CN113643133A
Anomaly diagnosis method for underwater structure of marine floating platform
CN113984114A
Seabed oil pipeline corrosion rate prediction method, system, equipment and medium
CN114386462A
Cited By
Pipeline inner wall corrosion detection method and system suitable for water conservancy project
CN119619305A
Corrosion structure monitoring method, device and equipment and storage medium
CN119807716A
Water supply pipeline corrosion risk evaluation method based on multi-source data and time sequence prediction
CN120562319A
Multi-modal intelligent evaluation method for corrosion sensitivity of metal material in deep sea environment
CN120908076A
Deep-sea environment metal material corrosion sensitivity multi-modal intelligent evaluation method
CN120908076B