Rainfall live data correction method based on terrain
By combining multi-layer perceptrons and convolutional neural networks to process terrain data, the problem of traditional precipitation data processing ignores terrain factors is solved, and higher accuracy of precipitation data correction and forecast accuracy are achieved.
Patent Information
- Application Number
- CN202410974864.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-19
- Publication Date
- 2024-11-29
AI Technical Summary
Traditional precipitation data processing methods ignore terrain factors, resulting in spatial and temporal deviations in precipitation data, making it difficult to accurately reflect the actual precipitation situation, especially in complex terrain areas with low data accuracy.
Using the terrain-based precipitation live data correction method, by collecting real meteorological data and local terrain data, using multi-layer perceptron network and convolutional neural network to feature code and correct the data, construct position information attention maps, and fuse elevation data to improve Correction accuracy.
Taking into account terrain factors, the spatial resolution and forecast accuracy of precipitation data are improved. The revised data is more in line with the actual situation and improves the accuracy and reliability of weather and climate forecasts.
Smart Images

Figure CN119046895A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of precipitation data processing, and in particular relates to a method for correcting actual precipitation data based on terrain. Background Art
[0002] With the rapid development of science and technology, precipitation plays a vital role in meteorology, hydrology, agriculture and many other social science applications. Topographic conditions, such as mountains, river valleys, plateaus, etc., have a significant impact on the distribution and intensity of precipitation. Traditional precipitation data collection methods often ignore these topographic factors, resulting in spatial and temporal deviations in precipitation data, making it difficult to accurately reflect the actual precipitation situation. Due to the complexity of the terrain, it is difficult to collect and process precipitation data in mountainous areas, hilly areas, etc., and the data accuracy is often low. In complex terrain areas, precipitation data is often affected by a variety of factors, such as terrain uplift, valley winds, etc. These factors make precipitation data more unreliable in these areas. Therefore, a precipitation data correction method that can adapt to complex terrain conditions and improve data reliability is needed. Summary of the invention
[0003] In view of the above-mentioned deficiencies in the prior art, the terrain-based precipitation real-time data correction method provided by the present invention solves the problem that in the prior art, when processing precipitation data, the terrain factors are not taken into account, resulting in deviations in the space and time of the precipitation data, making it difficult to reflect the actual precipitation conditions.
[0004] In order to achieve the above-mentioned invention object, the technical solution adopted by the present invention is: a method for correcting precipitation real-time data based on terrain, comprising the following steps:
[0005] S1. Collect rainfall impact data and pre-process it;
[0006] Among them, the impact data include real-time meteorological data, rainfall to be corrected, and local terrain data;
[0007] S2, encoding the real-time meteorological data through a multi-layer perceptron network to form meteorological numerical features;
[0008] S3, feature-connecting the meteorological numerical features, the precipitation to be corrected, and the local terrain features;
[0009] S4, constructing a location information attention map based on the location information and elevation data of the station corresponding to the rainfall to be corrected;
[0010] S5, fusing the position information attention map with the feature concatenation and inputting it into the convolutional neural network;
[0011] S6. Correct the amount of water by using a convolutional neural network to correct the precipitation.
[0012] Further, in the step S1, in the impact data:
[0013] The live weather time includes temperature TAIR, dew point temperature DEWP, atmospheric pressure PAIR, humidity QAIR, relative humidity RHUS, wind speed WIND, east-west component DEWP of wind speed, and north-south component VWIN of wind speed;
[0014] The local terrain data includes ground cover type, aspect, slope and height.
[0015] Furthermore, in step S1, the preprocessing of the influencing data is to process outliers and missing values through a normalization method.
[0016] Furthermore, in step S2, the multilayer perceptron network sequentially connects an input layer, a plurality of hidden layers, and an output layer;
[0017] The multi-layer perceptron network F(X) is expressed as:
[0018]
[0019] In the formula, G(·) represents the activation function of the output layer, f(·) represents the output of the hidden layer, and b [1] represents the bias of the hidden layer, W [1] represents the weight of the hidden layer, W [2] represents the weight of the matrix from the hidden layer to the output layer, b [2] represents the bias term added to the output layer neurons, and x represents the input layer.
[0020] Furthermore, the step S4 is specifically as follows:
[0021] S41, mapping the location information of the station corresponding to the precipitation to be corrected onto an image of 800*700 pixels;
[0022] S42, embedding the elevation data into one channel of the image, and generating a heat map in another channel of the image according to the position information, thereby constructing a position attention map.
[0023] Furthermore, in step S41, the conversion formula for mapping the position information to the image is:
[0024]
[0025] In the formula, (x, y) represents the coordinates of the location information in the image, lat represents latitude, and lon represents longitude.
[0026] Furthermore, in step S42, the method for generating the heat map is specifically as follows:
[0027] Initialize an 800*700 array with a value of 0, and set the value of (x, y) on the image to 1. The value near (x, y) is represented by an exponential decay function to obtain the heat map intensity of each observation point, and then generate a heat map;
[0028] The expression of the exponential decay function is:
[0029] I(r)=e -k·r
[0030] Where I(r) represents the intensity of the heat map at a distance r from the observation point, and k is the attenuation coefficient, which controls the attenuation rate.
[0031] Further, in step S5, the convolutional neural network includes a convolutional layer, a pooling layer and a fully connected layer connected in sequence;
[0032] The convolution layer is used to extract the features of the input data using convolution operations and activation functions; wherein the bottom convolution layer is used to extract low-level features, and the upper convolution layer further extracts complex features by integrating low-level features;
[0033] The pooling layer is used to perform dimensionality reduction processing on the output features of the convolutional layer;
[0034] The fully connected layer is used to map the dimension-reduced feature vector output by the pooling layer to the corresponding output category. Furthermore, the loss function L of the convolutional neural network is loss for:
[0035] L loss =αL1+βL2
[0036] Where L1 represents the absolute value error loss function, L2 represents the mean square error loss function, and α and β represent the weight coefficients of the loss functions L1 and L2, respectively.
[0037] The beneficial effects of the present invention are:
[0038] (1) Considering topographic factors: The correction method based on topography can better consider the impact of topography on precipitation distribution. Topography has an important regulatory effect on precipitation. For example, mountains, hills and plains will affect the distribution and intensity of precipitation. Traditional correction methods may ignore these effects, while the method based on topography can more accurately correct precipitation according to topographic characteristics, thus improving the accuracy of the correction.
[0039] (2) Improve spatial resolution: Fuse elevation data with latitude and longitude location data for high-resolution modeling to achieve fine-tuning of the spatial distribution of precipitation. Traditional methods usually use coarse spatial grids or statistical methods, which make it difficult to capture the impact of spatial details on precipitation.
[0040] (3) Improve forecast accuracy: Using the deep learning pytorch framework to establish a regression model (convolutional neural network) to predict precipitation can improve the accuracy of precipitation data, and thus improve the accuracy of weather and climate forecasts. Based on the direct impact of terrain, high altitude, and ground factors on precipitation distribution, by better considering these impacts, the revised data is more in line with the actual situation, which helps to improve the accuracy and reliability of the forecast. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 A flow chart of the terrain-based precipitation real-time data correction method provided by the present invention.
[0042] Figure 2 This is a correction framework diagram for actual precipitation data provided by the present invention. DETAILED DESCRIPTION
[0043] The specific implementation modes of the present invention are described below so that those skilled in the art can understand the present invention. However, it should be clear that the present invention is not limited to the scope of the specific implementation modes. For those of ordinary skill in the art, as long as various changes are within the spirit and scope of the present invention as defined and determined by the attached claims, these changes are obvious, and all inventions and creations utilizing the concept of the present invention are protected.
[0044] Embodiment 1:
[0045] The embodiment of the present invention provides a method for correcting precipitation data based on terrain, such as Figure 1-2 As shown, the following steps are included:
[0046] S1. Collect rainfall impact data and pre-process it;
[0047] Among them, the impact data include real-time meteorological data, rainfall to be corrected, and local terrain data;
[0048] S2, encoding the real-time meteorological data through a multi-layer perceptron network to form meteorological numerical features;
[0049] S3, feature-connecting the meteorological numerical features, the precipitation to be corrected, and the local terrain features;
[0050] S4, constructing a location information attention map based on the location information and elevation data of the station corresponding to the rainfall to be corrected;
[0051] S5, fusing the position information attention map with the feature concatenation and inputting it into the convolutional neural network;
[0052] S6. Correct the amount of water by using a convolutional neural network to correct the precipitation.
[0053] In step S1 of the embodiment of the present invention, in the influencing data:
[0054] The real-time meteorological data include temperature TAIR, dew point temperature DEWP, atmospheric pressure PAIR, humidity QAIR, relative humidity RHUS, wind speed WIND, the east-west component of wind speed DEWP, and the north-south component of wind speed VWIN;
[0055] The local terrain data includes ground cover type, aspect, slope and height; wherein the aspect includes an X-axis component of the aspect and a Y-axis component of the aspect.
[0056] In step S1 of the embodiment of the present invention, the preprocessing of the influencing data is to process outliers and missing values through a normalization method.
[0057] Specifically, in this embodiment, when the scales (units) of the features of different dimensions of Yuanshu data are inconsistent, it is necessary to preprocess the time by normalization. For the relatively small values of the data UWIN and VWIN (wind speed) and the large value of PAIR (atmospheric pressure), the linear function normalization is performed on the data TAIR (temperature), DEWP (dew point temperature), PAIR (atmospheric pressure), QAIR (humidity), RHUS (relative humidity), UWIN (east-west component of wind speed), VWIN (north-south component of wind speed), and WIND (wind speed), and the original data is linearly transformed to the interval [0,1] to achieve geometric scaling of the data. Since the slope aspect is a number without the concept of quantity, sin and cos are used for decomposition coding; LandOver (ground cover type) has 9 categories, so the cover is uniquely encoded.
[0058] In step S2 of the embodiment of the present invention, the multilayer perceptron network MLP is used as a model to capture the characteristics of ground observation real-time data, which is a basic feedforward artificial neural network; the multilayer perceptron network sequentially connects an input layer, several hidden layers and an output layer; each layer is composed of multiple neurons (or nodes), and the neurons between adjacent layers are fully connected.
[0059] Among them, the input data of the input layer is an n-dimensional vector, which is n neurons;
[0060] Hidden layer: fully connected to the input layer. Assuming that the input layer is represented by vector x, the output of the hidden layer is represented as Among them, W [1] is the weight (also called connection coefficient), b [1]is the bias, and the function can be the commonly used ReLU activation function; when the input is negative, the derivative of the ReLU function is 0, and when the input is positive, the derivative of the ReLU function is 1, and when the input value is equal to 0, the ReLU function is not differentiable; the derivative of the ReLU function is:
[0061]
[0062] Output layer: The hidden layer to the output layer is a multi-category logistic regression (softmax regression), which is expressed as:
[0063] Based on this, the multi-layer perceptron network F(X) in this embodiment is expressed as:
[0064]
[0065] In the formula, G(·) represents the activation function of the output layer, f(·) represents the output of the hidden layer, and b [1] represents the bias of the hidden layer, W [1] represents the weight of the hidden layer, W [2] represents the weight of the matrix from the hidden layer to the output layer, b [2] represents the bias term added to the output layer neurons, and x represents the input layer.
[0066] In step S4 of the embodiment of the present invention, the grid field of the terrain and the ordinary image data are similar in many aspects: the horizontal spatial distribution of physical quantities is similar to the pixel matrix of the image, and the types and levels of physical quantities can be compared with the concept of "channel" in the image data. The correction model uses the powerful advantages of convolutional neural networks in the field of recognition to explore the potential mapping relationship between physical quantity fields and precipitation. However, if all grid data within the correction range are directly used as the input of the model, the input variables for different stations at the same time remain unchanged, and it is difficult to obtain meaningful output results. In the embodiment of the present invention, a method for fusing station location information based on position attention is proposed, which can consider both global physical quantity information and physical quantities "near" the station. By embedding terrain data into one channel of the image, a heat map is generated on another channel using the latitude and longitude data of the observation station.
[0067] Specifically, step S4 of the embodiment of the present invention is as follows:
[0068] S41, mapping the location information of the station corresponding to the precipitation to be corrected onto an image of 800*700 pixels;
[0069] S42, embedding the elevation data into one channel of the image, and generating a heat map in another channel of the image according to the position information, thereby constructing a position attention map.
[0070] In step S41 of this embodiment, the geographical coordinates of the observation site are first converted into rectangular coordinates of the image; this conversion involves mapping the latitude and longitude range of 108° to 115°N and 24° to 31°E to an 800*700 pixel image. The conversion formula for mapping the location information to the image is:
[0071]
[0072] Where (x, y) represents the coordinates of the location information in the image, lat represents latitude, and lon represents longitude.
[0073] In step S42 of this embodiment, the method for generating a heat map is specifically as follows:
[0074] Initialize an 800*700 array with a value of 0, and set the value of (x, y) on the image to 1. The value near (x, y) is represented by an exponential decay function to obtain the heat map intensity of each observation point, and then generate a heat map;
[0075] The expression of the exponential decay function is:
[0076] I(r)=e -k·r
[0077] Where I(r) represents the intensity of the heat map at a distance r from the observation point, and l is the attenuation coefficient, which controls the attenuation rate.
[0078] The above method provided by the present embodiment can ensure that the area near the observation point has a higher intensity, while the intensity of the area far from the observation point decreases rapidly, thereby accurately reflecting the degree of influence of each observation point on its surrounding environment. This method makes it possible to take into account the specific terrain conditions around each observation site in the analysis, so as to more accurately understand and predict the relevant environmental impacts. Through this channel fusion technology, it is possible to add the accuracy of the geographical location and the complexity of the terrain while maintaining the original spatial structure of the data, providing an enhanced data representation method.
[0079] In step S5 of the embodiment of the present invention, the core idea of the Convolutional Neural Network (CNN) is to extract features of data such as images through convolution operations, thereby achieving tasks such as classification and recognition of data.
[0080] The convolutional neural network in the embodiment of the present invention includes a convolutional layer, a pooling layer and a fully connected layer connected in sequence;
[0081] In this embodiment, the convolution layer is used to extract the features of the input data using the convolution operation and the activation function; wherein the bottom convolution layer is used to extract low-level features, and the upper convolution layer further extracts complex features by integrating low-level features. Specifically, the convolution operation can be regarded as a special weighted summation operation, wherein the weight parameters in the convolution kernel are obtained through training and learning, and its elements are calculated by the following formula:
[0082]
[0083] Where x represents the element of the original matrix, s represents the element of the new matrix, w represents the weight in the convolution kernel, and m and n represent the number of columns and rows of the convolution kernel.
[0084] The pooling layer in this embodiment is used to reduce the dimension of the output features of the convolutional layer, thereby reducing model parameters and the amount of calculation; commonly used pooling methods include maximum pooling and average pooling.
[0085] The fully connected layer in this embodiment is used to map the dimension-reduced feature vector output by the pooling layer to the corresponding output category, thereby achieving classification or recognition of the input data.
[0086] In the embodiment of the present invention, the loss function L of the convolutional neural network is loss for:
[0087] αL loss =αL1+βL2
[0088] Where L1 represents the absolute value error loss function, L2 represents the mean square error loss function, and α and β represent the weight coefficients of the loss functions L1 and L2, respectively.
[0089] In this embodiment, the above two loss functions are combined to realize the regression task of precipitation correction, which can balance the robustness and sensitivity of the error.
[0090] Embodiment 2:
[0091] The embodiment of the present invention provides quantitative analysis and example analysis of the method in embodiment 1.
[0092] Quantitative analysis:
[0093] In order to evaluate the correction effect of the method of the present invention on precipitation data, the original actual value of CMADaas and five different correction schemes including linear regression, Bagging, Boosting, MLP, and the method proposed in the present invention are compared on the 2021-2023 test set. Six common evaluation indicators are selected to evaluate the consistency of the data before and after correction: mean absolute error (MAE), mean square error (MSE), mean relative error (MRE), mean absolute relative error (MARE), and correlation coefficient (CC). The comparison of the experimental results of various methods on the test set is shown in Table 1. The experimental results show that our model has achieved the best effect in terms of the four indicators of MAE, MSE, MRE, and CC. The MRE indicator in the present invention is negative and very small, indicating that it is effective when predicting larger values, and the predicted values of some larger values are smaller than the true values.
[0094] Table 1: Comparison of experimental results of various methods on the test set
[0095]
[0096] Example analysis:
[0097] In this embodiment, the actual precipitation and corrected precipitation from 00:00 to 23:00 on May 9, 2023 were selected for analysis. Since only 98 observation stations provided actual precipitation data, it is impossible to comprehensively evaluate the precipitation correction effect of all longitude and latitude coordinates. Therefore, the mean absolute error (MAE) between the uncorrected value and the observed value, and the corrected value and the observed value at the locations of these observation stations is calculated to evaluate the correction effect. Table 2 shows the correction results of various correction methods for the observation station locations at 00:00, 06:00, 12:00 and 18:00. Table 3 shows the correction effect of our method at the observation station location from 00:00 to 23:00.
[0098] Table 2: Comparison of correction effects of various methods
[0099]
[0100] Table 3: Evaluation of station location correction effect
[0101]
[0102] The present invention uses specific embodiments to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.
[0103] Those skilled in the art will appreciate that the embodiments described herein are intended to help readers understand the principles of the present invention, and should be understood that the protection scope of the present invention is not limited to such specific statements and embodiments. Those skilled in the art can make various other specific variations and combinations that do not deviate from the essence of the present invention based on the technical revelations disclosed by the present invention, and these variations and combinations are still within the protection scope of the present invention.
Claims
1. A method for correcting precipitation data based on terrain, characterized in that: The following steps are involved: S1. Collect rainfall impact data and pre-process it; Among them, the impact data include real-time meteorological data, rainfall to be corrected, and local terrain data; S2, encoding the real-time meteorological data through a multi-layer perceptron network to form meteorological numerical features; S3, feature-connecting the meteorological numerical features, the precipitation to be corrected, and the local terrain features; S4, constructing a location information attention map based on the location information and elevation data of the station corresponding to the rainfall to be corrected; S5, fusing the position information attention map with the feature concatenation and inputting it into the convolutional neural network; S6. Correct the amount of water by using a convolutional neural network to correct the precipitation.
2. The method for correcting precipitation data based on terrain according to claim 1, characterized in that: In the step S1, in the influencing data: The live weather time includes temperature TAIR, dew point temperature DEWP, atmospheric pressure PAIR, humidity QAIR, relative humidity RHUS, wind speed WIND, east-west component DEWP of wind speed, and north-south component VWIN of wind speed; The local terrain data includes ground cover type, aspect, slope and height.
3. The method for correcting precipitation data based on terrain according to claim 2, characterized in that: In the step S1, the preprocessing of the influencing data is to process outliers and missing values through a normalization method.
4. The method for correcting precipitation data based on terrain according to claim 2, characterized in that: In step S2, the multi-layer perceptron network sequentially connects an input layer, a plurality of hidden layers, and an output layer; The multi-layer perceptron network F(X) is expressed as: In the formula, G(·) represents the activation function of the output layer, f(·) represents the output of the hidden layer, and b [1] represents the bias of the hidden layer, W [1] represents the weight of the hidden layer, W [2] represents the weight of the matrix from the hidden layer to the output layer, b [2] represents the bias term added to the output layer neurons, and x represents the input layer.
5. The method for correcting precipitation data based on terrain according to claim 1, characterized in that: The step S4 is specifically as follows: S41, mapping the location information of the station corresponding to the precipitation to be corrected onto an image of 800*700 pixels; S42, embedding the elevation data into one channel of the image, and generating a heat map in another channel of the image according to the position information, thereby constructing a position attention map.
6. The method for correcting precipitation data based on terrain according to claim 5, characterized in that: In step S41, the conversion formula from the position information to the image is: In the formula, (x, y) represents the coordinates of the location information in the image, lat represents latitude, and lon represents longitude.
7. The method for correcting precipitation data based on terrain according to claim 5, characterized in that: In step S42, the method for generating the heat map is specifically as follows: Initialize an 800*700 array with a value of 0, and set the value of (x, y) on the image to 1. The value near (x, y) is represented by an exponential decay function to obtain the heat map intensity of each observation point, and then generate a heat map; The expression of the exponential decay function is: I(r)=e -k·r Where I(r) represents the intensity of the heat map at a distance r from the observation point, and k is the attenuation coefficient, which controls the attenuation rate.
8. The method for correcting precipitation data based on terrain according to claim 1, characterized in that: In step S5, the convolutional neural network includes a convolutional layer, a pooling layer and a fully connected layer connected in sequence; The convolution layer is used to extract the features of the input data using convolution operations and activation functions; wherein the bottom convolution layer is used to extract low-level features, and the upper convolution layer further extracts complex features by integrating low-level features; The pooling layer is used to perform dimensionality reduction processing on the output features of the convolutional layer; The fully connected layer is used to map the dimension-reduced feature vector output by the pooling layer to the corresponding output category.
9. The method for correcting precipitation data based on terrain according to claim 8, characterized in that: The loss function L of the convolutional neural network loss for: L loss =αL1+βL2 Where L1 represents the absolute value error loss function, L2 represents the mean square error loss function, and α and β represent the weight coefficients of the loss functions L1 and L2, respectively.
Citation Information
Cited By
Intelligent rainfall correction method, device and equipment and storage medium
CN122087735A
A method, apparatus, device, and storage medium for intelligent rainfall correction.
CN122087735B
Classified precipitation correction method, system and equipment for multi-threshold processing and medium
CN122132704A
A multi-threshold processing hierarchical precipitation revision method, system, device and medium
CN122132704B
Precipitation estimation device, precipitation estimation method, and program
WO2026192056A1
