Temperature space-time prediction method based on multi-scale large-kernel space-time prediction neural network

Through a multi-scale large-core space-time prediction neural network, combined with a multi-scale space-time attention unit, the problem of large errors in the temperature space-time prediction of existing meteorological forecasting methods is solved, and more accurate temperature prediction is achieved, especially in capturing the temperature being affected by the terrain. local climate effects aspects.

CN119129795AActive Publication Date: 2024-12-13HARBIN ENG UNIV

Patent Information

Application Number
CN202411020312.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2024-06-26
Filing Date
2024-07-29
Publication Date
2024-12-13
Estimated Expiration
2044-07-29

AI Technical Summary

Technical Problem

The existing meteorological forecasting methods rely on parameterized numerical models, which are prone to errors and are difficult to effectively capture the local climate effects formed by temperatures affected by terrain, resulting in insufficient accuracy of temperature spatial and temporal prediction.

Method used

The temperature and space-time prediction method based on multi-scale large-core spatiotemporal prediction neural network is adopted, and the spatial and temporal characteristics of the temperature data are learned through the encoder-space-time translator-decoder architecture, combined with the multi-scale spatiotemporal attention unit. Capture the pattern of temperature changes.

Benefits of technology

It improves the accuracy and stability of temperature space-time prediction, can better learn the temporal evolution laws of spatial characteristics, and obtain more accurate temperature prediction results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119129795A_ABST
    Figure CN119129795A_ABST
Patent Text Reader

Abstract

The invention discloses an air temperature space-time prediction method based on a multi-scale large-kernel space-time prediction neural network, and belongs to the technical field of atmospheric science. According to the method, a multi-scale large-kernel space-time prediction neural network is adopted to construct an air temperature space-time prediction model, the model is an encoder-space-time translator-decoder architecture, a core module MSSTA of a space-time translator is decomposed into a multi-scale space attention MSST and a time evolution attention TEA, the MSST decomposes large-kernel convolution from a multi-scale angle, and the time evolution attention TEA is decomposed from a multi-scale angle. Spatial feature information of different scales is captured, and TEA pays attention to global gentle evolution and local rapid evolution of multi-scale spatial features along with time; and training a model by using the ERA5-Land air temperature data of the target area, and applying the trained model to air temperature space-time prediction of the target area. According to the method, the characteristic that the temperature changes under different scales have differences is considered, multi-scale spatio-temporal feature transformation is learned, and a more accurate temperature spatio-temporal prediction result can be obtained.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of atmospheric science technology, and in particular relates to a method for spatiotemporal temperature prediction based on a multi-scale large-kernel spatiotemporal prediction neural network. Background Art

[0002] Accurate temperature forecasts are of great significance in modern society, helping people avoid the effects of severe high and low temperatures. By predicting temperature, people can better cope with weather changes, reduce risks, and improve efficiency and productivity in various fields. Temperature forecasts play an important role in agriculture, energy management, ecological environment, health care, and scientific research, and have a profound impact on the development and sustainability of society.

[0003] The current mainstream weather forecasting method is based on traditional numerical weather prediction (NWP), which uses mathematical equations to describe atmospheric motion and physical processes and solves them through numerical simulation. However, the traditional NWP method has high computing resource requirements and mainly relies on parameterized numerical models. These models are subject to uncertainty due to the influence of initial conditions and parameter selection, which can easily lead to increased errors.

[0004] In recent years, with the rapid development of data-driven deep learning methods, weather forecasting methods based on deep learning are considered to be a powerful supplement to traditional methods. Related models of spatiotemporal series prediction based on deep learning have been applied to the spatiotemporal prediction of temperature. These models can capture the spatiotemporal correlation and nonlinear characteristics in temperature data. By learning from historical meteorological data, they can discover the hidden patterns and laws in the climate system and predict the future temperature trends. However, the challenges faced by spatiotemporal series prediction research based on deep learning in the spatiotemporal prediction of temperature are more complex, because the temperature is affected by the terrain to form large-scale plain land temperature, and the small and medium-scale local temperature is affected by the terrain such as valleys and lakes. Generally speaking, the temperature of large-scale plain land is relatively average, and valleys, canyons and lakes will produce local climate effects. How to learn the temperature change law of local climate effects formed by the terrain and the overall temperature change of large-area land plains will help improve the accuracy of temperature prediction, so it is a research goal. Summary of the invention

[0005] In order to achieve the above objectives, the present invention discloses a method for spatiotemporal temperature prediction based on a multi-scale large-kernel spatiotemporal prediction neural network. This algorithm is constructed based on a deep learning method using the reanalysis temperature data of ERA5-Land. Taking into account the differences in temperature changes at different scales, multi-scale spatiotemporal feature transformations are learned to obtain better temperature prediction results.

[0006] A method for spatiotemporal prediction of temperature based on a multi-scale large-core spatiotemporal prediction neural network of the present invention comprises the following steps:

[0007] Step 1: Collect ERA5-Land temperature data and construct a temperature dataset, including normalizing the collected data and setting the forecast duration, and dividing the training, validation, and test datasets.

[0008] Step 2: Use a multi-scale large-core spatiotemporal prediction neural network to build a temperature spatiotemporal prediction model; the multi-scale large-core spatiotemporal prediction neural network is an encoder-spatial-temporal translator-decoder architecture, where: the encoder consists of N s The encoder captures the spatial characteristics of single-frame temperature grid data; the spatiotemporal translator consists of N t The network consists of MSLKA units; each MSLKA unit contains an MSSTA unit and a ConvFFN unit. A two-dimensional batch normalization structure is set before the MSSTA unit and the ConvFFN unit. The ConvFFN unit is used to enhance local features. The MSSTA unit contains a two-dimensional convolution layer, a GELU layer, an MSSTA structure and a two-dimensional convolution layer in sequence; the MSSTA structure is decomposed into two parts: multi-scale spatial attention MSST and time evolution attention TEA; the MSST part is decomposed into multi-scale spatial local depth convolution, spatial expansion convolution and channel convolution, and multi-scale spatial attention processing is performed on the data; the TEA part is divided into two parts: gentle time evolution attention GTEA and rapid time evolution attention ATEA. GTEA focuses on learning the evolution law of overall regional features over time, which is achieved through an average pooling layer, a one-dimensional convolution and a Sigmoid activation function; ATEA focuses on learning the evolution law of local regional features over time, which is achieved through a maximum pooling layer, a one-dimensional convolution and a Sigmoid activation function; the decoder consists of N s The decoder outputs the temperature grid data prediction frame of the future time. s is a multiple of 2 and greater than 2, N t is an integer greater than 1.

[0009] Step 3, using the temperature data set constructed in step 1 to train the temperature spatiotemporal prediction model, and using the trained temperature spatiotemporal prediction model to predict the temperature at future moments using the temperature spatiotemporal data of the target area collected in real time.

[0010] In the step 3, the temperature spatiotemporal data of the target area collected in real time is first normalized, then input into the trained temperature spatiotemporal prediction model, and the prediction results are denormalized to obtain the final temperature spatiotemporal prediction results of the target area.

[0011] Compared with the prior art, the advantages and positive effects of the present invention are:

[0012] (1) The method of the present invention is based on ERA5-Land historical temperature data. It uses deep learning methods to learn the nonlinear spatiotemporal variation laws of historical temperature characteristics, constructs a model that can effectively learn the historical spatiotemporal variation laws, and realizes the prediction results of future temperature based on historical temperature data.

[0013] (2) The method of the present invention uses a multi-scale large-core spatiotemporal attention neural network to construct a temperature spatiotemporal prediction model, extracts spatial features through a feature encoder, learns the changes between frames through a multi-scale spatiotemporal translator, learns the spatiotemporal evolution law, and completes spatiotemporal prediction by combining spatial information and temporal evolution law through a feature decoder. Among them, the core of the multi-scale spatiotemporal translator is a multi-scale large-core spatiotemporal attention unit, which divides spatiotemporal attention into attention to local and global features of the spatial dimension and attention to global stability and local prominent evolution of temporal dimension features. The temperature spatiotemporal prediction model of the present invention can better learn the temporal evolution law of spatial features, improve the effect of temperature spatiotemporal prediction, and obtain more accurate temperature spatiotemporal prediction results. BRIEF DESCRIPTION OF THE DRAWINGS

[0014] Figure 1 It is a flow chart of the method for spatiotemporal prediction of temperature based on a multi-scale large-kernel spatiotemporal prediction neural network of the present invention;

[0015] Figure 2 This is the overall structure diagram of the multi-scale large-kernel spatiotemporal prediction neural network of the present invention;

[0016] Figure 3 A structural diagram of a multi-scale spatiotemporal attention unit in a multi-scale large-kernel spatiotemporal prediction neural network of the present invention;

[0017] Figure 4 This is the decomposition diagram of the large kernel volume of the present invention. DETAILED DESCRIPTION

[0018] The present invention will be further described in detail below with reference to the accompanying drawings and embodiments.

[0019] The embodiment of the present invention implements a method for spatiotemporal prediction of temperature based on a multi-scale large-kernel spatiotemporal prediction neural network. First, ERA5-Land reanalysis temperature data is collected to construct a data set; then, a multi-scale large-kernel spatiotemporal prediction neural network model (MSLKSTNet) is constructed. The model is mainly divided into three modules: feature encoder, multi-scale spatiotemporal translator and feature decoder. The core module Multi-scale spatiotemporal attention (MSSTA) in the multi-scale spatiotemporal translator decomposes large-kernel convolution from a multi-scale perspective, captures spatial feature information of different scales, and pays attention to the global smooth evolution and local rapid evolution of multi-scale spatial features over time. Based on this model training, a temperature spatiotemporal prediction model is obtained to complete the temperature spatiotemporal prediction task. The present invention takes into account the multi-scale characteristics of the temperature spatiotemporal characteristics, constructs a neural network that can learn multi-scale spatiotemporal changes in temperature, and can obtain more accurate temperature spatiotemporal prediction results.

[0020] like Figure 1 As shown, the temperature spatiotemporal prediction method based on a multi-scale large-core spatiotemporal prediction neural network in an embodiment of the present invention includes the following four steps, which are described in detail below.

[0021] Step 1: The embodiment of the present invention collects ERA5-Land temperature data to construct a temperature dataset.

[0022] Data collection: The spatial resolution of the ground data of the ERA5 dataset is 0.1°×0.1°, and the temporal resolution is 1h. The data area is selected from the east longitude (115.7°-103.0°) and the north latitude (36.7°-24.0°), and a frame of 128*128 temperature grid data is formed at each moment. The data spanning from 2015 to 2021 is selected.

[0023] Data processing: In order to speed up the training of the model and improve the accuracy of the model, the data is standardized to make it obey the standard normal distribution. At the same time, the embodiment of the present invention uses the data of the first 12 hours as the input of the model and the data of the last 12 hours as the label data to complete the construction of the overall data set.

[0024] Dataset division: The overall dataset is divided. Data from 2015 to 2019 are selected as the training set, data from 2020 as the validation set, and data from 2021 as the test dataset for evaluation.

[0025] Step 2: Use a multi-scale large-kernel spatiotemporal prediction neural network to build a temperature spatiotemporal prediction model.

[0026] like Figure 2As shown, the multi-scale large-core spatiotemporal prediction neural network of the present invention as a whole follows the architecture of encoder-spatial-temporal translator-decoder. s The decoder also has N s The spatiotemporal translator is located between the encoder and decoder and contains N t MSLKA units. Given a batch of input data with a dimension of (B, T, C, H, W), B represents the number of batches of data, T represents the time length of the input data, C represents the number of channels, H and W represent the width and height of the grid data respectively. Before entering the encoder, the batch dimension and time dimension of the data are integrated together, and the input data shape becomes (B*T, C, H, W). The encoder does not pay attention to the time evolution between frames, but focuses on capturing the feature information of a single frame. Before entering the spatiotemporal translator, the encoder extracts spatial features and reshapes the data into data with dimensions of (B, T*C1, H1, W1). The spatiotemporal translator learns the changes between frames and the spatiotemporal evolution rules. Before entering the decoder, the spatiotemporal translator reshapes the data into (B*T, C1, H1, W1). The decoder also does not pay attention to time changes like the encoder. From a spatial perspective, the spatiotemporal evolution feature information learned from the spatiotemporal translator is integrated into the future prediction frame. The output data dimension is the same as the input data dimension, reshaped into (B, T, C, H, W). C1, H1 and W1 are the dimensional values ​​output by network transformation.

[0027] For example, in the embodiment of the present invention, the batch size is set to 8 and the number of channels is set to 1. The temperature data at 12 moments is used to predict the temperature data at 12 moments. The input data shape can be expressed as (8, 12, 1, 128, 128), that is, 8*12*1*128*128 data. The encoder extracts spatial features and reshapes the data into (B, T*C1, H1, W1) dimensional data. C1, H1, W1 can be adjusted according to actual usage. s is a multiple of 2 and greater than 2, N t is an integer greater than 1. In the embodiment of the present invention, N is set s is 4, N t is 10.

[0028] The space-time translator contains N tMSLKA units, each of which contains an MSSTA unit and a ConvFFN unit. A two-dimensional batch normalization batchnorm2d structure is set before the MSSTA unit and the ConvFFN unit. The role of batchnorm2d is to improve the generalization ability of the model, accelerate model training, and prevent problems such as gradient explosion. ConvFFN is a module for enhancing local features. It processes features using 3x3 convolution kernels to extract richer local information. Each MSLKA unit extracts spatiotemporal features from the input data through the MSSTA unit, and then combines the local features extracted by the ConvFFN unit to obtain the output features. The MSSTA unit sequentially contains a two-dimensional convolution layer Conv2D, a GELU layer, an MSSTA structure, and a two-dimensional convolution layer Conv2D. The input data is processed by the MSSTA unit and then added to the input data to obtain the output data of the MSSTA unit.

[0029] like Figure 3 As shown in Figure 1, the method of the present invention decomposes the MSSTA structure into multi-scale spatial attention and time evolution attention. Multi-scale spatial attention (MSSA) focuses on the changes in feature information from a multi-scale perspective. Figure 4 As shown in , the large kernel convolution is decomposed into three parts, namely multi-scale spatial local convolution (depth convolution), spatial expansion convolution (depth expansion convolution) and channel convolution (1×1 convolution). Figure 4 As shown, the MSSA processing in the MSSTA structure of the embodiment of the present invention is to divide the input data into 4 parts in the channel dimension, perform convolution operations with convolution kernels of 3*3, 5*5, 7*7 and 9*9 respectively, then splice the data after the convolution operation in the channel dimension, and then perform a full-channel convolution kernel of 11*11 and a deep dilation convolution operation with an expansion rate of 2, and then input a 1*1 two-dimensional convolution for convolution operation to complete multi-scale spatial attention processing on the input data. Multi-scale spatial local depth convolution is used to pay attention to multi-scale local context information, spatial depth dilation convolution is used to capture remote dependencies and pay attention to global feature information, and point convolution captures the relationship between channel dimensions, realizes information interaction in the channel dimension, and performs multi-scale feature fusion. The MSSA embodiment of the present invention divides the input data into 4 parts in the channel, the input data scale is (B, T*C1, H1, W1), the number of channels L = T*C1, and the scale of each part of the data after segmentation is (B, L / 4, H1, W1).

[0030] At the same time, in the MSSTA structure, the input data is processed with temporal evolution attention (TEA). TEA is used to capture the temporal evolution between frames, and the temporal evolution attention is divided into two parts: gradual temporal evolution attention (GTEA) and abrupt temporal evolution attention (ATEA). Gradual temporal evolution attention focuses on the small evolution of overall regional features over time, which helps to learn the temporal evolution law of overall features, while abrupt temporal evolution attention focuses on the large evolution of local regional features over time, which helps to learn the prominent transformation of local features. Figure 3 As shown in the figure, GTEA is implemented through an average pooling layer AvgPool, a one-dimensional convolution Conv1D and a Sigmoid activation function; ATEA is implemented through a maximum pooling layer MaxPool, a one-dimensional convolution Conv1D and a Sigmoid activation function. Finally, the input data, the results of MSSA processing, the results of GTEA processing and the results of ATEA processing are combined to obtain the final output of MSSTA.

[0031] The calculation of the MSSTA structure is expressed as follows:

[0032] Suppose input data X, first split X evenly into 4 parts X1, X2, X3, X4 = Split(X) in the channel dimension;

[0033] Perform convolution operations on the four divided parts of data respectively to obtain the input data:

[0034] Y1, Y2, Y3, Y4=DWConv1(X1), DWConv2(X2), DWConv3(X3), DWConv4(X4);

[0035] Data Y obtained after MSSA processing MSSA =Conv 1*1 (DW_D_Conv(Cat(Y1, Y2, Y3, Y4)));

[0036] GTEA processes the input data X to obtain the data Y GTEA =Sigmoid(Conv1D(AvgPool(X)));

[0037] ATEA processes input data X to obtain data Y ATEA =Sigmoid(Conv1D(MaxPool(X)));

[0038] The final data Y obtained from the MSSTA structure processing output is as follows:

[0039]

[0040] Among them, the input data data Data Y GTEA , Y ATEA All belong to Split represents a split operation; DWConv1, DWConv2, DWConv3, and DWConv4 are spatial local convolutions of four scales, which correspond to 3*3, 5*5, 7*7, and 9*9 convolution operations in the embodiment of the present invention; Cat represents a connection operation, DW_D_Conv represents a deep dilation convolution operation, and Conv 1*1 Represents a 1*1 convolution operation; AvgPool represents average pooling, MaxPool represents maximum pooling; Conv1D represents 1D convolution; Sigmoid is the Sigmoid activation function; represents the Kronecker product, and ⊙ represents the Hadamard product.

[0041] Step 3: Use the temperature dataset in step 1 to train the model.

[0042] Selection of loss function during training: The loss function used is the cross entropy loss function J, and the formula is as follows:

[0043]

[0044] Where n is the total grid data volume of the input training data sequence, p i represents the predicted temperature value at time i, y i is the temperature label value at time i. The loss function is used to evaluate the difference between the model prediction value and the true label, back-propagate and update the gradient, and optimize the model to make the prediction value close to the true value.

[0045] In the embodiment of the present invention, each sample is a temperature spatiotemporal sequence. If the input training sample set size is (B, T, C, H, W), then n = B*T*C*H*W; the prediction data p at time i is i and label data y i The data are all of size (B, T, C, H, W). The predicted value and label value of each grid at each moment are squared to obtain data of size (B, T, C, H, W). Then the n numbers are summed and averaged to obtain the final result J.

[0046] Training hyperparameters and optimization: During the training process, 16 video sequences were input per batch, and the Adam optimizer was used to adjust the model parameters. The learning rate was set to 0.001, and the CosineLRScheduler strategy was used to dynamically adjust the learning rate. In the test phase, 8 video sequences were input per batch, and the model was stopped after 30 epochs of training to evaluate its performance and generalization ability.

[0047] Step 4, input the currently collected temperature spatiotemporal data into the trained temperature spatiotemporal prediction model to predict the temperature of each region at the future time. The embodiment of the present invention first normalizes the currently collected temperature spatiotemporal data of the target region, such as standardizing the mean standard deviation of the collected data, and then inputs the trained temperature spatiotemporal prediction model to output the temperature of each grid in the target region at the future time. Similarly, the predicted output temperature is de-normalized to obtain the final temperature spatiotemporal prediction result.

[0048] The temperature spatiotemporal prediction model constructed by the present invention is compared with the existing temperature prediction model to prove the technical effect of the present invention. The MAE (mean absolute error), MSE (mean square error) and RMSE (root mean square error) indicators are selected to evaluate the prediction results. The smaller the value of the three indicators, the better the prediction effect. At the same time, because the data input to the model is standardized, the three indicators are used to evaluate the prediction results after the de-standardization operation is performed on the prediction results.

[0049] The experimental data selected the target area of ​​east longitude (115.7°-103.0°) and north latitude (36.7°-24.0°) for the whole year of 2021. The existing methods compared with the method of the present invention use the following neural networks to construct the spatiotemporal prediction model of temperature: ConvLSTM network, PredRNNv2 network, Unet network, SmaAt-UNet network, SimVP network, En-Van-De network. The comparison of the evaluation indicators of the prediction results is shown in Table 1.

[0050] Table 1 Comparison of the indicators predicted by the proposed method and the existing method on the same data set

[0051] Comparison Method MSE MAE RMSE ConvLSTM 1.583 0.892 1.258 PredRNNv2 1.298 0.798 1.139 Unet 1.714 0.926 1.309 SmaAt-UNet 1.452 0.854 1.205 SimVP 1.339 0.821 1.157 Method of the present invention 1.258 0.794 1.121

[0052] It can be seen from Table 1 that the temperature spatiotemporal prediction model constructed by the present invention achieves minimum values ​​in all three indicators compared with models constructed by other neural networks, indicating that the prediction effect is the best and the prediction result is more accurate.

[0053] Existing temperature spatiotemporal prediction models either lack the ability to capture large-scale global features or lack attention to multi-scale local information, and at the same time, the modeling ability of short-term mutations of local spatial information is insufficient. Based on these problems, the method of the present invention designs a temperature spatiotemporal series prediction model with an encoder-translator-decoder architecture. The core of the translator is the multi-scale spatiotemporal attention unit MSSTA, which divides the spatiotemporal evolution attention into two parts: spatial attention and temporal attention. The multi-scale spatial attention pays attention to spatial feature information from a multi-scale perspective, and the temporal evolution attention learns the changes of spatial features over time from the perspectives of gentle temporal evolution and rapid temporal evolution. Starting from the influence of geographical factors on temperature, the model conducts statistical analysis on the spatiotemporal temperature data set, reveals the multi-scale temperature characteristics formed by the influence of geographical factors on temperature, can better capture the complex evolution laws in spatiotemporal data, and improves the accuracy and stability of spatiotemporal series prediction.

[0054] Except for the technical features described in the specification, all of them are known technologies to those skilled in the art. The present invention omits the description of known components and known technologies to avoid redundancy and unnecessary limitation of the present invention. The implementation methods described in the above embodiments do not represent all implementation methods consistent with the present application. On the basis of the technical solution of the present invention, various modifications or variations that can be made by those skilled in the art without creative labor are still within the protection scope of the present invention.

Claims

1. A method for spatiotemporal temperature prediction based on a multi-scale large-core spatiotemporal prediction neural network, characterized in that: The steps include: Step 1: Collect ERA5-Land temperature data of the target area and construct a temperature dataset of the target area, including: normalizing the collected data, setting the forecast duration, and dividing the data into training set, validation set, and test set; Step 2, using a multi-scale large-core spatiotemporal prediction neural network to build a temperature spatiotemporal prediction model; The multi-scale large-kernel spatiotemporal prediction neural network is an encoder-spatial-temporal translator-decoder architecture, wherein: The encoder consists of N s The encoder is composed of encoding layers, each of which consists of a two-dimensional convolution layer, a group normalization layer, and a SiLU activation function. The encoder captures the spatial characteristics of a single frame of temperature grid data; Space-time translator by N t The network consists of MSLKA units; each MSLKA unit contains an MSSTA unit and a ConvFFN unit. A two-dimensional batch normalization structure is set before the MSSTA unit and the ConvFFN unit. The ConvFFN unit is used to enhance local features. The MSSTA unit contains a two-dimensional convolution layer, a GELU layer, an MSSTA structure and a two-dimensional convolution layer in sequence; the MSSTA structure is decomposed into two parts: multi-scale spatial attention MSST and time evolution attention TEA; the MSST part is decomposed into multi-scale spatial local depth convolution, spatial expansion convolution and channel convolution, and multi-scale spatial attention processing is performed on the data; the TEA part is divided into two parts: gentle time evolution attention GTEA and rapid time evolution attention ATEA. GTEA focuses on learning the evolution law of overall regional features over time, which is achieved through an average pooling layer, a one-dimensional convolution and a Sigmoid activation function; ATEA focuses on learning the evolution law of local regional features over time, which is achieved through a maximum pooling layer, a one-dimensional convolution and a Sigmoid activation function; The decoder consists of N s The decoder is composed of a two-dimensional convolution layer, an upsampling layer, a group normalization layer, and a SiLU activation function. The decoder outputs the temperature grid data prediction frame for the future time. N s is a multiple of 2 and greater than 2, N t is an integer greater than 1; Step 3, using the temperature data set constructed in step 1 to train the temperature spatiotemporal prediction model, and using the trained temperature spatiotemporal prediction model to predict the temperature at future moments using the temperature spatiotemporal data of the target area collected in real time.

2. The method according to claim 1, characterized in that In the step 2, the dimension of the input data of the temperature spatiotemporal prediction model is assumed to be (B, T, C, H, W), where B represents the number of batches of data, T represents the time length of the input data, C represents the number of channels, and H and W represent the width and height of each frame of temperature grid data, respectively; the encoder first converts the input data into data of dimension (B*T, C, H, W), then extracts spatial features, and outputs data of dimension (B, T*C1, H1, W1) to the spatiotemporal translator; the spatiotemporal translator learns the spatiotemporal evolution characteristics of each frame of temperature grid data, and outputs data of dimension (B*T, C1, H1, W1) to the decoder; the decoder outputs a predicted frame of temperature grid data for the future time from a spatial perspective according to the spatiotemporal evolution characteristics learned by the spatiotemporal translator, and outputs a prediction result of dimension (B, T, C, H, W); wherein C1, H1 and W1 are the dimensional values ​​of the network transformation output.

3. The method according to claim 1 or 2, characterized in that: In step 2, the multi-scale spatial attention part in the MSSTA structure performs the following operations on the input data in sequence: Multi-scale spatial local depth convolution: The input data is divided into four parts in the channel dimension, and convolution operations with convolution kernels of 3*3, 5*5, 7*7 and 9*9 are performed respectively. The convolution results are concatenated in the channel dimension as the input for the next step; Spatial dilated convolution: Perform a convolution operation on the input data with a convolution kernel of 11*11 and a dilation rate of 2; Channel convolution: Perform a 1*1 two-dimensional convolution on the output of the spatial dilation convolution.

4. The method according to claim 1 or 2, characterized in that: In step 2, the calculation of the MSSTA structure includes: assuming that the input data of the MSSTA structure is X, then: In the MSST part, X is evenly divided into four parts X1, X2, X3, and X4 in the channel dimension; then convolution operations of different scales are performed on the four divided parts of data to obtain data Y1, Y2, Y3, and Y4; the data after MSSA processing is represented as Y MSSA =Conv 1*1 (DW_D_Conv(Cat(Y1,Y2,Y3,Y4))); where Cat represents the connection operation, Dw_D_Conv represents the spatial expansion convolution operation, and Conv 1*1 Represents a 1*1 convolution operation; The GTEA part processes the input data X to obtain data T GTEA =Sigmoid(Conv1D(AvgPool(X))); ATEA processes input data X to obtain data Y ATEA =Sigmoid(Conv1D(MaxPool(X))); The final MSSTA structure processes the output data Y as follows: Among them, AvgPool represents average pooling, MaxPool represents maximum pooling; Conv1D represents 1D convolution; Sigmoid is the Sigmoid activation function; represents the Kronecker product, and ⊙ represents the Hadamard product.

5. The method according to claim 1 or 2, characterized in that: In step 3, the temperature spatiotemporal prediction model uses a cross entropy loss function during training, as follows: Among them, p i is the temperature grid forecast data at time i, y i is the temperature grid label data at time i. When the input data of the temperature spatiotemporal prediction model is (B, T, C, H, W), then n = B*T*C*H*W, p i and i are all (B, T, C, H, W) data; the above formula means taking the square of the difference between the predicted value and the label value of each grid at each moment to obtain data of (B, T, C, H, W) scale, and then summing and averaging all n numbers to obtain the cross entropy loss value J.

6. The method according to claim 1, characterized in that In the step 3, the temperature spatiotemporal data of the target area collected in real time is first normalized, then input into the trained temperature spatiotemporal prediction model, and the prediction results are denormalized to obtain the final temperature spatiotemporal prediction results of the target area.

Citation Information

Patent Citations

  • Offshore wind power prediction method and device based on multi-scale space-time diagram transformation network

    CN117114192A

  • Medical image segmentation model based on lightweight attention module and training method of model

    CN118212417A

  • Multivariate space-time prediction method and system for weather forecast

    CN118226551A

Cited By

  • Meteorological element space downscaling method based on time sequence characteristics

    CN121723123A