Hydrogen concentration field space-time reconstruction and prediction method and system based on sparse sensor data

By combining numerical simulation and neural network models, the problems of blind spots and prediction lag in sparse sensor monitoring were solved, enabling spatiotemporal reconstruction and prediction of hydrogen concentration field from sparse sensor data. This improved monitoring accuracy and real-time prediction, ensuring the safety of hydrogen energy transportation facilities.

CN121983162APending Publication Date: 2026-05-05XI AN JIAOTONG UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
XI AN JIAOTONG UNIV
Filing Date
2026-01-14
Publication Date
2026-05-05

AI Technical Summary

Technical Problem

In existing technologies, sparsely deployed point sensors cannot effectively monitor the spatial distribution of hydrogen leaks and predict their diffusion trends, resulting in monitoring blind spots and delayed early warnings, which cannot meet the needs of real-time risk perception and proactive prevention and control.

Method used

Numerical simulation is used to generate sparse sensor time-series data and complete two-dimensional concentration field data. The model is trained using a neural network model with iTransformer architecture. The spatiotemporal reconstruction and prediction of hydrogen concentration field are performed using sparse sensor data, including data preprocessing, standardization, partitioning into training, validation and test sets, and constructing a grid cross-attention decoder for feature mapping and prediction.

Benefits of technology

It has achieved second-level real-time hydrogen concentration field reconstruction and prediction based on sparse sensors, which has reduced hardware deployment costs, improved monitoring accuracy and prediction robustness, provided all-time and all-space situational awareness, and provided an important guarantee for the safe operation of hydrogen energy transportation facilities.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121983162A_ABST
    Figure CN121983162A_ABST
Patent Text Reader

Abstract

The invention discloses a hydrogen concentration field space-time reconstruction and prediction method and system based on sparse sensor data, and relates to the technical field of hydrogen energy safety utilization. The method comprises the following steps: simulating various hydrogen leakage working conditions through numerical simulation, and generating sparse sensor time sequence data and complete two-dimensional concentration field data; preprocessing and standardizing the data, and dividing the processed data into a training set, a verification set and a test set; training a neural network prediction model by using the training set and the verification set to obtain a trained neural network prediction model; and inputting sparse sensor time sequence data collected in real time into the trained neural network prediction model, and outputting a current time concentration field reconstruction result and a future time concentration field prediction sequence through anti-standardization processing. The method can provide full-time-space and prospective situation awareness for the hydrogen leakage risk of the closed space, and has important application value for guaranteeing safe operation of hydrogen energy conveying infrastructures.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of hydrogen energy safe utilization technology, specifically relating to a method and system for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data. Background Technology

[0002] Hydrogen energy, as a key component of the future clean energy system, relies primarily on pipeline transportation for its large-scale and economical delivery. This includes two main routes: constructing new pure hydrogen pipelines and utilizing existing natural gas pipelines for hydrogen blending. However, due to its small molecular weight, high diffusion coefficient, and wide flammability and explosiveness range, hydrogen is highly susceptible to leakage during transportation, especially in enclosed underground spaces such as utility tunnels. Leaks can rapidly accumulate and form explosive mixtures, seriously threatening public safety and facility stability.

[0003] In existing technologies, safety monitoring mainly relies on sparsely deployed point sensors. This technology can only reflect the local concentration at the sensor locations, resulting in serious "monitoring blind spots." Furthermore, it cannot effectively predict leakage and diffusion trends, leading to delayed early warnings and failing to meet the needs of real-time risk perception and proactive prevention.

[0004] To overcome the limitations of point-based monitoring, computational fluid dynamics (CFD) simulation is employed to obtain complete concentration field information. This method, through numerical solution of fluid dynamics equations, can theoretically simulate the diffusion process after a hydrogen leak and obtain the spatial concentration distribution. However, CFD simulation is computationally expensive, and each simulation is extremely time-consuming, making real-time monitoring and rapid prediction impossible, thus hindering its application in online safety early warning systems.

[0005] While data-driven methods offer new insights for concentration field reconstruction and prediction, achieving both high-precision concentration field reconstruction and efficient future time prediction using only a very small amount of sparse sensor data remains a significant technical challenge. This requires models with robust spatiotemporal feature mining and mapping capabilities to overcome challenges such as data sparsity, noise interference, and variable operating conditions. Summary of the Invention

[0006] The purpose of this invention is to overcome the problems of spatial monitoring blind spots and time prediction lag in traditional point monitoring technologies, and to provide a method and system for spatiotemporal reconstruction and prediction of hydrogen concentration fields based on sparse sensor data, so as to quickly and accurately realize spatiotemporal reconstruction and prediction of hydrogen concentration fields.

[0007] To achieve the above objectives, the present invention adopts the following technical solution: In a first aspect, the present invention provides a method for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data, comprising the following steps: Numerical simulation was used to simulate various hydrogen leakage conditions, generating sparse sensor time-series data and complete two-dimensional concentration field data. The sparse sensor time-series data and the complete two-dimensional concentration field data are preprocessed and standardized, and the processed data are divided into training set, validation set and test set. The neural network prediction model is trained using the training set and validation set to obtain a trained neural network prediction model; The real-time collected sparse sensor time-series data is input into the trained neural network prediction model. After denormalization, the model outputs the current concentration field reconstruction result and the future concentration field prediction sequence.

[0008] A further improvement of this invention is that the numerical simulation of various hydrogen leakage conditions includes: Simulate various hydrogen leak scenarios with different leak locations and leak intensities within the integrated utility tunnel; In the simulation model, sparse sensor location points corresponding to the actual deployment are preset, and the concentration time series data of the location points are recorded as sparse sensor time series data; Complete two-dimensional plane concentration field data of spatiotemporal evolution within the simulation area are obtained synchronously as complete two-dimensional concentration field data.

[0009] A further improvement of the present invention is that the preprocessing and standardization include: The time series data of the rarefied hydrogen sensor obtained from the simulation was used as the input data of the neural network. The complete spatiotemporal data of hydrogen concentration field obtained from the simulation is processed into a grid matrix to generate structured matrix data as the output data of the neural network. The input and output data are matched one-to-one in time to construct a dataset, which is then divided into training set, validation set and test set according to the proportions. Based on the data in the training set, a standardization parameter is calculated, and this parameter is used to simultaneously standardize the training set, validation set, and test set.

[0010] A further improvement of the present invention is that the mesh matrixing process includes: Grid interpolation is performed on the discrete point concentration data obtained from the simulation. Linear interpolation is used to generate an initial grid matrix, and the missing values ​​are filled by nearest neighbor interpolation to obtain a two-dimensional grid matrix. Threshold filtering is applied to the two-dimensional grid matrix, and the matrix element values ​​with concentration values ​​less than a preset threshold are set to zero.

[0011] A further improvement of this invention is that the standardization process is performed according to the following formula:

[0012] in, These are the standardized sample values. These are the original sample values. The sample mean. This represents the sample standard deviation.

[0013] A further improvement of the present invention is that the training of the neural network prediction model includes: Construct a neural network prediction model based on the iTransformer architecture, which includes an iTransformer encoder and a grid cross-attention decoder; The neural network prediction model is trained on the standardized training set, and its performance is verified and hyperparameters are tuned using the standardized validation set. The performance of the optimized neural network prediction model was evaluated using a test set to determine the final neural network prediction model to be used for hydrogen concentration field reconstruction and prediction.

[0014] A further improvement of the present invention is that the iTransformer encoder includes an inverted data embedding layer and a Transformer encoding layer; The grid cross-attention decoder is configured to: perform cross-attention calculation on the learnable grid query parameters and the sensor features output by the encoder to generate intermediate two-dimensional grid features, and process the intermediate two-dimensional grid features through a neural network module containing convolutional layers and upsampling layers to decode the hydrogen concentration field with target spatial resolution.

[0015] A further improvement of this invention is that the neural network prediction model is trained to minimize the composite loss function. For the objective, the composite loss function is defined as:

[0016] in, and These are the weighting coefficients for the reconstruction segment and the prediction segment, respectively. For the reconstruction section loss, For the predicted segment loss; The loss of the reconstructed section and predicted segment loss All were obtained by weighted summation:

[0017] in, For weighted Charbonnier loss, For structural similarity loss, For spatial gradient loss, , , These are the weight coefficients for Charbonnier loss, structural similarity loss, and spatial gradient loss, respectively.

[0018] A further improvement of this invention is that the specific steps for outputting the current concentration field reconstruction result and the future concentration field prediction sequence are as follows: Acquire the time series data of hydrogen concentration collected by sparse sensors in the integrated utility tunnel at the current moment; The time series data is input into the neural network prediction model to obtain the concentration field prediction sequence for the future target time. The concentration field prediction sequence is denormalized to output the complete hydrogen concentration field reconstruction result at the current time and the complete hydrogen concentration field prediction sequence at future time.

[0019] Secondly, the present invention also provides a spatiotemporal reconstruction and prediction system for hydrogen concentration fields based on sparse sensor data, comprising the following modules: The data acquisition and simulation module is used to simulate various hydrogen leakage conditions through numerical simulation, and generate sparse sensor time-series data and complete two-dimensional concentration field data. The data preprocessing module is used to preprocess and standardize the sparse sensor time-series data and the complete two-dimensional concentration field data, and divide the processed data into training set, validation set and test set. The model training module is used to train the neural network prediction model using the training set and validation set to obtain a trained neural network prediction model. The concentration field prediction module is used to input the real-time collected sparse sensor time-series data into the trained neural network prediction model, and output the current concentration field reconstruction result and the future concentration field prediction sequence after denormalization processing.

[0020] Compared with the prior art, the present invention has the following beneficial effects: This invention provides a method for spatiotemporal reconstruction and prediction of hydrogen concentration fields based on sparse sensor data. This method uses a very small amount of sparse sensor time-series data as input and simultaneously outputs a complete two-dimensional concentration field reconstruction result for the current moment and a predicted concentration field sequence for future moments, solving the problems of spatial monitoring blind spots and temporal prediction lag inherent in traditional point-based monitoring technologies. Compared to solutions relying on densely deployed sensors, this invention significantly reduces hardware deployment and maintenance costs. Compared to computational fluid dynamics simulation methods, this invention achieves second-level real-time inference through a trained neural network prediction model, overcoming its drawbacks of excessive computation time and inability to be used for online early warning. This invention generates training data through numerical simulation and uses the training and validation sets to train the neural network prediction model, significantly improving the accuracy and robustness of reconstructing the entire field distribution from sparse data and predicting future evolution. This method can provide all-weather, forward-looking situational awareness of hydrogen leakage risks in enclosed spaces such as integrated utility tunnels, gaining valuable time for active ventilation control, emergency decision-making, and personnel evacuation, and has significant application value for ensuring the safe operation of hydrogen energy transportation infrastructure.

[0021] Furthermore, by simulating various hydrogen leakage scenarios with different leakage locations and intensities within the integrated utility tunnel, and pre-setting sparse sensor location points corresponding to actual deployments in the simulation model, this method can efficiently generate a large amount of high-quality training data covering various possible operating conditions. This solves the problem of obtaining a large amount of real leakage data in actual engineering, while avoiding the safety risks and high costs associated with conducting dangerous real leakage experiments. The multi-condition, high-fidelity simulation data obtained through this method provides sufficient and reliable learning samples for the subsequent training of the neural network model, significantly improving the model's generalization ability and robustness in the face of complex and variable real-world scenarios. This is a crucial prerequisite for ensuring that the entire method ultimately achieves practical accuracy.

[0022] Furthermore, this neural network prediction model possesses powerful spatiotemporal feature extraction and mapping capabilities through its unique iTransformer encoder and grid-cross-attention decoder structure. The iTransformer encoder can effectively capture the dynamic changes in sparse sensor time-series data and the spatial correlations between different sensors; while the grid-cross-attention decoder cleverly maps these features onto a two-dimensional spatial grid, achieving accurate reconstruction and prediction from a very small amount of point data to a complete two-dimensional concentration field. Attached Figure Description

[0023] The accompanying drawings described herein are for illustrative purposes only and are not intended to limit the scope of the invention in any way. Furthermore, the shapes and proportions of the components in the drawings are merely illustrative to aid in understanding the invention and do not specifically limit the shapes and proportions of the components of the invention.

[0024] Figure 1 This is an overall flowchart of the spatiotemporal reconstruction and prediction method of hydrogen concentration field based on sparse sensor data provided in this embodiment of the invention. Figure 2 This is a schematic diagram of the geometric model of the integrated utility tunnel in an embodiment of the present invention; Figure 3 This is a flowchart illustrating the process of establishing a numerical simulation model of an integrated utility tunnel and generating data in an embodiment of the present invention. Figure 4 This is a flowchart illustrating the preprocessing and dataset partitioning of simulation data in an embodiment of the present invention; Figure 5 This is a schematic diagram of the neural network prediction model structure used in this embodiment of the invention, the core of which includes an iTransformer encoder and a grid cross-attention decoder; Figure 6 This is a flowchart illustrating the training process of the neural network model in an embodiment of the present invention; Figure 7 This is a schematic diagram comparing the prediction results of this invention with the numerical simulation baseline results. (a) is the concentration field predicted by the model, and (b) is the corresponding numerical simulation concentration field. Figure 8 This is an overall flowchart of the hydrogen concentration field spatiotemporal reconstruction and prediction system based on sparse sensor data of the present invention; Figure 9 This is a schematic diagram of an electronic device according to an embodiment of the present invention.

[0025] The components include: 1. Air outlet; 2. Gas pipeline; 3. Sensor location; 4. Air inlet. Detailed Implementation

[0026] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, 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. The components of the embodiments of the present invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.

[0027] Therefore, the following detailed description of the embodiments of the invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to illustrate selected embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the invention without inventive effort are within the scope of protection of the invention.

[0028] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.

[0029] In the description of the embodiments of the present invention, it should be noted that if terms such as "upper," "lower," "horizontal," or "inner" indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship commonly used when the product of the invention is in use, they are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the present invention. Furthermore, terms such as "first" and "second" are only used to distinguish descriptions and should not be construed as indicating or implying relative importance.

[0030] Furthermore, the use of the term "horizontal" does not imply that the component must be absolutely horizontal, but rather that it can be slightly tilted. For example, "horizontal" simply means that its direction is more horizontal than "vertical," and does not mean that the structure must be completely horizontal, but can be slightly tilted.

[0031] In the description of the embodiments of the present invention, it should also be noted that, unless otherwise explicitly specified and limited, the terms "set," "install," "connect," and "link" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in the present invention according to the specific circumstances.

[0032] The present invention will now be described in further detail with reference to the accompanying drawings: Example 1 like Figure 1 As shown, this invention provides a method for spatiotemporal reconstruction and prediction of hydrogen concentration fields based on sparse sensor data, comprising the following steps: S1: Generate multiple sets of sparse sensor data and complete two-dimensional concentration field data under hydrogen leakage conditions through numerical simulation. like Figure 2 and Figure 3 As shown, in this specific embodiment, step S1 specifically includes the following steps: S11: A three-dimensional full-size geometric model of the integrated utility tunnel is established. The main body of the integrated utility tunnel is a closed cuboid tunnel with a length of 200 m along its axial direction, a clear width of 2 m in the transverse direction, and a clear height of 3.8 m in the vertical direction. The space enclosed by the inner wall, top plate, and bottom plate of the tunnel is used as the fluid calculation domain. A gas pipeline 2 is arranged axially inside the tunnel, running through the length of the tunnel, to represent the gas transmission pipeline within the integrated utility tunnel. The pipeline diameter is 0.4 m. Hydrogen leakage locations are set on the wall of the gas pipeline 2 to construct the geometric conditions corresponding to the hydrogen leakage operation.

[0033] S12: Ventilation openings are provided at the top of both ends of the corridor. An air outlet 1 is provided at the top of one end of the corridor, and an air inlet 4 is provided at the top of the other end, forming the inlet and outlet boundaries for ventilation. Both the air outlet 1 and the air inlet 4 are 1 m in size. Simultaneously, several sparse hydrogen sensor points 3 are arranged along the axial direction of the corridor, 0.2 m below the top plate inside the corridor and 1 m laterally from the side wall. Adjacent hydrogen sensor points 3 are horizontally spaced 10 m apart, totaling 21 sensors, to acquire time-series monitoring data of hydrogen concentration within the integrated utility tunnel.

[0034] S13: A fluid computational domain was constructed based on a full-size geometric model of the integrated utility tunnel, and the computational domain was meshed. Local mesh refinement was performed in areas with significant changes in flow and concentration gradients, such as near gas pipeline leak holes and at outlet 1 and inlet 4, to improve the analytical accuracy of jet diffusion, turbulent mixing, and boundary layer effects.

[0035] S14: Set up a set of governing equations, including at least the mass conservation equation, the momentum conservation equation, and the hydrogen component transport equation. If necessary, introduce a turbulence model and gravity buoyancy terms to describe the ventilation flow field and hydrogen diffusion and buoyancy characteristics within the corridor.

[0036] S15: Define fluid properties, including the density, viscosity, and diffusion coefficient of air and hydrogen (or their mixture), and calculate the properties of the mixture using preset mixing rules.

[0037] S16: Set boundary conditions: apply a pressure outlet boundary at air outlet 1, apply a given velocity inlet boundary at air inlet 4, set the corridor wall and the gas pipeline 2 wall as non-slip solid wall boundaries; set a mass flow inlet boundary at the leak hole.

[0038] S17: Three sets of mesh systems with different densities (coarse, medium, and fine) were used to perform transient simulations of the same typical leakage condition to verify mesh independence. Key monitoring parameters, such as concentration curves at monitoring points, were compared. When the relative deviation between the calculation results of the medium-density mesh and the fine-density mesh was less than a preset threshold, mesh independence was considered satisfied, and the medium-density mesh was selected for simulations of all subsequent conditions to balance computational accuracy and efficiency.

[0039] S18: To ensure that the simulation model accurately reflects the real physical process, the CFD simulation results are compared and verified with known experimental data or results from published authoritative literature. For example, under simplified geometric conditions, the concentration change curves over time or steady-state spatial distribution at the same location can be compared. If the errors of the key indicators between the simulation results and the experimental data are within acceptable limits, the established simulation model is deemed reliable and can be used for subsequent multi-condition simulations.

[0040] S19: Set up multiple hydrogen leakage scenarios, including at least different combinations of leakage location and leakage intensity, to form diverse simulation samples; initialize the flow field, perform transient solution calculations, the transient solution calculation time is 180 s, and output and save the calculation results once per second; during the calculation process, synchronously collect hydrogen concentration time series data of sparse hydrogen sensor point 3, and extract the hydrogen concentration field data at the corresponding time on a preset two-dimensional cross section, wherein the preset two-dimensional cross section is a longitudinal plane located at the centerline of the transverse direction of the corridor, i.e., 1 m away from any side wall and passing through the sparse hydrogen sensor point 3; mark and save the monitoring data and two-dimensional concentration field spatiotemporal data of each scenario according to the scenario number and time series.

[0041] S2: Preprocess and standardize the sparse sensor time-series data and the complete two-dimensional concentration field data, and divide the processed data into training set, validation set and test set; like Figure 4 As shown, in this specific embodiment, step S2 specifically includes the following steps: S21: After completing the transient numerical solution for each working condition, extract hydrogen concentration field data at a preset two-dimensional cross section at a preset time step interval; the concentration field data includes at least the two-dimensional spatial coordinate information of each sampling point on the cross section and the corresponding hydrogen concentration value, and is associated, marked and stored according to the working condition number and time step number to form the original spatiotemporal data sequence.

[0042] S22: To unify the data format under different operating conditions and at different time steps, a fixed spatial range and a regular grid are defined on the preset two-dimensional cross-section. The spatial range is 200 m axially and 3.8 m vertically, covering the effective fluid computation domain. A regular grid with a grid size of 500×50 is constructed within the spatial range. By fixing the spatial range and grid size, each frame of hydrogen concentration field can be represented as a two-dimensional matrix with consistent dimensions and spatial alignment, which facilitates subsequent batch training and inference deployment.

[0043] S23: Map the irregular scattered concentration data obtained in step S21 to the regular grid lattice in step S22, and perform two-stage grid interpolation to obtain a regular grid concentration matrix; first, use linear interpolation to calculate the concentration value of each grid point to maintain the continuity of the spatial distribution of the concentration field; for missing values ​​generated by linear interpolation, use nearest neighbor interpolation to fill them in, and use the filled-in result to replace the missing values, thereby obtaining a gridded two-dimensional concentration matrix without missing values.

[0044] S24: Perform numerical stabilization and noise suppression processing on the gridded two-dimensional concentration matrix obtained in step S23; set the minimum concentration values ​​less than the preset threshold to zero to reduce the background noise caused by numerical errors and interpolation errors; truncate or zero out non-physical negative values; save the processed gridded concentration matrix as complete two-dimensional concentration field label data according to working conditions and time steps.

[0045] S25: Time-align the sparse sensor concentration time series with the grid concentration field time series, and construct samples using the sliding time window method; use the sparse sensor concentration vectors of multiple consecutive historical time steps as the model input sequence, and use the grid concentration field matrix sequence within the corresponding time period as the model output sequence; the output sequence simultaneously includes the reconstruction target of the concentration field at the current time and the prediction target of the concentration field at several future times, enabling the model to have the joint learning ability of current reconstruction and future prediction.

[0046] S26: Organize the samples constructed in step S25 into standard data pairs, and divide them into training, validation, and test sets according to a 7:1:2 ratio. During the partitioning process, a mutually exclusive partitioning strategy is adopted to ensure that the samples in the validation and test sets do not overlap with the samples in the training set, thus avoiding information leakage caused by sliding time window sampling. The representativeness of the sample distribution in each subset is maintained to cover different combinations of working conditions, thereby improving the credibility of the model generalization evaluation.

[0047] S27: Calculate the standardized parameters for the input and output data based solely on the training set. These standardized parameters include the mean and standard deviation. The dataset is standardized according to the following formula:

[0048] in, These are the standardized sample values. These are the original sample values. The sample mean. This represents the sample standard deviation.

[0049] After fixing the standardized parameters, they are used simultaneously for the standardization of the training set, validation set, and test set, and the standardized training set, validation set, and test set are output for neural network training and evaluation, thereby ensuring that there is no information leakage in the data preprocessing process and improving the stability and convergence of model training.

[0050] S3: The neural network prediction model is trained using the training set and validation set to obtain a trained neural network prediction model; wherein the neural network prediction model can take sparse sensor time series data as input and synchronously output the complete two-dimensional concentration field at the current and future times; like Figure 5 As shown, in this specific embodiment, step S3 specifically includes the following steps: S31: Construct a neural network prediction model based on the iTransformer architecture. The neural network prediction model includes an iTransformer encoder and a grid cross-attention decoder. The iTransformer encoder is used to extract the spatiotemporal correlation features between sensors from the time series of sparse hydrogen sensors. The grid cross-attention decoder is used to map the sensor features to a regular grid space of a preset two-dimensional cross-section and decode to obtain a complete hydrogen concentration field sequence output. The input of the neural network prediction model is the hydrogen concentration sequence data of sparse hydrogen sensor point 3 in continuous time steps. The output of the neural network prediction model is a hydrogen concentration field matrix sequence located on the preset two-dimensional cross-section. The single-frame output is a two-dimensional concentration matrix consistent with a fixed spatial range and a regular grid dot matrix, and the multi-frame output is a concentration field sequence composed of several continuous time steps.

[0051] S32: The iTransformer encoder uses an inverted data embedding layer to perform feature mapping on the sensor time series data, forming an embedded feature set to characterize the data of each sensor location; static position information related to the sensor location is introduced into the embedded feature set to characterize the spatial differences of different sensor locations; the fused embedded feature set is input into the Transformer encoding layer for feature extraction, and encoded features reflecting the correlation between multiple sensors are obtained through attention modeling and nonlinear transformation, and the encoded features serve as the basic feature input for the subsequent decoding stage.

[0052] S33: The grid cross-attention decoder sets grid query parameters corresponding to the preset two-dimensional grid dot matrix; when performing concentration field reconstruction and prediction, according to the requirements of the target time step, time-related feature information is introduced and fused with the encoded features to form a sensor feature representation for decoding; using the grid query parameters as query items and the sensor feature representation as keys and values, cross-attention calculation is performed to map the sensor features to a two-dimensional grid space to obtain intermediate two-dimensional grid features.

[0053] S34: The intermediate two-dimensional grid features are input into the decoding network for reconstruction. The decoding network includes convolutional units for extracting local spatial features and upsampling units for improving spatial resolution, and outputs a single-frame hydrogen concentration field matrix consistent with the target spatial resolution. Feature fusion, cross-attention mapping and decoding reconstruction operations are repeatedly performed on multiple consecutive target time steps and combined in chronological order to obtain a complete hydrogen concentration field matrix sequence output, thereby realizing the reconstruction of the hydrogen concentration field at the current time and the prediction of the hydrogen concentration field at future time.

[0054] S35: Train the neural network prediction model based on the standardized training set. The training process includes model initialization, training parameter setting, loss function and optimizer definition, training iteration, and validation evaluation. First, initialize the neural network prediction model parameters and set the training parameters, which include at least the upper limit of the number of training epochs, batch size, and learning rate. Then, define the loss function and optimizer, minimizing the composite loss function during training. For the objective, the composite loss function is defined as:

[0055] in, and These are the weighting coefficients for the reconstruction segment and the prediction segment, respectively. For the reconstruction section loss, For the predicted segment loss; The loss of the reconstructed section and predicted segment loss All were obtained by weighted summation:

[0056] in, For weighted Charbonnier loss, For structural similarity loss, For spatial gradient loss, , , These are the weight coefficients for Charbonnier loss, structural similarity loss, and spatial gradient loss, respectively.

[0057] S36: During training, model parameters are selected and saved based on changes in the validation loss, and the optimal model parameters are loaded for testing and evaluation after training. Specifically, when the validation loss obtained after a certain training round improves compared to the historical best validation loss, the current model parameters are saved as candidate optimal model parameters and the historical best validation loss is updated; when the validation loss does not improve, the candidate optimal model parameters are not updated and the next round of training begins. Training on the training set and evaluation on the validation set are repeated until the number of training rounds reaches a preset maximum value. Then, the candidate optimal model parameters are loaded as the best model parameters, and the model performance is tested on an independent test set that has undergone the same standardization process. A preset evaluation index is output, and the final neural network model used for hydrogen concentration field reconstruction and prediction is determined accordingly.

[0058] S4: Input the real-time collected sparse sensor time-series data into the trained neural network prediction model, and after denormalization processing, output the current concentration field reconstruction result and the future concentration field prediction sequence.

[0059] like Figure 6 As shown, in this specific embodiment, step S4 specifically includes the following steps: S41: Obtain the hydrogen concentration time series data collected by the sparse hydrogen sensors in the integrated utility tunnel at the current moment. The time series data includes the hydrogen concentration values ​​corresponding to each sensor location and is arranged into a continuous multi-time step sequence according to a preset time order to form the sparse sensor concentration sequence data as input to the neural network prediction model.

[0060] S42: Input the sparse sensor concentration sequence data into the neural network prediction model. The neural network prediction model performs temporal feature extraction and spatiotemporal correlation modeling based on the multi-time step sensor observation information at the current moment, and outputs a concentration field prediction sequence located on a preset two-dimensional cross section. The concentration field prediction sequence covers the future target time and is composed of several consecutive time step two-dimensional concentration field matrices in chronological order.

[0061] S43: Perform denormalization on the concentration field prediction sequence to restore the prediction result from the normalized quantity to the actual hydrogen concentration value, and output the complete hydrogen concentration field reconstruction result corresponding to the current time and the complete hydrogen concentration field prediction result corresponding to the future target time from the denormalized concentration field prediction sequence.

[0062] Figure 7This paper presents the results of reconstructing the complete hydrogen concentration field for the 71-80 s period using a sparse hydrogen sensor concentration time series as input, and predicting the complete hydrogen concentration field for the 81-100 s period. A comparison between the predicted results and the hydrogen numerical simulation results is also provided. The comparison results show that the spatiotemporal reconstruction and prediction results of the hydrogen concentration field based on sparse sensor data are in high agreement with the actual concentration field.

[0063] Example 2 like Figure 8 As shown, the present invention also provides a spatiotemporal reconstruction and prediction system for hydrogen concentration fields based on sparse sensor data, comprising the following modules: The data acquisition and simulation module is used to simulate various hydrogen leakage conditions through numerical simulation, and generate sparse sensor time-series data and complete two-dimensional concentration field data. The data preprocessing module is used to preprocess and standardize the sparse sensor time-series data and the complete two-dimensional concentration field data, and divide the processed data into training set, validation set and test set. The model training module is used to train the neural network prediction model using the training set and validation set to obtain a trained neural network prediction model. The concentration field prediction module is used to input the real-time collected sparse sensor time-series data into the trained neural network prediction model, and output the current concentration field reconstruction result and the future concentration field prediction sequence after denormalization processing.

[0064] Example 3 Please see Figure 9 As shown, the present invention also provides an electronic device 100 for a method of spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data; the electronic device 100 includes a memory 101, at least one processor 102, a computer program 103 stored in the memory 101 and executable on the at least one processor 102, and at least one communication bus 104.

[0065] The memory 101 can be used to store the computer program 103. The processor 102 implements the steps of the hydrogen concentration field spatiotemporal reconstruction and prediction method based on sparse sensor data described in Embodiment 1 by running or executing the computer program stored in the memory 101 and calling the data stored in the memory 101. The memory 101 may mainly include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback function, image playback function, etc.), etc.; the data storage area may store data created according to the use of the electronic device 100 (such as audio data), etc. In addition, the memory 101 may include non-volatile memory, such as hard disk, memory, plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, at least one disk storage device, flash memory device, or other non-volatile solid-state storage device.

[0066] The at least one processor 102 may be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The processor 102 may be a microprocessor or any conventional processor. The processor 102 is the control center of the electronic device 100, connecting various parts of the electronic device 100 via various interfaces and lines.

[0067] The memory 101 in the electronic device 100 stores multiple instructions to implement a method for spatiotemporal reconstruction and prediction of hydrogen concentration fields based on sparse sensor data, and the processor 102 can execute the multiple instructions to achieve the following: Numerical simulation was used to simulate various hydrogen leakage conditions, generating sparse sensor time-series data and complete two-dimensional concentration field data. The sparse sensor time-series data and the complete two-dimensional concentration field data are preprocessed and standardized, and the processed data are divided into training set, validation set and test set. The neural network prediction model is trained using the training set and validation set to obtain a trained neural network prediction model; The real-time collected sparse sensor time-series data is input into the trained neural network prediction model. After denormalization, the model outputs the current concentration field reconstruction result and the future concentration field prediction sequence.

[0068] Example 4 If the modules / units integrated in the electronic device 100 are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments can also be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include: any entity or device capable of carrying the computer program code, a recording medium, a USB flash drive, a portable hard drive, a magnetic disk, an optical disk, a computer memory, and a read-only memory (ROM).

[0069] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0070] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0071] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0072] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0073] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the specific implementation of the present invention. Any modifications or equivalent substitutions that do not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.

[0074] Many embodiments and applications beyond the examples provided will be apparent to those skilled in the art upon reading the foregoing description. Therefore, the scope of this teaching should not be determined by reference to the foregoing description, but rather by reference to the foregoing claims and the full scope of their equivalents. For purposes of completeness, all articles and references, including patent applications and publications, are incorporated herein by reference. The omission of any aspect of the subject matter disclosed herein in the foregoing claims is not intended as a waiver of that subject matter, nor should it be construed as an indication that the applicant has not considered that subject matter as part of the disclosed inventive subject matter.

[0075] The above content provides a further detailed description of the present invention. It should not be construed that the specific embodiments of the present invention are limited to this. For those skilled in the art, several simple deductions or substitutions can be made without departing from the concept of the present invention, and all such deductions or substitutions should be considered to fall within the scope of protection of the present invention as defined by the submitted claims.

Claims

1. A method for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data, characterized in that, Includes the following steps: Numerical simulation was used to simulate various hydrogen leakage conditions, generating sparse sensor time-series data and complete two-dimensional concentration field data. The sparse sensor time-series data and the complete two-dimensional concentration field data are preprocessed and standardized, and the processed data are divided into training set, validation set and test set. The neural network prediction model is trained using the training set and validation set to obtain a trained neural network prediction model; The real-time collected sparse sensor time-series data is input into the trained neural network prediction model. After denormalization, the model outputs the current concentration field reconstruction result and the future concentration field prediction sequence.

2. The method for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data according to claim 1, characterized in that, The numerical simulation of various hydrogen leakage conditions includes: Simulate various hydrogen leak scenarios with different leak locations and leak intensities within the integrated utility tunnel; In the simulation model, sparse sensor location points corresponding to the actual deployment are preset, and the concentration time series data of the location points are recorded as sparse sensor time series data; Complete two-dimensional plane concentration field data of spatiotemporal evolution within the simulation area are obtained synchronously as complete two-dimensional concentration field data.

3. The method for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data according to claim 1, characterized in that, The preprocessing and standardization include: The time series data of the rarefied hydrogen sensor obtained from the simulation was used as the input data of the neural network. The complete spatiotemporal data of hydrogen concentration field obtained from the simulation is processed into a grid matrix to generate structured matrix data as the output data of the neural network. The input and output data are matched one-to-one in time to construct a dataset, which is then divided into training set, validation set and test set according to the proportions. Based on the data in the training set, a standardization parameter is calculated, and this parameter is used to simultaneously standardize the training set, validation set, and test set.

4. The method for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data according to claim 3, characterized in that, The grid matrixing process includes: Grid interpolation is performed on the discrete point concentration data obtained from the simulation. Linear interpolation is used to generate an initial grid matrix, and the missing values ​​are filled by nearest neighbor interpolation to obtain a two-dimensional grid matrix. Threshold filtering is applied to the two-dimensional grid matrix, and the matrix element values ​​with concentration values ​​less than a preset threshold are set to zero.

5. The method for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data according to claim 3, characterized in that, The standardization process is performed according to the following formula: in, These are the standardized sample values. These are the original sample values. The sample mean. This represents the sample standard deviation.

6. The method for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data according to claim 1, characterized in that, The training of the neural network prediction model includes: Construct a neural network prediction model based on the iTransformer architecture, which includes an iTransformer encoder and a grid cross-attention decoder; The neural network prediction model is trained on the standardized training set, and its performance is verified and hyperparameters are tuned using the standardized validation set. The performance of the optimized neural network prediction model was evaluated using a test set to determine the final neural network prediction model to be used for hydrogen concentration field reconstruction and prediction.

7. The method for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data according to claim 6, characterized in that, The iTransformer encoder includes an inverted data embedding layer and a Transformer encoding layer; The grid cross-attention decoder is configured to: perform cross-attention calculation on the learnable grid query parameters and the sensor features output by the encoder to generate intermediate two-dimensional grid features, and process the intermediate two-dimensional grid features through a neural network module containing convolutional layers and upsampling layers to decode the hydrogen concentration field with target spatial resolution.

8. The method for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data according to claim 6, characterized in that, Train the neural network prediction model to minimize the composite loss function For the objective, the composite loss function is defined as: in, and These are the weighting coefficients for the reconstruction segment and the prediction segment, respectively. For the reconstruction section loss, For the predicted segment loss; The loss of the reconstructed section and predicted segment loss All were obtained by weighted summation: in, For weighted Charbonnier loss, For structural similarity loss, For spatial gradient loss, , , These are the weight coefficients for Charbonnier loss, structural similarity loss, and spatial gradient loss, respectively.

9. The method for spatiotemporal reconstruction and prediction of hydrogen concentration field based on sparse sensor data according to claim 1, characterized in that, The specific steps for outputting the current concentration field reconstruction result and the future concentration field prediction sequence are as follows: Acquire the time series data of hydrogen concentration collected by sparse sensors in the integrated utility tunnel at the current moment; The time series data is input into the neural network prediction model to obtain the concentration field prediction sequence for the future target time. The concentration field prediction sequence is denormalized to output the complete hydrogen concentration field reconstruction result at the current time and the complete hydrogen concentration field prediction sequence at future time.

10. A spatiotemporal reconstruction and prediction system for hydrogen concentration field based on sparse sensor data, characterized in that, Includes the following modules: The data acquisition and simulation module is used to simulate various hydrogen leakage conditions through numerical simulation, and generate sparse sensor time-series data and complete two-dimensional concentration field data. The data preprocessing module is used to preprocess and standardize the sparse sensor time-series data and the complete two-dimensional concentration field data, and divide the processed data into training set, validation set and test set. The model training module is used to train the neural network prediction model using the training set and validation set to obtain a trained neural network prediction model. The concentration field prediction module is used to input the real-time collected sparse sensor time-series data into the trained neural network prediction model, and output the current concentration field reconstruction result and the future concentration field prediction sequence after denormalization processing.