A High-Precision Reconstruction Method for Sparse Sampling of Airflow Field Based on Motion Estimation and Compensation
By employing a motion estimation and compensation-based approach, utilizing bidirectional recurrent convolutional neural networks and feature fusion techniques, the problem of insufficient utilization of time step information in existing technologies is solved, achieving high-precision reconstruction of gas concentration distribution and improving reconstruction quality.
Patent Information
- Application Number
- CN202411186911.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-28
- Publication Date
- 2025-10-31
- Estimated Expiration
- 2044-08-28
AI Technical Summary
Existing gas concentration distribution reconstruction methods based on super-resolution networks fail to fully exploit the spatiotemporal information between consecutive time steps, resulting in limited reconstruction performance.
A high-precision reconstruction method for airflow field sparse sampling based on motion estimation and compensation is adopted. This method involves constructing a training dataset, extracting the gas diffusion relationship between time steps using a motion estimation module and a compensation module, and combining a bidirectional recurrent convolutional neural network and a feature fusion module to achieve high-precision reconstruction.
It significantly improves the accuracy and quality of gas concentration distribution reconstruction, reduces artifacts and blurring, and enhances the overall performance of the reconstruction network.
Smart Images

Figure CN119296681B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data completion, and more particularly to a method for high-precision reconstruction of sparse sampling of gas concentration field distribution. Background Technology
[0002] Gas concentration field distribution has wide-ranging applications in many fields. In the environmental protection field, gas concentration distribution information helps monitor the emission and diffusion of polluting gases (such as sulfur dioxide and nitrogen oxides), providing a scientific basis for air quality assessment and environmental governance. In the industrial field, leaks of hazardous gases may lead to fire, explosion, or poisoning risks. Accurate understanding of gas concentration distribution information can help detect leaks of hazardous gases, locate the leak location, thereby preventing accidents and ensuring the safety of industrial production and workers.
[0003] However, due to the limitations of gas sensor principles, it is difficult to obtain dense gas concentration field distributions in practice. Commonly used gas chemical sensors are designed with active functional layers that readily react with the target gas. Their basic principle is to convert chemical reactions into fluctuations in electrical signals, thereby obtaining gas concentration values. Because these sensors can only measure target gas concentrations through direct contact with gas molecules, the measurement spatial coverage of a single chemical sensor is limited, making it impossible to obtain information on large-area, dense gas concentration distributions. Especially in industrial plants, unless the sensor is installed near the leak point, it is almost impossible to track gas diffusion, making the location of gas leak sources challenging.
[0004] To address the inherent limitations mentioned above, researchers have developed chemical sensor grid systems for indoor applications and industrial manufacturing sites, and have begun studying corresponding gas concentration distribution reconstruction techniques. Chemical sensor grid systems alleviate the limitations of a single sensor's coverage by using a large number of low-cost chemical sensors and installing them in a grid to form a sensor array. The grid system reconstructs the dense gas concentration distribution information within the region of interest by monitoring the response data of each sensor in the array. The core technology used in this process is called gas concentration distribution reconstruction technology.
[0005] Gas concentration distribution reconstruction technology uses sensors to sparsely sample a target area and reconstruct a dense gas concentration distribution map of that area. With the development of the Internet of Things (IoT), dense and real-time gas concentration distribution data can be generated by densely installing sensor arrays; however, the high cost and maintenance challenges of this method are impractical. Therefore, the key to gas concentration distribution reconstruction technology lies in using as few sensors as possible to reconstruct the dense gas concentration distribution with the highest possible accuracy as quickly as possible.
[0006] For sensor grid systems, gas concentration distribution reconstruction techniques can be mainly categorized into model-based methods, statistical methods, and learning-based methods. Model-based methods infer the parameters of the gas concentration distribution model from measurement data and create a gas concentration distribution map by numerically solving the governing equations through fluid dynamics simulations. However, fluid dynamics simulation methods are computationally intensive and unsuitable for complex real-world scenarios requiring high resolution and real-time model updates. Statistical methods reconstruct gas concentration distribution maps using the statistical characteristics of measurement data, primarily including interpolation, Gaussian process regression, and Gaussian kernel extrapolation. Interpolation is relatively fast, but interpolation based on sparse input cannot meet the high-precision reconstruction requirements. Gaussian process regression and Gaussian kernel extrapolation offer higher reconstruction accuracy than interpolation, but their performance is significantly affected by several manually processed parameters. Recent research has employed learning-based methods, treating the gas concentration distribution reconstruction problem as a super-resolution problem. The sparse sampling data of the sensor array is viewed as a low-resolution image, while the reconstructed dense gas concentration distribution is considered a high-resolution image. Advanced deep convolutional neural network methods from the super-resolution domain are used to directly learn the gas concentration distribution patterns, achieving a mapping from sparse sampling data to dense gas concentration distributions. Studies have shown that learning-based super-resolution methods achieve higher reconstruction accuracy than the other two types of methods, and also meet practical requirements in terms of real-time performance.
[0007] However, most current super-resolution networks used for gas concentration distribution reconstruction are based on single-image super-resolution, utilizing only sensor sampling data and spatial information of the array distribution at a single time step. Introducing temporal information from consecutive time steps to achieve spatiotemporal mapping across multiple time steps can achieve better reconstruction quality. Currently, some research has attempted to incorporate sensor array sampling data from multiple consecutive time steps as input to super-resolution networks. One approach treats the data from multiple time steps as multi-channel low-resolution images, then inputs them into a convolutional neural network to extract features; another approach treats the data from multiple time steps as an image sequence, then inputs it into a recurrent convolutional neural network to extract features. The features extracted by both methods are then upsampled and decoded to reconstruct the corresponding high-resolution image, i.e., the dense gas concentration distribution. However, neither method explicitly or implicitly represents the gas diffusion relationship between adjacent time steps. The neural network cannot determine which regions in neighboring time steps to extract features to enhance the reconstruction effect of the current time step. Therefore, existing super-resolution network-based gas concentration distribution reconstruction methods do not fully exploit the spatiotemporal information between consecutive time steps, limiting reconstruction performance. Further improvements are needed. Summary of the Invention
[0008] The technical problem this invention aims to solve is to address the limitations of the existing technology. Considering the gas diffusion motion relationship between consecutive time steps, this invention proposes a high-precision reconstruction method for sparse sampling of the airflow field based on motion estimation and compensation, thereby improving the reconstruction quality. The method includes the following steps:
[0009] The first step is to construct the dataset required to train the network of this invention based on simulation and block sampling techniques, and divide it into training set, validation set and test set;
[0010] The labels used when training the network of this invention are high-resolution gas concentration distribution maps with continuous time steps. The input for training the network of this invention is a high-resolution gas concentration distribution map with continuous time steps. Low-resolution gas concentration distribution maps obtained by block sampling at corresponding time steps Where T is the number of time steps. C, H, and W are respectively The number of channels, height, and width, C, s×H, and s×W are respectively The number of channels, height, and width; s is the downsampling factor or magnification factor, with a default value of 32;
[0011] The second step is to construct a gas concentration distribution reconstruction network based on motion estimation and compensation;
[0012] The gas concentration distribution reconstruction network based on motion estimation and compensation includes:
[0013] (1) Gas motion estimation module, based on two low-resolution gas concentration distribution maps of adjacent time steps. and Calculate from using motion estimation methods respectively arrive and from arrive Positive displacement vector of gas and reverse displacement vector The moving objects reflected in the distribution map can be blocks or pixels;
[0014] (2) Gas motion compensation module, based on positive displacement vector and reverse displacement vector Resampling techniques were used to analyze low-resolution gas concentration distribution maps. Corresponding reverse features and low-resolution gas concentration distribution map Corresponding positive features Perform inverse distortion mapping to obtain the motion-compensated inverse features. and positive features
[0015] (3) Feature extraction module: Utilizes the forward and backward extraction blocks of a bidirectional recurrent convolutional neural network to extract low-resolution gas concentration distribution maps with continuous time steps. Both forward and reverse feature extraction are performed. Forward feature extraction starts from the first time step and proceeds in ascending order of time steps. The input to the forward extraction block is a low-resolution gas concentration distribution map of a single time step. Positive features after motion compensation from the previous time step Then output the positive features of the current time step. Reverse feature extraction starts at time step T and proceeds in decreasing order of time step number. The input to the reverse extraction block is a low-resolution gas concentration distribution map of a single time step. and the inverse features after motion compensation at the next time step Then output the inverse feature of the current time step.
[0016] (4) Feature fusion module, which uses cross-attention mechanism and dilated convolution to fuse the low-resolution gas concentration distribution map of a single time step. positive features and reverse features Implicit feature alignment and fusion are performed to obtain the fused feature f at the current time step. t ;
[0017] (5) Upsampling reconstruction module, which uses a combination of transposed convolution and pixel reconstruction to reconstruct the low-resolution gas concentration distribution map of a single time step. fusion feature f t The size and dimensions are obtained by progressive upsampling. Same residual plot Will Compared to directly using interpolation algorithms Interpolation plot magnified by s times The output of the reconstructed network is obtained by adding them together.
[0018] The third step involves training, validating, and testing the gas concentration distribution reconstruction network based on motion estimation and compensation using the training set, validation set, and test set, respectively, to obtain a trained reconstruction network. During the training phase, the Charbonnier loss function is used to calculate the output of the reconstruction network. High-resolution gas concentration distribution map corresponding to the network input. The loss values between the two methods are used to comprehensively evaluate the merits of the reconstruction method during the verification and testing phases, employing the MSE and SSIM metric functions.
[0019] Furthermore, the steps described in the first step of constructing the dataset required for training the network of this invention based on simulation and block sampling techniques include:
[0020] 1) Using fluid simulation software to simulate the flow of gas in three-dimensional space, sampling is performed at a certain cross-section at a certain period to obtain a high-resolution gas concentration distribution map with continuous time steps.
[0021] 2) Divide the high-resolution gas concentration distribution map of each time step into a square grid. Randomly or systematically select a point in each grid to simulate a gas sensor. Arrange the gas concentration values corresponding to these points according to the positional relationship of the grid to obtain a continuous low-resolution gas concentration distribution map for each time step.
[0022] 3) High-resolution gas concentration distribution maps with T time steps and low-resolution gas concentration distribution map The dataset required to train the network of this invention is constructed as a pair of inputs and labels.
[0023] Furthermore, the motion estimation method described in step (1) is used to calculate the values from... arrive and from arrive Positive displacement vector of gas and reverse displacement vector The motion estimation methods can be block matching, pixel recursion, energy method, optical flow method, or neural network optical flow estimation method.
[0024] Furthermore, the training phase described in step three uses the Charbonnier loss function to calculate the output of the reconstructed network. High-resolution gas concentration distribution map corresponding to the network input. The loss values between these are given by the Charbonnier loss function, which is calculated as follows:
[0025]
[0026] Where C, H, and W represent the output graph of the reconstructed network, respectively. High-resolution gas concentration distribution map corresponding to the network input. The number of channels, height, and width, and Represent and The pixel value in the j-th row and k-th column of the i-th channel, where ε is a preset minimum constant value.
[0027] Furthermore, the verification and testing phase described in step three uses the MSE and SSIM index functions to comprehensively evaluate the merits of the reconstruction method. The calculation expressions for the MSE and SSIM index functions are as follows:
[0028]
[0029] In the MSE expression, C, H, and W represent the network output graph, respectively. High-resolution gas concentration distribution map corresponding to network input The number of channels, height, and width; in the SSIM expression, yes The average value, yes variance yes The average value, yes variance yes and The covariance, c1, and c2 are preset minimum constant values.
[0030] The present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the above-described method steps when executing the program.
[0031] The technical effects and advantages of this invention are as follows:
[0032] This invention considers the gas diffusion relationship between consecutive time steps and proposes a high-precision reconstruction method for sparse sampling of airflow fields based on motion estimation and compensation, which can improve the reconstruction quality. The gas concentration distribution reconstruction network based on motion estimation and compensation has the following advantages: 1) The gas motion estimation module and the gas motion compensation module help the reconstruction network not only extract spatial information from the gas concentration distribution map of a single time step, but also fully mine time-related information from the gas concentration distribution maps of adjacent time steps, thereby improving the reconstruction accuracy and effectively suppressing artifacts and blurring; 2) The feature extraction module and the feature fusion module perform bidirectional feature extraction and efficiently fuse the extracted positive and negative features, effectively alleviating the problem of information imbalance between different time steps caused by unidirectional feature extraction, and improving the overall reconstruction quality; 3) The upsampling reconstruction module uses transposed convolution and pixel recombination to gradually upsample and reconstruct the residual between the interpolated map and the target map, which reduces the difficulty of network learning, accelerates network convergence, and achieves high-magnification upsampling reconstruction.
[0033] Other features and advantages of the invention will be set forth in the following description, and will be apparent in part from the description, or may be learned by practicing the invention. The objects and other advantages of the invention may be realized and obtained by means of the structures pointed out in the description and the drawings. Attached Figure Description
[0034] Figure 1 This is a schematic diagram of the reconstructed network provided in an embodiment of the present invention;
[0035] Figure 2 This is a visualization diagram of motion estimation of gas concentration distribution maps at adjacent time steps provided in an embodiment of the present invention;
[0036] Figure 3 This is a visualization diagram of motion compensation provided in an embodiment of the present invention;
[0037] Figure 4a Target gas concentration distribution map provided for embodiments of the present invention and reference image Gas concentration distribution map obtained after motion compensation A comparative diagram;
[0038] Figure 4b Target gas concentration distribution map provided for embodiments of the present invention and reference image Gas concentration distribution map obtained after motion compensation A comparative diagram;
[0039] Figure 5 This is a schematic diagram of a feature fusion module provided in an embodiment of the present invention;
[0040] Figure 6 shows the reconstruction effect diagrams of different reconstruction methods provided in the embodiments of the present invention; wherein, Figure 6a This is a low-resolution gas concentration distribution map for input. Figure 6b For high-resolution gas concentration distribution maps of the target, Figure 6c This is a diagram showing the reconstruction result using bilinear interpolation. Figure 6d This is a diagram showing the reconstruction result using bicubic interpolation. Figure 6e This is a rendering of the SwinIR reconstruction. Figure 6f This is a reconstruction effect diagram of the reconstruction method provided in the embodiment of the present invention. Detailed Implementation
[0041] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0042] In a specific embodiment of the present invention, a high-precision reconstruction method for sparse sampling of airflow field based on motion estimation and compensation includes the following steps:
[0043] The first step is to construct the dataset required to train the network of this invention based on the Fluent simulation software and the block sampling technique, and divide it into training set, validation set and test set;
[0044] In this embodiment, the steps of constructing the dataset required to train the network of this invention based on Fluent simulation software and block sampling technology include:
[0045] Step 1: Simulate the flow of gas in three-dimensional space using the fluid simulation software Fluent. Sample at a certain cross-section with a certain period to obtain a two-dimensional high-resolution gas concentration distribution map with a size of 224×224 and continuous time steps.
[0046] Step 2: Divide the high-resolution gas concentration distribution map of each time step into a 7×7 square grid. Randomly or systematically select a point in each grid to simulate a gas sensor. Arrange the gas concentration values corresponding to these points according to the positional relationship of the grid to obtain a continuous low-resolution gas concentration distribution map of size 7×7 for each time step.
[0047] Step 3: Create three consecutive high-resolution gas concentration distribution maps over three time steps. and low-resolution gas concentration distribution map The dataset required to train the network of this invention is constructed as a pair of inputs and labels.
[0048] The second step involves using the deep learning framework PyTorch to construct a gas concentration distribution reconstruction network based on motion estimation and compensation. The structure of the reconstruction network is as follows: Figure 1 As shown, the system includes a gas motion estimation module, a gas motion compensation module, a feature extraction module, a feature fusion module, and an upsampling reconstruction module. These modules share parameters across different time steps. The gas motion estimation and gas motion compensation modules perform bidirectional motion estimation and compensation, while the feature extraction module outputs a low-resolution gas concentration distribution map. Corresponding positive features and reverse features The feature fusion module fuses forward and backward features to obtain the fused feature f. t Finally, the upsampling reconstruction module performs fusion on the features f. t Upsampling yields size and Same residual plot Will Compared to directly using interpolation algorithms Interpolated image magnified 32 times The output of the reconstructed network is obtained by adding them together.
[0049] In this embodiment, the gas motion estimation module targets two low-resolution gas concentration distribution maps at adjacent time steps. and Calculation using optical flow method The block or pixel in the middle moves to Displacement vector including lateral and longitudinal directions This is used to explicitly characterize the diffusion and motion relationships of gas between two adjacent distribution maps. Additionally, to improve the final reconstruction quality, it also calculates... The block or pixel in the middle moves to Displacement vector including lateral and longitudinal directions Figure 2 This shows two low-resolution gas concentration distribution maps at adjacent time steps. and The image includes a visualization of pixel motion estimation, with arrows indicating the relative displacement of the pixel estimated by the gas motion estimation module from another time step. Gas motion estimation characterizes the gas diffusion relationship between adjacent time steps, making it possible to extract relevant information from related regions of interest in neighboring time steps to enhance the reconstruction effect at the current time step.
[0050] The gas motion estimation module uses motion estimation methods to estimate gas motion and can be embedded in the network for end-to-end training and inference with the support of hardware parallel computing. Motion estimation does not need to be performed in advance when creating the dataset, which simplifies the training and inference process and speeds up the training and inference process.
[0051] In this embodiment, the gas motion compensation module is based on the positive displacement vector. and reverse displacement vector Resampling techniques were used to analyze low-resolution gas concentration distribution maps. Corresponding reverse features and low-resolution gas concentration distribution map Corresponding positive features Perform inverse distortion mapping to obtain the motion-compensated inverse features. and positive features Figure 3 This shows the positive displacement vector from time t to time t+1. Low-resolution gas concentration distribution map reverse features The distortion mapping process for a specific pixel in the image. The intersection of the straight lines in the image represents a pixel. The left image shows the output of the gas motion compensation module. The image on the right shows one of the module inputs. A solid straight arrow represents another input to the gas motion compensation module. The displacement vector of a specific pixel in the image. To obtain... The gas concentration value at the location of this pixel needs to be determined under the guidance of the displacement vector. Find the pixel value at the corresponding position and place it... In the middle. Due to in The position value of the corresponding pixel in the image is often not an integer, so a resampling technique is needed to obtain the pixel value of the non-integer coordinate point. In this embodiment, the target value is obtained by using the pixel values of four adjacent integer coordinate points and interpolation, and then this value is placed in the left image. At that pixel position, for The same applies to pixel values at other locations. To provide a more intuitive understanding of the function of the gas motion compensation module, Figure 4a The target gas concentration distribution map is shown. and reference image Gas concentration distribution map obtained after inverse distortion mapping The comparison chart, Figure 4b The target gas concentration distribution map is shown. and reference image Gas concentration distribution map obtained after inverse distortion mapping The comparison image is shown below. The gas motion compensation module performs a reverse distortion mapping on the reference gas concentration distribution map based on motion information, placing the pixels of the reference map at the same position as the target map at that time, thus aligning the contents of the reference and target maps spatially. When the two are stacked together in terms of channel number and input into the convolutional neural network, due to the characteristic that the convolutional kernel has a locally fixed-size receptive field, the distorted reference gas concentration distribution map portion in the convolution region is highly correlated with the target gas concentration distribution map portion, thus enhancing the reconstruction effect of the target gas concentration distribution map.
[0052] Gas motion compensation is not performed on the low-resolution gas concentration distribution map, but rather on the corresponding feature map. Moving motion compensation from the image level to the feature level yields significant improvements because inaccuracies in motion estimation have a greater impact on biases introduced by image-level motion compensation, making it more likely to degrade reconstruction performance. In other words, reconstruction networks based on feature-level motion compensation are more robust to motion estimation.
[0053] In this embodiment, the feature extraction module is a bidirectional recurrent convolutional neural network, comprising a forward extraction block and a backward extraction block. The feature extraction network is a convolutional neural network, specifically a stack of convolutional layers, normalization layers, and activation layers. The forward feature extraction part extracts and propagates features along the forward timeline. Taking time t as an example, its input is a low-resolution gas concentration distribution map. as well as Positive characteristics after motion compensation The two are stacked along the channel dimension and fed into the positive feature extraction module, which then outputs the positive features. The output is fed into the feature fusion module and, after motion compensation, into the forward feature extraction module at time t+1. Specifically, at time t=1, the input to the forward feature extraction module is a low-resolution gas concentration distribution map. and size and The feature maps are identical and all values are set to 0 by default. To alleviate the problem of poor reconstruction of low-resolution gas concentration distribution maps in the early stages of forward feature extraction due to too few time steps, short information propagation paths, and a small temporal receptive field, a reverse feature extraction part is introduced, which is the reverse of the above forward feature extraction operation, thus forming a bidirectional recurrent neural network. The bidirectional recurrent convolutional neural network greatly alleviates the problem of unbalanced information transmission between different time steps and can greatly improve the overall reconstruction quality.
[0054] In this embodiment, the structure of the feature fusion module is as follows: Figure 5 As shown, it includes a cross-attention module and a dilated convolution module. Taking time t as an example, the input of the feature fusion module comes from the output of the feature extraction module, i.e., the positive features. and reverse features In the cross-attention module, one of the attention blocks will inversely feature... Treat it as query Q, and include positive features. One attention is viewed as a key-value pair K and V, while the other is viewed in the opposite way. This is due to positive features. and reverse features In the previous modules, there was no interference, and the content of the two modules was spatially misaligned. Therefore, motion estimation and compensation were necessary to improve the quality of the final reconstruction. However, feature maps, unlike distribution maps, do not have obvious physical meaning, making explicit motion estimation and compensation impossible. The cross-attention module can implicitly perform these two steps. When an attention module directs the inverse feature map... Treat it as query Q, and include positive features. When viewed as key-value pairs K and V, the inverse feature It will include positive features For reference, from the perspective of positive features The search engine identifies similar feature representations, utilizing those with higher similarity and suppressing dissimilar features, thus leveraging positive features. The relevant feature information compensates for and enhances the reverse features One feature represents the first, and the other attention represents the second. Therefore, positive features... and reverse features The process of mutually utilizing each other's relevant information to compensate for and enhance themselves is similar to motion estimation and motion compensation. Next, the compensated and enhanced features are stacked along the channel dimension and fed into dilated convolutions with different dilation factors for parallel feature convergence, thus obtaining the fused feature f. t Compared to ordinary convolution, dilated convolutions with different dilation factors can tolerate more spatial shifts in the content related to two features, achieving better feature aggregation and thus enhancing the fused feature f. t This enhances the representational capabilities and improves the quality of the final reconstruction.
[0055] In this embodiment, the upsampling reconstruction module first uses two transposed convolutional layers with an upsampling factor of 4, and then uses a pixel reconstruction layer with an upsampling factor of 2 to reconstruct the low-resolution gas concentration distribution map of a single time step. fusion feature f t A total of 32x upsampling was performed to obtain the size and Same residual plot Finally Compared to directly using the bilinear interpolation algorithm Interpolated image magnified 32 times The output of the reconstructed network is obtained by adding them together. The upsampling reconstruction module improves reconstruction accuracy by using progressive upsampling, and speeds up reconstruction by combining transposed convolution and pixel recombination. Furthermore, by reconstructing the residual map between the target output and the interpolated map, the learning difficulty of the network is reduced, network convergence is accelerated, and the final reconstruction quality is improved.
[0056] The third step involves using the training set, validation set, and test set to train, validate, and test the gas concentration distribution reconstruction network based on motion estimation and compensation, respectively, to obtain the trained reconstruction network.
[0057] In the training phase of this embodiment, three 7×7 time-step continuous low-resolution gas concentration distribution maps are selected from the training set and input into the reconstruction network. The reconstruction network outputs three corresponding 224×224 images. The Charbonnier loss function is used to calculate the loss value between the output image and the corresponding high-resolution gas concentration distribution map input to the reconstruction network. The network parameters are updated based on the loss value through backpropagation to obtain the reconstructed network model after one training iteration. The above training steps are repeated until a certain number of training iterations or a loss value threshold is reached, at which point training terminates. The Charbonnier loss function expression is as follows:
[0058]
[0059] Where C, H, and W represent the output graph of the reconstructed network, respectively. High-resolution gas concentration distribution map corresponding to the network input. The number of channels, height, and width, and Represent and The pixel value in the j-th row and k-th column of the i-th channel, where ε is a preset minimum constant value, typically taken as 10. -6 A smaller Charbonnier loss value results in better reconstruction performance. Compared to the commonly used pixel-level loss function MSE, the Charbonnier loss function is more robust, can better handle outliers, and improves network reconstruction performance.
[0060] In the validation phase of this embodiment, three 7×7 time-step continuous low-resolution gas concentration distribution maps are selected from the validation set and input into the reconstruction network. The reconstruction network outputs three corresponding 224×224 images. The evaluation values between the output images and the corresponding high-resolution gas concentration distribution maps input to the reconstruction network are calculated using the MSE and SSIM index functions. After each training step, a validation step is performed, and the model with the best overall evaluation value is selected as the final trained reconstruction network model. The expressions for the MSE and SSIM index functions are as follows:
[0061]
[0062] In the MSE expression, C, H, and W represent the network output graph, respectively. High-resolution gas concentration distribution map corresponding to network input The number of channels, height, and width; in the SSIM expression, yes The average value, yes variance yes The average value, yes variance yes and The covariance, c1, and c2 are preset minimum constant values to avoid zero in the denominator. A smaller MSE evaluation value indicates a smaller difference between the two images. However, the MSE evaluation metric cannot accurately measure the similarity between two images according to human visual perception. Therefore, the SSIM metric is introduced as a supplement. The SSIM structural similarity metric, based on the assumption of human vision, extracts brightness, contrast, and structural information from the image, which is more consistent with human visual perception. The SSIM evaluation value ranges from -1 to 1; the closer to 1, the more similar the two images. Using a comprehensive evaluation using MSE and SSIM metric functions can reduce artifacts and blurring in the reconstructed image while ensuring reconstruction accuracy, thus improving the overall quality of the reconstruction.
[0063] In the testing phase of this embodiment, three 7×7 time-step continuous low-resolution gas concentration distribution maps are selected from the test set and input into the reconstruction network. The reconstruction network outputs three corresponding 224×224 images. The evaluation values between the output images and the corresponding high-resolution gas concentration distribution maps are calculated using the MSE and SSIM index functions. The testing phase occurs after the training and validation phases and is performed only once to evaluate the merits of different reconstruction methods.
[0064] Table 1 compares our proposed method with other reconstruction methods, using MSE and SSIM as evaluation metrics. Three methods were compared: bilinear interpolation, bicubic interpolation, and the image super-resolution network SwinIR. Experimental results show that our proposed method achieves the best results in both metrics.
[0065] Table 1 Comparison of this method with other reconstruction methods
[0066] Reconstruction methods MSE↓ SSIM↑ Bilinear interpolation 4.0657 0.9630 Bicubic interpolation 4.2124 0.9616 SwinIR 1.6735 0.9854 This invention 0.5561 0.9938
[0067] Figure 6 shows the reconstruction results of different reconstruction methods, in which... Figure 6a This is a low-resolution gas concentration distribution map for input. Figure 6b For high-resolution gas concentration distribution maps of the target, Figure 6c This is a diagram showing the reconstruction result using bilinear interpolation. Figure 6d This is a diagram showing the reconstruction result using bicubic interpolation. Figure 6eThis is a rendering of the SwinIR reconstruction. Figure 6f The image shows the reconstruction effect of the reconstruction method provided in this embodiment of the invention. It can be seen that the method of this invention not only has higher reconstruction accuracy, but also fewer artifacts and blurring in the reconstructed image, resulting in higher reconstruction quality.
[0068] Finally, it should be noted that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A high-precision reconstruction method for sparse sampling of airflow fields based on motion estimation and compensation, characterized in that, Includes the following steps: The first step is to construct the dataset required to train this network based on simulation and block sampling techniques, and divide it into training set, validation set and test set; The labels used during network training are high-resolution gas concentration distribution maps with continuous time steps. The input for training the network is a high-resolution gas concentration distribution map with continuous time steps. Low-resolution gas concentration distribution maps obtained by block sampling at corresponding time steps Where T is the number of time steps. C, H, and W are respectively The number of channels, height, and width, C, s×H, and s×W are respectively The number of channels, height, and width; s is the downsampling factor or magnification factor, with a default value of 32; The second step is to construct a gas concentration distribution reconstruction network based on motion estimation and compensation; The gas concentration distribution reconstruction network based on motion estimation and compensation includes: (1) Gas motion estimation module, based on two low-resolution gas concentration distribution maps of adjacent time steps. and Calculate from using motion estimation methods respectively arrive and from arrive Positive displacement vector of gas and reverse displacement vector The moving objects reflected in the distribution map can be blocks or pixels; (2) Gas motion compensation module, based on positive displacement vector and reverse displacement vector Resampling techniques were used to analyze low-resolution gas concentration distribution maps. Corresponding reverse features and low-resolution gas concentration distribution map Corresponding positive features Perform inverse distortion mapping to obtain the motion-compensated inverse features. and positive features (3) Feature extraction module: Utilizes the forward and backward extraction blocks of a bidirectional recurrent convolutional neural network to extract low-resolution gas concentration distribution maps with continuous time steps. Both forward and reverse feature extraction are performed. Forward feature extraction starts from the first time step and proceeds in ascending order of time steps. The input to the forward extraction block is a low-resolution gas concentration distribution map of a single time step. Positive features after motion compensation from the previous time step Then output the positive features of the current time step. Reverse feature extraction starts at time step T and proceeds in decreasing order of time step number. The input to the reverse extraction block is a low-resolution gas concentration distribution map of a single time step. and the inverse features after motion compensation at the next time step Then output the inverse feature of the current time step. (4) Feature fusion module, which uses cross-attention mechanism and dilated convolution to fuse the low-resolution gas concentration distribution map of a single time step. positive features and reverse features Implicit feature alignment and fusion are performed to obtain the fused feature ft at the current time step; (5) Upsampling reconstruction module, which uses a combination of transposed convolution and pixel reconstruction to reconstruct the low-resolution gas concentration distribution map of a single time step. The fusion features ft are progressively upsampled to obtain the size and Same residual plot Will Compared to directly using interpolation algorithms Interpolation plot magnified by s times The output of the reconstructed network is obtained by adding them together. The third step involves training, validating, and testing the gas concentration distribution reconstruction network based on motion estimation and compensation using the training set, validation set, and test set, respectively, to obtain a trained reconstruction network. During the training phase, the Charbonnier loss function is used to calculate the output of the reconstruction network. High-resolution gas concentration distribution map corresponding to the network input. The loss values between the two methods are used to comprehensively evaluate the merits of the reconstruction method during the verification and testing phases, employing the MSE and SSIM metric functions.
2. The high-precision reconstruction method for sparse sampling of airflow field based on motion estimation and compensation as described in claim 1, characterized in that, The steps described in the first step, which involve constructing the dataset required for training this network based on simulation and block sampling techniques, include: 1) Using fluid simulation software to simulate the flow of gas in three-dimensional space, sampling is performed at a certain cross-section at a certain period to obtain a high-resolution gas concentration distribution map with continuous time steps. 2) Divide the high-resolution gas concentration distribution map of each time step into a square grid. Randomly or systematically select a point in each grid to simulate a gas sensor. Arrange the gas concentration values corresponding to these points according to the positional relationship of the grid to obtain a continuous low-resolution gas concentration distribution map for each time step. 3) High-resolution gas concentration distribution maps with T time steps and low-resolution gas concentration distribution map The dataset used to build the network is a pair of inputs and labels.
3. The high-precision reconstruction method for sparse sampling of airflow field based on motion estimation and compensation as described in claim 1, characterized in that, The second step (1) describes using motion estimation methods to calculate the values from... arrive and from arrive Positive displacement vector of gas and reverse displacement vector The motion estimation methods can be block matching, pixel recursion, energy method, optical flow method, or neural network optical flow estimation method.
4. The high-precision reconstruction method for sparse sampling of airflow field based on motion estimation and compensation as described in claim 1, characterized in that, The training phase described in step three uses the Charbonnier loss function to calculate the output of the reconstructed network. High-resolution gas concentration distribution map corresponding to the network input. The loss values between these are given by the Charbonnier loss function, which is calculated as follows: Where C, H, and W represent the output graph of the reconstructed network, respectively. High-resolution gas concentration distribution map corresponding to the network input. The number of channels, height, and width, and Represent and The pixel value in the j-th row and k-th column of the i-th channel, where ε is a preset minimum constant value.
5. The high-precision reconstruction method for sparse sampling of airflow field based on motion estimation and compensation as described in claim 1, characterized in that, The verification and testing phase described in step three uses the MSE and SSIM index functions to comprehensively evaluate the merits of the reconstruction method. The calculation expressions for the MSE and SSIM index functions are as follows: In the MSE expression, C, H, and W represent the network output graph, respectively. High-resolution gas concentration distribution map corresponding to network input The number of channels, height, and width; in the SSIM expression, yes The average value, yes variance yes The average value, yes variance yes and The covariance, c1, and c2 are preset minimum constant values.
6. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps of the method described in any one of claims 1-5.
Citation Information
Patent Citations
Flow field reconstruction and prediction method based on bidirectional long-short term memory neural network
CN117371314A
High-flux plasma arc in-situ metallurgical method and metallurgical device
CN118133684A