County-level sea wave revision forecasting method, device, medium and product
By using the TCN-KAN hybrid model, which combines a temporal convolutional network and a Kolmogorov-Arnold network, the problem of insufficient long-term feature representation in existing wave forecasting methods is solved, achieving high-precision correction of wave forecasts for county-level sea areas and improving forecast accuracy.
Patent Information
- Application Number
- CN202510912055.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-03
- Publication Date
- 2025-11-21
- Estimated Expiration
- 2045-07-03
AI Technical Summary
Existing intelligent correction methods for wave forecasts based on neural networks such as BPNN, CNN, and LSTM cannot effectively express the long-term variation characteristics of wave changes in terms of feature input, resulting in inaccurate wave forecasts for county-level sea areas.
The Temporal Convolutional Network (TCN) model was used to predict and initially correct wave forecast errors. Then, the Kolmogorov-Arnold Network (KAN) model was used for final correction, thus constructing a TCN-KAN hybrid model to improve forecast accuracy.
The TCN-KAN hybrid model significantly improved the accuracy of wave forecasts for county-level sea areas and reduced forecast errors, especially with a significant improvement in prediction accuracy over long forecast periods.
Smart Images

Figure CN120408331B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of marine forecasting, in particular to a county-level sea area wave revision forecasting method, device, medium and product. BACKGROUND
[0002] At present, the county-level sea area wave forecasting is based on large-area wave numerical forecasting products, and is combined with regional statistical methods for comprehensive forecasting. However, due to the uncertainty of physical parameters, initial condition errors, boundary condition errors and other reasons, the wave numerical forecasting often has many errors, which further affects the accuracy of the county-level sea area wave forecasting.
[0003] In order to improve the forecasting accuracy, the forecasting error revision is an effective method widely used. The traditional error revision methods include model output statistics (MOS), multi-model combination, empirical formula correction, etc. However, with the development of artificial intelligence technology, the intelligent revision method based on multi-source data fusion is becoming an important means to improve the accuracy of wave forecasting. The revision technology based on artificial intelligence has obvious advantages, including: it can not only dig the nonlinear correlation of wave data and break through the linear limitation, but also is good at processing grid data, comprehensive analysis of spatial distribution and capturing regional collaborative influence. However, the wave evolution process is influenced by nonlinear dynamic mechanism and multi-scale ocean-atmosphere interaction, and has significant spatio-temporal complexity characteristics. The existing wave forecasting intelligent revision methods based on BPNN (Backpropagation Neural Network), CNN (Convolutional Neural Networks), LSTM ((Long Short-Term Memory) and other neural networks and their combination models face the following technical bottlenecks in the implementation process: in the feature input, the single time series data cannot effectively express the long-term change characteristics of the wave change, resulting in inaccurate forecasting. SUMMARY
[0004] The purpose of the present application is to provide a county-level sea area wave revision forecasting method, device, medium and product to solve the problem of inaccurate wave forecasting described in the background art.
[0005] To achieve the above purpose, the present application provides the following solutions:
[0006] In a first aspect, the present application provides a county-level sea area wave revision forecasting method, comprising:
[0007] n feature vectors are obtained and sent to a pre-trained temporal convolutional network (TCN) model, so that the pre-trained TCN model outputs n county-level sea area wave forecast errors after the reporting time a, the n feature vectors being feature vectors corresponding to target meteorological elements in a predetermined range centered on the target county-level sea area for N forecast horizons after the reporting time a;
[0008] For each forecast time after the reporting time a, a difference between the forecast value of the county-level sea area wave and the forecast error of the county-level sea area wave is determined to obtain a preliminary revised forecast value of the county-level sea area wave;
[0009] The preliminary revised forecast value is sent to a pre-trained Kolmogorov-Arnold Network (KAN) model, so that the KAN model outputs the final revised forecast value of the n county-level sea area waves after the reporting time a.
[0010] Optionally, the target meteorological elements include any one of sea level pressure, first predetermined height zonal wind speed and second predetermined height meridional wind speed.
[0011] Optionally, the predetermined range includes a predetermined number of latitude and longitude grid regions centered on the target county-level sea area.
[0012] Optionally, the n feature vectors are generated by the following method:
[0013] For the target meteorological elements, meteorological forecast data for N forecast horizons after the reporting time a is obtained.
[0014] For the meteorological forecast data for the N forecast horizons, sliding is performed according to a window size W and a sliding step L, and a feature vector is generated for each sliding, to obtain the n feature vectors, the n= .
[0015] Optionally, before the method of obtaining the meteorological forecast data for the N forecast horizons after the reporting time a for the target meteorological elements, the method further includes the following method:
[0016] The N weather forecast data of the first predetermined number of latitude and longitude grid areas are sent to a principal component analysis (PCA) model, so that the PCA model performs dimension reduction processing on the N weather forecast data of the first predetermined number of latitude and longitude grid areas, to obtain N weather forecast data of a second predetermined number of latitude and longitude grid areas after dimension reduction, where the second predetermined number is less than the first predetermined number.
[0017] Optionally, the county-level sea area wave forecast error is a wave height forecast error of the county-level sea area wave.
[0018] Optionally, the first predetermined height is 10 meters, and the second predetermined height is 10 meters.
[0019] In a second aspect, the present application provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the method according to any one of the first aspect.
[0020] In a third aspect, the present application provides a computer readable storage medium having a computer program stored thereon, wherein the computer program is executable by a processor to implement the steps of the method according to any one of the first aspect.
[0021] In a fourth aspect, the present application provides a computer program product comprising a computer program, wherein the computer program is executable by a processor to implement the steps of the method according to any one of the first aspect.
[0022] According to the embodiments of the present application, the following technical effects are disclosed:
[0023] The county-level sea area wave revised forecast method provided by the embodiments of the present application predicts the county-level sea area wave forecast error through the TCN model; then performs preliminary revision on the forecast based on the forecast error to obtain a preliminary revised forecast value; and then sends the preliminary revised forecast value to the pre-trained KAN model, so that the KAN model outputs the final revised forecast value of the n county-level sea area waves after the reporting time a. That is, the TCN-KAN hybrid model is constructed to improve the accuracy of the county-level sea area wave forecast. BRIEF DESCRIPTION OF DRAWINGS
[0024] In order to more clearly illustrate the technical solutions of the embodiments of the present application or the prior art, the drawings needed in the embodiments will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.
[0025] Figure 1 An application environment diagram of a county-level sea area wave revision prediction method according to an embodiment of the present application;
[0026] Figure 2 A flowchart of a county-level sea area wave revision prediction method according to an embodiment of the present application;
[0027] Figure 3 A flowchart of an n-feature vector generation method according to an embodiment of the present application;
[0028] Figure 4 A reanalysis data and meteorological numerical prediction product grid diagram according to another embodiment of the present application;
[0029] Figure 5 A method diagram of n-feature vector generation according to another embodiment of the present application;
[0030] Figure 6 A TCN model construction and training diagram according to an embodiment of the present application;
[0031] Figure 7 A hybrid feature generation diagram according to another embodiment of the present application;
[0032] Figure 8 A KAN model construction and training diagram according to an embodiment of the present application;
[0033] Figure 9 A comparison diagram between a wave prediction result of the present application and a prediction result of another prediction method according to an embodiment of the present application;
[0034] Figure 10 Another comparison diagram between a wave prediction result of the present application and a prediction result of another prediction method according to an embodiment of the present application;
[0035] Figure 11 A county-level sea area wave prediction intelligent revision model training method processing flowchart according to an exemplary embodiment of the present application;
[0036] Figure 12 A structural diagram of a computer device according to an embodiment of the present application. DETAILED DESCRIPTION
[0037] With reference to the accompanying drawings, the technical solutions in the embodiments of the present application will be described clearly and completely. Obviously, the described embodiments are only a part of the embodiments of the present application, but not all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work fall within the scope of the present application.
[0038] The above purposes, features and advantages of the present application will be more apparent and understandable. The present application will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0039] The county sea wave correction forecasting method provided by the embodiments of the present application can be applied to an application environment as shown in Figure 1 The application environment includes a terminal and a server. The terminal communicates with the server through a network. A data storage system can store data required to be processed by the server. The data storage system can be separately arranged, integrated on the server, placed on a cloud or other server. The terminal can send the data to be processed to the server. After receiving the data to be processed, the server can first store the data to be processed, and then acquire the data to be processed from the storage location when it needs to be processed, or can perform the processing task while storing. In addition, in some embodiments, the county sea wave correction forecasting method can also be realized by the server or the terminal alone, such as the terminal directly performing the county sea wave correction forecasting on the data to be processed, or the server acquiring the data to be processed from the data storage system and performing the county sea wave correction forecasting on the data to be processed.
[0040] The terminal can be, but is not limited to, various desktop computers, notebook computers, smart phones, tablet computers, Internet of Things devices and portable wearable devices. The Internet of Things device can be a smart speaker, a smart television, a smart air conditioner, a smart vehicle device, etc. The portable wearable device can be a smart watch, a smart bracelet, a head-mounted device, etc. The server can be realized by an independent server or a server cluster composed of multiple servers, and can also be a cloud server.
[0041] In an exemplary embodiment, as shown in Figure 2 A county sea wave correction forecasting method is provided. The method is executed by a computer device, specifically by a terminal or a server, or by both the terminal and the server. In the embodiments of the present application, the method is applied to the server in Figure 1 The method includes the following steps 201 to 203.
[0042] Before the specific steps are described, it also needs to be pointed out in advance that the method is used to calculate the final corrected prediction value of the county sea wave using the numerical prediction data of a target meteorological element on a certain day, and for other target meteorological elements, the county sea wave correction prediction method provided in the application can also be used, the method is similar to the application, and the application will not be described one by one.
[0043] Step 201, obtaining n feature vectors and sending them to a pre-trained TCN model, so that the pre-trained TCN model outputs n county sea wave prediction errors after the reporting time a, and the n feature vectors are the feature vectors corresponding to the target meteorological elements in a predetermined range centered on the target county sea wave after N prediction times of the reporting time a.
[0044] Step 202, for each prediction time after the reporting time a, determining the difference between the prediction value of the county sea wave and the prediction error of the county sea wave to obtain the preliminary corrected prediction value of the county sea wave.
[0045] Step 203, sending the preliminary corrected prediction value to a pre-trained KAN model, so that the KAN model outputs the final corrected prediction value of the n county sea wave after the reporting time a.
[0046] It needs to be said here that the application uses the prediction data of the target meteorological element of the same county sea wave and the same time period to predict the prediction error of the county sea wave of the same county sea wave and the same time period.
[0047] The county sea wave correction prediction method provided in the embodiment of the application calculates the county sea wave prediction error through the TCN model, then preliminarily corrects the prediction based on the prediction error to obtain the preliminary corrected prediction value, and then sends the preliminary corrected prediction value to a pre-trained KAN model, so that the KAN model outputs the final corrected prediction value of the n county sea wave after the reporting time a. That is, the application constructs a TCN-KAN hybrid model to improve the accuracy of the county sea wave prediction.
[0048] Optionally, in another exemplary embodiment of the application, the target meteorological element includes any one of sea level pressure, first predetermined height zonal wind speed and second predetermined height meridional wind speed.
[0049] Among them, the first predetermined height and the second predetermined height are a predetermined height from the sea level, which can be an empirical value, for example, both are 10 meters high.
[0050] Of course, other target meteorological elements can also be included in actual use, which is not limited in the application.
[0051] Optionally, in another example embodiment of the present application, the predetermined range comprises a predetermined number of latitude-longitude grid regions centered on the target county-level sea area.
[0052] The present application takes the grid region as the weather feature background field information.
[0053] Optionally, referring to Figure 3 , in another example embodiment of the present application, the n feature vectors are obtained by the following steps 401 and 402:
[0054] Step 401, for the target weather element, obtain the weather forecast data of N forecast horizons after the reporting time a.
[0055] Step 402, for the weather forecast data of N forecast horizons, sliding according to the window size W and the sliding step L, generating a feature vector every time sliding, obtaining the n feature vectors.
[0056] Wherein, the n= .
[0057] When the window slides once, the weather forecast data corresponding to the window is a feature vector, that is, the weather forecast data included in the feature vector is the same as the window size.
[0058] Optionally, in another example embodiment of the present application, before step 401, the method further comprises the following step 501:
[0059] Step 501, send the N forecast horizon weather forecast data corresponding to the first predetermined number of latitude-longitude grid regions to the PCA model, so that the PCA model performs dimensionality reduction processing on the N forecast horizon weather forecast data, obtaining the N forecast horizon weather forecast data of the second predetermined number of latitude-longitude grid regions after dimensionality reduction, wherein the second predetermined number is less than the first predetermined number.
[0060] Wherein, the dimensionality reduction is to reduce the number of region grids.
[0061] Further, the process of using PCA for dimensionality reduction is as follows:
[0062] Step one, flatten the two-dimensional grid data into a one-dimensional array. For each weather element Q , flatten all the numerical prediction two-dimensional grid data of the reporting time and the forecast horizon into a one-dimensional array one by one, and stack them into the original matrix .
[0063] Step two, diagonalize the matrix. Let the covariance matrix of the matrix be and is a matrix composed of a group of bases by rows, let then is the data after base transformation. Let the covariance matrix of be then and the relationship is expressed as the following formula (1):
[0064] (1)
[0065] wherein, is the number of samples. Thus, the optimization target is converted to finding a matrix satisfying is a diagonal matrix, and the diagonal elements are arranged in descending order.
[0066] Step three, determine the feature vector after dimension reduction. Calculate the contribution ratio of the principal component variance of each meteorological element , when the sum of the contribution ratios of the first principal component variances of all meteorological elements is greater than 85%, the first diagonal elements are determined as the feature vectors of the meteorological element grid data after dimension reduction.
[0067] Exemplarily, for sea level pressure (MSLP), 10-meter zonal wind speed (U10) and 10-meter meridional wind speed (V10) elements, the regional background data extracted from each forecast time in each forecast file is flattened into a one-dimensional matrix with a length of 225, and then stacked into a two-dimensional matrix (m*119, 225) according to the forecast (wherein, m is the total number of numerical prediction files collected), through the PCA method, first, 4 characteristic values are extracted from the 225 dimensions, and the principal component variance contribution ratio of each characteristic value is calculated, as shown in the following Table 1.
[0068] Table 1 Principal component variance contribution ratio of each feature after PCA dimension reduction
[0069]
[0070] According to the requirement that the total characteristic principal component contribution ratio is above 85%, the first 4 characteristics are selected to form the feature vector after dimension reduction. Thus, the original sample of (m*119, 225) dimensions is reduced to (m*119, 4), which greatly reduces the data amount on the basis of retaining most of the characteristics.
[0071] The application collects county-level sea wave forecast data, county-level sea area neighborhood reanalysis data, and meteorological numerical prediction products. Specifically, the county-level sea wave forecast data can be wave height forecast data for county-level sea areas, the county-level sea area neighborhood reanalysis data is reanalysis data for wave height in the neighborhood of county-level sea areas, and the meteorological numerical prediction products include numerical prediction data for three elements of sea level pressure, 10-meter zonal wind speed, and 10-meter meridional wind speed.
[0072] Exemplarily, the county-level sea wave forecast data of N65 (Rongcheng East nearshore) sea area (latitude range 36.5°~37.5°N, longitude range 122.5°~123°E) from January 1, 2020 to July 31, 2024 is collected, with a forecast validity of 119 hours and a forecast time interval of 1 hour. The reanalysis data of the same period is downloaded from the European Center for Medium-Range Weather Forecasts (ECMWF), with a spatial resolution of 0.5° and a time resolution of 1 hour; in addition, the 00 o'clock (universal time) meteorological numerical prediction products of the same period from the Copernicus Atmosphere Monitoring Service (CAMS) are downloaded, including three elements of sea level pressure, 10-meter zonal wind speed, and 10-meter meridional wind speed, with a spatial resolution of 0.4°, a forecast validity of 119 hours, and a forecast time interval of 1 hour.
[0073] After collecting the data, the data needs to be preprocessed to facilitate the subsequent processing process, and the preprocessing process is as follows:
[0074] For reanalysis data, a partition statistical analysis method is used to extract reanalysis grid data with pixel centers located inside the county vector plane, and a spatial mapping relationship between county-level areas and reanalysis data is established, as shown in Figure 4 , which is a schematic diagram of a county area (vector plane), and Figure 4 , it can be calculated by using the arithmetic mean method, that is, the formula S→E(e) = (e1+e2+e3) / 3, to obtain the county-level sea wave reanalysis time series data, where S is the reanalysis time series data, which can also be denoted as E(e); e1~e9 are reanalysis grid data.
[0075] For meteorological numerical prediction products, a certain size of neighborhood range is defined, with the geometric center of the county sea area polygon as the center point, and the grid data of each element and each forecast validity in the specified neighborhood range in the meteorological numerical prediction products is extracted as the meteorological feature background field information.
[0076] Exemplarily, a partition statistical analysis method is used to establish a spatial mapping relationship between county-level sea areas and reanalysis data, and the grid of the corresponding reanalysis data for each county-level sea area is extracted. For meteorological numerical prediction products, the grid where N65 sea area is located is taken as the center, and 7 grids in each of the four directions are taken, which are defined as the regional range of the meteorological feature background field of the county-level sea area, that is, a square region of 15 rows and 15 columns centered on N65 sea area.
[0077] Optionally, see Figure 11 In the left half of this application, in another exemplary embodiment, the process of building, training, and correcting the TCN model is as follows:
[0078] Step 1: Organize a meteorological numerical forecast feature dataset. This involves targeting meteorological elements. The start time of the report In the The eigenvectors of the numerical weather prediction data at each time point after dimensionality reduction are denoted as follows: (As can be seen from the process of "PCA for dimensionality reduction") For length is (A one-dimensional array). Let the sliding time window length be W, the sliding step size be L, the number of meteorological elements be C, and the maximum forecast lead time of the numerical weather prediction product be N. See the sample organization diagram for details. Figure 5 As shown. When the time taken at the end of the sliding time window At that time, the corresponding value is shifted forward using the numerical weather prediction product from the previous day. The feature vectors of each time period are supplemented. Therefore, for each meteorological numerical forecast product, the generated dimension is ( ) eigenvectors.
[0079] After the feature data is organized, Meteorological elements In the forecast product file generated at forecast time 'a', the nth feature record is extracted, and the wave height forecast error (the wave forecast value for the county-level sea area minus the reanalysis data value) at the last forecast time of each feature record is extracted as tag data, denoted as . ,like Figure 5 middle The corresponding feature recording time is The tag matrix extracted from each forecast product file is denoted as... Its dimensions are ( 1).
[0080] Step 2: Data Normalization and Dataset Partitioning. The feature data and label data generated by the organization are normalized feature-by-feature using the extreme value normalization method, as shown in the following formulas (2) and (3):
[0081] (2)
[0082] (3)
[0083] In the formula, The first of the above feature data i One characteristic, ; for The maximum value in the sample space. for The minimum value in the sample space; These are the normalized feature data; For the above label data, The maximum value in the label space. The minimum value in the label space; The data is standardized label data. Then, a subset of data from the last continuous period of the normalized dataset is extracted as the test set, and its preceding subset is randomly divided into the training set and the validation set according to a certain ratio (e.g., 8:2) to form the final sample dataset.
[0084] Step 3: TCN Model Construction. The network structure and parameters of the TCN model are initially determined. The training set data is input into the TCN model for iterative training, and the training results are validated using the validation set data. The network structure of the TCN model is set as follows: Figure 6 As shown:
[0085] Figure 6 In the input data, feature data and label data are included, with dimensions of ( ). None, W, CxK )and( None, 1 The TCN receives input data and has three hidden layers with channels H1, H2, and H3, connected by residual connections. The hidden layers use dilated convolution, meaning that the higher the layer, the more "holes" in the convolution window and the larger the dilated convolution coefficient d. The output data dimension of hidden layer H3 is (…). None, W, H3 ), flatten it into ( None, WxH3 The input is a fully connected (FCN) layer; after the FCN layer is processed, the model result is output after passing through an activation function, which is the wave forecast error for county-level sea areas. .
[0086] Step 4: TCN Model Training. Model parameters (such as the number of nodes in hidden layers H1 to H3, dilated convolution coefficients, kernel size, etc.) are tuned using a grid search method. This involves enumerating various parameter combinations and selecting the combination that minimizes the prediction error after correction on the validation set. The activation function is ReLU, and the loss function is Mean Squared Error (MSE). The number of training epochs is determined. After training, the model structure, optimal parameters, and weight data are saved to a file.
[0087] Step 5: Initial Correction of Waves in County-Level Sea Areas. Run the optimal model obtained from the above training, inputting the training set, validation set, and test set. Calculate the prediction error value for each feature record in the sample dataset. Subtract the prediction error value from the prediction value at the corresponding time to obtain the initial correction value, denoted as [missing value]. . In the middle, a is the start time of the forecast product, . With the same start time of the forecast product, a total of corrected values are calculated, and the time interval between adjacent corrected values is .
[0088] Exemplarily:
[0089] For each meteorological numerical forecast file, by the method of sliding window, the sliding step is set to 1, the sliding window length is 24 (for time less than 24 hours, the forecast data of the corresponding time in the previous day numerical forecast file is supplemented), and the dimension-reduced feature vector of each element is extracted every 24 hours. In this way, each numerical forecast file extracts a matrix with dimensions (119, 24, 12). After extraction, stack according to the first dimension to generate feature data with dimensions (119*m, 24, 12). At the same time, the effective wave height at the end of each sliding window is extracted and organized as label data. Then, independently standardize the extreme values according to the third dimension of the feature data and the label data in order to generate a normalized data set. The data from October 1, 2023 to July 31, 2024 is used as the test set, and the data between January 1, 2020 and September 30, 2023 is randomly divided into training set and validation set in the ratio of 8:2. Build a TCN model with input dimensions (None, 24, 12), determine the output channel numbers H1, H2 and H3 of the three hidden layers of TCN as 128, 32 and 8 respectively through grid search algorithm, then pass through a fully connected layer, and output the county-level sea area wave forecast error with dimensions (None, 1). During model training, the maximum number of iterations is 1000, the minimum batch size is 400, the learning rate is 0.0001, the optimizer selects Adam algorithm, the activation function uses ReLU, the loss function uses MSE, and no early stopping mechanism is set. After processing the training set, input the model for training, and use the validation set to verify the training results until the training is completed, and save the optimal model structure, parameters and weights. After training is completed, read and run the model file to predict the error of all feature records in the training set, validation set and test set, and save the preliminary error prediction results in the order of numerical forecast start time and forecast validity, with dimensions (m, 119).
[0090] Optionally, referring to Figure 11 the right half, in another exemplary embodiment of the present application, the process of KAN model construction, training and correction is as follows:
[0091] Step one, organize the county-level sea area wave time series data set after preliminary correction. For each meteorological numerical forecast file, organize the One correction value , p The total number of meteorological numerical forecast products, organized as follows: Figure 7 As shown:
[0092] Therefore, the dimension of the feature data is (None, 1, ...). ), denoted as XL The label data represents the final multi-step correction values, denoted as... ,in Between 1 and N At any moment ( (To correct the time interval of the forecast), such as correcting it every 3 hours. Therefore, the dimension of the label data is (None, ...). ).
[0093] Step 2: Data normalization and dataset partitioning, using the same methods as in "TCN model construction, training and correction process", to generate training set, validation set and test set.
[0094] Step 3: KAN Model Construction. The network structure and parameters of the KAN model are initially determined. The training set data is input into the KAN model for iterative training, and the training results are validated using the validation set data. The network structure of the KAN model is set as follows: Figure 8 As shown:
[0095] Figure 8 The input layer of the model is ( ) dimensional feature data XL, the output layer is ( The dimension label data is YL. KAN uses a 3-layer network structure design, with dimensions H1, H2, and H3 in each layer. The KAN model directly outputs the corrected data, with dimensions ( ).
[0096] Step 4: Model training, parameter tuning, and training methods are the same as in "TCN model construction, training, and correction process," generating model structure, parameter, and weight files.
[0097] Step 5: Output Correction Results. Run the optimal model obtained from the above training, input the test set, and calculate the correction value for each feature record in the test set, denoted as . . In the table, 'a' represents the start time of the forecast product, and 'n' represents the forecast lead time of the model in this application. .
[0098] Exemplarily, the initial time of each numerical prediction file is taken as the initial time of the sample data of the model, and for the 119 error prediction values in the above-mentioned "preliminary error prediction result" within the corresponding time limit, the preliminary revised value is obtained by subtracting the error prediction value from the county-level sea area wave prediction value, and the feature data with a dimension of (None, 119) is generated. The 3-hour significant wave height reanalysis data from the 3rd hour to the 117th hour after the initial time of the model is selected as the label data. The generated feature data and label data are normalized by using the extreme value standardization method, and then the sample data set is divided into a training set, a validation set and a test set in the same way as the above-mentioned "preliminary error prediction result". The KAN model is constructed, the input dimension is (None, 119), the three hidden layer dimensions H1, H2 and H3 are determined to be 128, 32 and 8 respectively by using the grid search algorithm, the third-order B-spline activation function is used to connect different layers, the grid size of the B-spline interval is defined as 5, and the output dimension is (None, 39). During the model training process, the maximum number of iterations is 1000, the minimum batch size is 100, the learning rate is 0.0001, the optimizer selects the Adam algorithm, the loss function uses MSE, and no early stopping mechanism is set. The training set data is input into the model for training, and the training result is verified by using the validation set until the training is completed, and the optimal model structure, parameters and weights are saved. After the training is completed, the model file is read and run, the feature data in the test set is input into the model, the output result is obtained and is de-normalized to obtain the final revised value.
[0099] Alternatively, for the revised results of the above-mentioned two models, the following method can be used for evaluation:
[0100] The root mean square error (English full name: Root Mean Square Error, English abbreviation: RMSE) and the mean absolute error (English full name: Mean Absolute Error, English abbreviation: MAE) indexes are used to evaluate the model results of the present application, and the evaluation is divided according to different prediction time limits, and the calculation formulas are as follows formulas (4) and (5):
[0101] (4)
[0102] (5)
[0103] In the formula, n is the total number of samples in the test set of the model, is the wave height reanalysis data value of the sample, is the wave height reanalysis data value of the sample, i is the wave height reanalysis data value of the sample, is the wave height reanalysis data value of the sample, i is the wave height reanalysis data value of the sample.
[0104] The RMSE and MAE indicators are used to test and evaluate the model. Within the 119-hour prediction period, the 6-hour RMSE and MAE indicators between the revised and un-revised model and the reanalysis data are calculated, and the results are shown in the following table. According to the table, the prediction results of the revised model are more accurate than those of the un-revised model at each time period. The average RMSE error of the revised model is reduced by 29.61% ; The average MAE error of the revised model is reduced by 34.66% 。 The results show that the accuracy of the county-level sea wave prediction results after the revision by the county-level sea wave intelligent revision method of the application has been greatly improved.
[0105] Table 2 Comparison of prediction errors between the model of the application and existing inventions
[0106]
[0107] Selecting two cold air processes on November 4, 2023 and December 13, 2023 as sample periods, the differences in accuracy of county-level sea wave prediction between the revised and un-revised models of the application are shown in Figure 9 、 Figure 10 the prediction curve graph. During these two cold air processes, large waves (significant wave height > 3m) occurred in the N65 sea area. As shown in the graph, after revision by the model of the application, the prediction results of the two cold air processes are closer to the true values, and the extreme value prediction is more accurate. According to statistics, during the cold air process on November 4, 2023, the RMSE of the prediction results of the revised and un-revised models of the application were 0.28m and 0.37m respectively; during the cold air process on December 13, 2023, the RMSE of the prediction results of the revised and un-revised models of the application were 0.19m and 0.40m respectively. Before revision, the significant wave height prediction value of the county-level sea wave numerical prediction within the 119-hour prediction period was systematically overestimated, especially in the maximum significant wave height area, which was significantly higher than the true value; after revision by the method of the application, the process curve of the significant wave height prediction sequence and the true value was significantly improved. After revision by the model of the application, the overall prediction error (RMSE) of the prediction results in the two cold air processes was reduced by 24.3% and 52.5% respectively compared with the un-revised model.
[0108] In summary, the application proposes a county-level sea wave intelligent correction forecasting method. After the model correction, the accuracy of the county-level sea wave forecasting result is effectively improved. The application adopts a "two-step" modeling idea, processes the meteorological background field feature data by PCA method, constructs a sample data set by using the same data organization method, uses TCN model for preliminary correction, uses KAN model for final correction, and constructs a PCA-TCN-KAN hybrid model. The example proves that the application model can effectively correct the long-time sea wave forecast and improve the prediction accuracy. Within 119 hours, the RMSE of the original county-level sea wave forecast can be reduced by more than 20%, and the fitting ability in disaster process can be better.
[0109] In addition, the programming language used in the application is Python 3.9.13, the machine learning framework is Pytorch1.12.1, and the operating system is Windows Server 2019 Standard. The server hardware conditions used in the application are as follows: Intel(R) Xeon(R) Gold 6226 CPU @ 2.70GHz, 256GB memory.
[0110] The background technology mentioned in the application exists different degrees of data redundancy in multi-source spatio-temporal numerical prediction data, and there is a problem of time sequence mismatch in data organization; second, the gradient stability is insufficient, it is difficult to effectively capture long-distance time sequence dependence relationship, and then affect the convergence of model training, and lack of powerful function approximation ability, which may cause model underfitting or similar mean regression phenomenon. The above problems jointly restrict the further improvement of the accuracy of county-level sea wave artificial intelligence correction result, and make its development face a bottleneck.
[0111] From the content of the specific embodiments of the application, the application proposes a TCN and KAN county-level sea wave intelligent correction forecasting model for the problems mentioned in the background technology. The model takes multi-source meteorological and hydrological spatio-temporal sequences as input, first performs data dimensionality reduction by PCA to eliminate redundant information, and organizes spatio-temporal sequence feature samples based on meteorological numerical prediction products; then uses the hollow convolution structure of TCN to capture the long-distance time sequence dependence characteristics of sea wave evolution; finally, through the general function approximation characteristics of KAN model, the high-precision mapping of nonlinear dynamic process is realized, thereby constructing a county-level sea wave intelligent correction forecasting system integrating multi-source data features. While maintaining the computing efficiency, the method successfully breaks through the bottleneck of the existing county-level sea wave prediction intelligent correction method by virtue of the more superior model architecture, and greatly improves its accuracy.
[0112] The application provides a county-level sea area sea wave intelligent correction prediction method, aiming to solve the following two problems and improve the accuracy of county-level sea area sea wave prediction. First, the characteristics of the meteorological background field are introduced and dimension reduction processing is performed to solve the problems of time-consuming model training and convergence difficulty. The meteorological numerical prediction product is regional grid data, which contains spatial and temporal background information and a large amount of redundant information. Directly inputting into the intelligent model will cause problems such as too large data volume, time-consuming training and convergence difficulty, therefore, the application performs dimension reduction processing on the original meteorological numerical prediction data through PCA, retains the main characteristics of the regional background field, reduces the model input data volume, reduces the requirements of model training on computer hardware conditions, improves the model training speed and convergence. Secondly, a two-step correction method combining TCN and KAN is adopted to solve the problems of weak long sequence processing ability and function representation ability of the existing model. TCN flexibly controls the receptive field of the model by stacking convolution layers, adjusting the size of the convolution kernel and using a hollow convolution. Through an exponential growth of the hollow factor, TCN uses fewer layers to obtain a larger receptive field, thereby efficiently capturing long-term dependencies. At the same time, KAN has a learnable activation function (such as a spline function) located at the edge of the neural network, which has stronger function representation ability than the network with a fixed activation function, therefore, in the modeling task related to the physical process, KAN can achieve higher accuracy with fewer parameters. TCN and KAN are combined to model, TCN is used as a powerful spatiotemporal sequence feature extractor, then the features extracted by TCN and the time series observation data are input into KAN for final mapping to obtain more accurate function fitting, thereby better solving the gradient vanishing / explosion problem in the training process caused by the long-time dependence and multi-scale characteristics of the data itself, and better capturing the long-distance time sequence dependence characteristics of the sea wave evolution.
[0113] The application adopts a "two-step" modeling strategy: first, the PCA model is used to perform dimension reduction processing on the original meteorological numerical prediction data, the dimension-reduced data is organized into meteorological spatiotemporal feature samples, and the TCN model is used for preliminary correction; second, the TCN model preliminary correction result is used as input data, and the KAN model is used for final correction of the multi-step county-level sea area sea wave prediction.
[0114] In an exemplary embodiment, a computer device, which can be a server or a terminal, is provided, and the internal structure diagram thereof can be seen from Figure 12As shown in the figure. The computer device includes a processor, a memory, an input / output interface (I / O for short) and a communication interface. Among them, the processor, the memory and the input / output interface are connected through the system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capability. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store the county-level sea area wave correction forecast related data. The input / output interface of the computer device is used to exchange information between the processor and external devices. The communication interface of the computer device is used to communicate with the terminal outside through network connection. The computer program is executed by the processor, and a county-level sea area wave correction forecast method can be realized.
[0115] Those skilled in the art can understand that, Figure 12 The structure shown in the figure is only a block diagram of part of the structure related to the scheme of the present application, and does not constitute a limitation on the computer device to which the scheme of the present application is applied. The specific computer device can include more or fewer components than those shown in the figure, or combine certain components, or have a different component arrangement.
[0116] In an exemplary embodiment, a computer device is also provided, including a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the steps in each of the above method embodiments.
[0117] In an exemplary embodiment, a computer readable storage medium is provided, storing a computer program, which is executed by a processor to implement the steps in each of the above method embodiments.
[0118] In an exemplary embodiment, a computer program product is provided, including a computer program, which is executed by a processor to implement the steps in each of the above method embodiments.
[0119] It should be noted that the user information (including but not limited to user equipment information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in the present application are all information and data authorized by the user or authorized by all parties, and the collection, use and processing of related data need to comply with relevant regulations.
[0120] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer readable storage medium, and when the computer program is executed, the processes of the above-mentioned embodiments of the methods can be included. In the embodiments provided in the present application, any reference to the memory, database or other medium can include at least one of the non-volatile and volatile memories. The non-volatile memory can include read-only memory (Read-Only Memory, ROM), magnetic tape, floppy disk, flash memory, optical storage, high-density embedded non-volatile memory, resistive memory (ReRAM), magnetoresistive random access memory (Magnetoresistive Random Access Memory, MRAM), ferroelectric memory (Ferroelectric Random Access Memory, FRAM), phase change memory (Phase Change Memory, PCM), graphene memory, etc. The volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory, etc. As an illustration but not limitation, the RAM can be in various forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), etc.
[0121] The database involved in the embodiments provided in the present application can include at least one of a relational database and a non-relational database. The non-relational database can include a distributed database based on a blockchain, etc., without being limited thereto. The processor involved in the embodiments provided in the present application can be a general processor, a central processor, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., without being limited thereto.
[0122] The technical features of the above embodiments can be combined arbitrarily. In order to make the description simple, all possible combinations of the technical features in the above embodiments are not described, but as long as the combinations of the technical features do not exist contradictory, they should be considered as the scope of the present application.
[0123] The principles and implementation modes of the present application are described by applying specific examples. The above description of the embodiments is only used to help understand the method and its core idea of the present application; at the same time, for those skilled in the art, according to the idea of the present application, the specific implementation mode and application range will be changed. In conclusion, the content of the present application should not be understood as a limitation.
Claims
1. A method for a county-level sea wave correction forecast, characterized in that, The method comprises the following steps: n feature vectors are obtained and sent to a pre-trained TCN model, so that the pre-trained TCN model outputs n county-level sea area wave forecast errors after the reporting time a, and the n feature vectors are feature vectors corresponding to target meteorological elements in a predetermined range centered on a target county-level sea area for N forecast horizons after the reporting time a; for each forecast time after the reporting time a, the difference between the forecast value of the county-level sea wave and the forecast error of the county-level sea wave is determined to obtain a preliminary revised forecast value of the county-level sea wave; the preliminary revised forecast value is sent to a pre-trained KAN model, so that the KAN model outputs the final revised forecast value of the n county-level sea waves after the reporting time a; wherein the training process of the pre-trained TCN model comprises: sending N forecast horizons of meteorological forecast data corresponding to a first predetermined number of latitude and longitude grid regions to a PCA model, so that the PCA model performs dimensionality reduction processing on the N forecast horizons of meteorological forecast data to obtain N forecast horizons of meteorological forecast data of the second predetermined number of latitude and longitude grid regions after dimensionality reduction, and record them as feature vectors; wherein the second predetermined number is less than the first predetermined number; calculate the county wave forecast error based on the county wave reanalysis data; determine the county wave forecast error as the label data of the county-level sea wave forecast error; determine the feature vector as the feature data; input the label data and the feature data as training data into the TCN model to be trained for training.
2. The method of claim 1, wherein the method is characterized by, The target meteorological elements include any one of sea level pressure, first predetermined height zonal wind speed and second predetermined height meridional wind speed.
3. The method of claim 1, wherein the method is characterized by, The predetermined range includes a predetermined number of latitude and longitude grid regions centered on the target county-level sea area.
4. The county sea wave revision forecasting method according to claim 1, characterized in that, The n feature vectors are generated by the following method: for the target meteorological elements, obtain N forecast horizons of meteorological forecast data after the reporting time a; For the N weather forecast data of the forecast period, sliding is performed according to the window size W and the sliding step L, and a feature vector is generated every time the sliding is performed, so as to obtain the n feature vectors, and the n .
5. The county sea wave revision forecasting method according to claim 1, characterized in that, The county-level sea wave forecast error is the wave height forecast error of the county-level sea wave.
6. The county sea wave revision forecasting method according to claim 2, characterized in that, The first predetermined height is 10 meters, and the second predetermined height is 10 meters.
7. A computer device comprising: The memory, the processor and the computer program stored in the memory and executable on the processor, characterized in that the processor executes the computer program to implement the county-level sea wave revised forecast method of any one of claims 1-6.
8. A computer readable storage medium having stored thereon a computer program, characterized in that, The computer program is executed by the processor to implement the county-level sea wave revised forecast method of any one of claims 1-6.
9. A computer program product comprising a computer program, characterized in that, The computer program is executed by the processor to implement the county-level sea wave revised forecast method of any one of claims 1-6.
Citation Information
Patent Citations
Ocean wave forecasting algorithm fusing random search and mixed decomposition error correction
CN114912077A
Method, medium and system for constructing digital twinning system for near-shore overtopping disasters
CN119048706A