Intelligent and fast construction method of sea wave spectrum based on parameter spectrum constraint and computer equipment

By using a hybrid model based on parametric spectral constraints, combined with the Jonswap spectral constraint module and spectral energy compensation module, the peak factor of the wave spectrum is dynamically predicted and the energy distribution is compensated. This solves the problems of high computational cost, insufficient real-time performance, and insufficient accuracy in wave spectrum construction, and achieves efficient and accurate wave spectrum forecasting.

CN121168530BActive Publication Date: 2026-01-27QINGDAO INNOVATION & DEV CENT OF HARBIN ENG UNIV +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511704946.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-11-20
Publication Date
2026-01-27
Estimated Expiration
2045-11-20

AI Technical Summary

Technical Problem

Existing wave spectrum construction methods suffer from high computational overhead, insufficient real-time performance, inadequate accuracy and generalization ability, and lack of physical interpretability, leading to inaccurate and unreasonable forecast results.

Method used

A hybrid model based on parametric spectral constraints is adopted, combining the Jonswap spectral constraint module and the spectral energy compensation module. The wave spectrum is constructed by dynamically predicting the spectral peak factor and compensating for the wave spectral energy distribution through a convolutional neural network.

Benefits of technology

It improves the accuracy and efficiency of wave spectrum construction, enhances physical interpretability and generalization ability, and significantly improves the accuracy and rationality of forecasts.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121168530B_ABST
    Figure CN121168530B_ABST
Patent Text Reader

Abstract

The application belongs to the technical field of sea wave spectrum construction, and discloses a sea wave spectrum intelligent rapid construction method based on parameter spectrum constraint and computer equipment, which comprises a data set construction step, weather and wave element and sea wave spectrum data of a target sea area are collected, and a mask M is created to identify sea and land areas during preprocessing; a model construction and training step, a hybrid model comprising a Jonswap spectrum constraint module, a spectrum energy compensation module and a fusion module is constructed, the model is trained using the data set, and the mask M is used during training to make the loss function only based on marine area data calculation; a spectrum construction step, inputting to-be-predicted data into the trained model, and outputting sea wave spectrum. The application dynamically outputs a spectrum peak factor through deep learning, overcomes the limitation of insufficient accuracy of a traditional fixed parameter Jonswap spectrum under different sea conditions, maintains the efficiency of the deep learning method, and can significantly improve the physical rationality, interpretability and prediction accuracy of sea wave spectrum prediction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of wave spectrum construction technology, and particularly relates to a method and computer equipment for intelligent and rapid construction of wave spectra based on parametric spectrum constraints. Background Technology

[0002] Ocean waves are a crucial component of the marine dynamic environment, and their spatiotemporal evolution significantly impacts maritime navigation safety, nearshore disaster prevention and mitigation, and the stability of marine engineering facilities. Compared to single macroscopic parameters such as significant significant wave height and mean period, the wave spectrum provides a more comprehensive and detailed description of the distribution of wave energy across different frequencies and directions. It not only provides average wave state information but also reveals the fine structure of wave energy, such as wave components at different frequencies and their energy contributions, as well as wave propagation direction characteristics. This detailed physical information is essential for wave-resistant design of marine engineering structures such as offshore platforms and port facilities, optimization of maritime shipping routes, coastal erosion protection, and risk assessment of marine disasters such as tsunamis and storm surges. Therefore, the accurate construction and forecasting of the wave spectrum provides more precise and comprehensive physical evidence for decision-making in related fields, and is of great significance.

[0003] Currently, wave spectrum forecasting primarily relies on physics-based numerical modeling methods, such as WAVEWATCH III and SWAN. These methods simulate the evolution of the wave field by establishing and numerically solving the governing equations for physical processes such as wave generation, nonlinear interactions, wave propagation, and dissipation. This approach excels in explaining physical mechanisms. However, in wave spectrum construction, these methods face challenges such as high computational cost and insufficient real-time performance, especially in scenarios requiring rapid response, where their time consumption becomes even more pronounced.

[0004] To address the issue of insufficient real-time performance, two common solutions can be summarized in the field of wave spectrum construction:

[0005] (1) Constructing wave spectrum using physical empirical formulas. This type of method calculates the energy distribution of wave spectrum by substituting wave elements such as significant wave height and mean period, as well as wave spectrum parameters such as peak factor, into existing physical wave spectrum formulas such as the Jonswap spectrum formula.

[0006] (2) Another approach is the existing data-driven deep learning method, which directly constructs the wave spectrum based on the input meteorological and wave conditions. This type of method uses a deep learning model to directly establish the mapping relationship between the input meteorological and wave elements and the output wave spectrum energy.

[0007] However, existing wave spectrum construction methods have the following problems:

[0008] (1) The description of wave spectrum morphology will lack accuracy: Although physical empirical formulas such as wave spectrum can provide reasonable spectral shapes under specific sea conditions, these formulas usually rely on fixed or a few preset parameters. Taking the Jonswap spectrum as an example, the peak factor γ is used to describe the sharpness of the spectral peak. It is a shape parameter used to adjust the shape of the spectral lines to better match the actual sea conditions. If this parameter is set to the default value instead of dynamic prediction, the model will have difficulty adapting to the complex and varied wave morphology in the real ocean environment. Different meteorological wave conditions such as wind field, water depth, and bottom shape will cause significant changes in the shape and energy distribution of the wave spectrum, and a fixed γ value cannot capture these changes. Therefore, when facing sea conditions that have not been preset or are significantly different from the default parameter conditions, this method will lack accuracy in describing the wave spectrum morphology, and the generalization ability of the forecast results will be severely limited, making it difficult to truly reflect the physical characteristics of the waves.

[0009] (2) Lack of physical interpretability: Existing deep learning methods, when directly constructing wave spectra, mainly focus on establishing a direct data mapping relationship between input meteorological wave conditions and output wave spectrum energy. This "black box" operation ignores the integration of the physical generation mechanism and morphological characteristics of wave spectra into the model. This means that the model is difficult to explain how wave spectra are formed and evolved under different meteorological conditions, and it is also difficult to deeply understand the specific impact of specific meteorological factors on wave spectrum morphology, thus limiting the analysis and improvement of forecast results. Due to the lack of constraints on the physics of wave spectra, the wave spectrum energy directly output by the data-driven model may exhibit overly flat spectrum patterns and multiple unreasonable peaks in some cases, which does not conform to actual physical laws and seriously affects the accuracy and usability of forecast results.

[0010] Based on the above analysis, the problems and shortcomings of the existing technology are as follows:

[0011] (1) In the construction of wave spectrum, traditional numerical modeling methods based on physical mechanisms have problems such as large computational overhead and insufficient real-time performance; especially in scenarios that require fast response, the time consumption is even longer.

[0012] (2) Existing wave spectrum construction methods lack accuracy in describing wave spectrum morphology, limit the generalization ability of forecast results, and make it difficult to truly reflect the physical characteristics of waves; lacking physical interpretability, the output wave spectrum energy does not conform to actual physical laws, which seriously affects the accuracy and usability of forecast results. Summary of the Invention

[0013] To overcome the problems existing in related technologies, the present invention discloses an intelligent and rapid method and computer device for constructing ocean wave spectra based on parametric spectrum constraints. The technical solution is as follows:

[0014] This invention is implemented as follows: a method for intelligent and rapid construction of ocean wave spectra based on parametric spectrum constraints, comprising the following steps:

[0015] S1. Dataset Construction: Collect meteorological and wave element data of the target sea area and the corresponding sea wave spectrum data, and construct the training dataset after preprocessing; the preprocessing includes creating a mask M to identify the ocean area and the land area.

[0016] S2. Hybrid Model Construction and Training: Construct a parameter spectrum-constrained hybrid model, which includes:

[0017] The Jonswap spectral constraint module is used to dynamically predict the spectral peak factor based on the meteorological and wave element data, and calculate the initial wave spectral energy distribution by combining the significant wave height and average period using the Jonswap spectral formula.

[0018] The spectral energy compensation module is used to output spectral energy compensation values ​​based on the meteorological and wave element data.

[0019] The fusion module is used to fuse the initial wave spectrum energy distribution with the spectrum energy compensation value and output the final wave spectrum energy distribution.

[0020] The parameter spectrum constrained hybrid model is trained using the training dataset. During the training process, the mask M is used to filter land area data so that the loss function is calculated only based on ocean area data.

[0021] S3. Wave spectrum construction: Input the meteorological and wave element data of the target sea area to be predicted into the trained hybrid model, and output the wave spectrum of the sea area.

[0022] In step S1, the preprocessing further includes: replacing null and zero values ​​in the input data and wave spectrum data with preset constants. .

[0023] In step S2, the Jonswap spectral constraint module, based on a convolutional neural network, extracts distribution features from the significant wave height, average period, and sea surface wind speed of the input target sea area, learns the correlation between these features and the regional spectral peak factor, and predicts the key physical parameter of the Jonswap spectrum, the spectral peak factor. Combining the extracted significant wave height and average period, the wave spectral energy distribution is calculated using a preset Jonswap spectral formula. ;

[0024] ;

[0025] ;

[0026] ;

[0027] ;

[0028] In the formula, The wave spectrum energy distribution output by the Jonswap spectral constraint module. For input data, For frequency, The normalization coefficient is... For the effective wave height, The peak average period, Peak frequency, It is a natural exponential function. For the average period, The Jonswap spectral constraint module is used for parametric spectral constraint hybrid models. Calculate parameters for the Jonswap spectral constraint module. For shape parameters.

[0029] In step S2, the spectral energy compensation module is implemented through a neural network to learn and output the complex wave spectral energy details that the Jonswap spectral formula fails to describe.

[0030] In step S2, the spectral energy compensation module learns the energy distribution difference between the Jonswap empirical spectral type and the actual wave spectrum based on the input meteorological wave data, and outputs as... Energy compensation is performed, and the output results from the Jonswap spectral constraint module are fused and spliced ​​to finally output the wave spectrum energy distribution. ;

[0031] ;

[0032] In the formula, Output the wave spectrum energy distribution for the model. For the model spectral energy compensation module, These are the parameters calculated for the spectral energy compensation module.

[0033] In step S2, the fusion module obtains the final wave spectrum energy distribution by performing a tensor addition operation between the initial wave spectrum energy distribution and the spectrum energy compensation value.

[0034] In step S2, during the training of the hybrid model, the predicted wave spectrum is calculated by forward propagation, and the mean square error between the predicted wave spectrum and the actual wave spectrum is used as the loss function; the gradient is calculated by backpropagation, and the model weights are updated; the model is evaluated on the validation dataset, and the convergence of the model is monitored.

[0035] The method also includes model evaluation, comparing the wave spectrum constructed by the hybrid model with the wave spectra constructed by the pure data-driven model and the fixed-parameter Jonswap spectral model, using mean squared error (MSE), mean absolute error (MAE), and correlation coefficient (R²). 2 Error assessment is performed using at least one of the indicators.

[0036] Another object of the present invention is to provide a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements the intelligent and rapid wave spectrum construction method based on parameter spectrum constraints.

[0037] Combining all the above technical solutions, the beneficial effects of this invention are as follows:

[0038] First, the intelligent and rapid wave spectrum construction method combined with physical parameter spectral constraints provided by this invention introduces a hybrid model architecture, which includes a module for predicting the peak factor of regional spectral parameters; a module for calculating the wave spectrum energy distribution by substituting Jonswap spectrum data; and a module for outputting Jonswap wave spectrum energy compensation. The final model output is the predicted wave spectrum. This invention simultaneously solves the problems of lack of physical interpretability and potential physically unreasonable spectral shapes in data-driven models. Furthermore, by dynamically outputting peak factors through deep learning, it overcomes the limitations of insufficient accuracy of traditional fixed-parameter Jonswap spectra under different sea conditions. While maintaining the efficiency of deep learning methods, it significantly improves the physical rationality, interpretability, and prediction accuracy of wave spectrum forecasts.

[0039] Second, this invention fully considers the regional correlation of spectral peak factors: The Jonswap spectral constraint module in this invention utilizes a convolutional neural network, which has the ability to extract spatial features. When predicting spectral peak factors, the model can fully consider regional correlation, reflecting its interaction with the surrounding marine environmental conditions and spatial distribution characteristics, making the wave spectrum subsequently constructed using the Jonswap spectral physics formula more regionally consistent.

[0040] This invention balances construction efficiency and accuracy: it combines the advantages of fast inference speed and low computational cost of deep learning methods, ensuring construction efficiency. Simultaneously, by introducing the Jonswap physics formula as a physical constraint to predict spectral peak factors, this invention avoids constructing physically unreasonable spectral shapes and more accurately captures the evolution patterns of ocean wave spectra.

[0041] This invention enhances physical interpretability and generalization ability: by introducing the Jonswap spectral module to limit the output to physically meaningful wave spectral parameters, and utilizing the Jonswap spectral formula for wave spectral energy calculation, the physical interpretability of the constructed wave spectrum is significantly improved, making the constructed result not only a data mapping but also physically plausible. Furthermore, when facing new sea states not fully covered in the training data, this invention can generalize better, providing more reliable constructed results, thereby improving the robustness of the model.

[0042] Third, this invention significantly improves the physical rationality and accuracy of wave spectrum forecasting while maintaining the high efficiency of deep learning methods. By constructing a parametric spectral constraint hybrid model that includes a Jonswap spectral module and a spectral energy compensation module, it achieves rapid construction of wave spectra while effectively overcoming the limitations of insufficient generalization of traditional physical empirical formulas. This invention solves the technical challenge of balancing high accuracy, high efficiency, and physical rationality in wave spectrum construction. By constructing a Jonswap spectral constraint module that outputs spectral peak factors to dynamically adjust the peak factors, it overcomes the problems of insufficient accuracy and limited generalization ability of traditional fixed-parameter physical empirical formulas under complex sea conditions. This allows for a more accurate description and capture of the true physical morphology of wave spectra, significantly improving the accuracy and generalization ability of wave spectrum construction. Attached Figure Description

[0043] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure;

[0044] Figure 1 This is a flowchart of the intelligent rapid construction method for ocean wave spectrum provided in an embodiment of the present invention;

[0045] Figure 2 This is a diagram of the hybrid model architecture provided in an embodiment of the present invention;

[0046] Figure 3 This is a comparison chart of the MAE validation dataset results for the three models provided in this embodiment of the invention;

[0047] Figure 4 This is a comparison chart of the MSE validation dataset results of the three models provided in this embodiment of the invention; Detailed Implementation

[0048] To make the above-mentioned objects, features, and advantages of the present invention more apparent and understandable, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Many specific details are set forth in the following description to provide a thorough understanding of the present invention. However, the present invention can be practiced in many other ways different from those described herein, and those skilled in the art can make similar modifications without departing from the spirit of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed below.

[0049] The innovation of this invention lies in:

[0050] (1) Jonswap Spectrum Constraint Module: Dynamically predicts the key physical parameter of the Jonswap spectrum, the peak factor, by capturing the correlation between regional meteorological and wave data and the peak factor of the region, outputs the peak factor, and then combines the effective wave height and average period of the input data, substitutes them into the Jonswap spectrum formula to calculate a physically reasonable wave spectrum. This design takes into account the regional correlation of the peak factor, effectively overcomes the limitation of insufficient accuracy of the traditional fixed parameter Jonswap spectrum under different sea conditions, and improves the accuracy of wave spectrum construction;

[0051] (2) Spectral Energy Compensation Module: Based on the input meteorological wave conditions, the module learns the difference between the Jonswap spectrum and the real wave spectrum. The output of this module is intended to compensate for the wave spectrum energy distribution calculated by the Jonswap spectrum constraint module, thereby further enhancing the model's flexibility and ability to capture complex spectral shapes.

[0052] Example 1, such as Figure 1 As shown, the intelligent and rapid wave spectrum construction method based on parametric spectrum constraints provided in this embodiment of the invention includes the following steps:

[0053] S1. Dataset Construction: Collect meteorological and wave element data of the target sea area and the corresponding sea wave spectrum data, and construct the training dataset after preprocessing; the preprocessing includes creating a mask M to identify the ocean area and the land area.

[0054] Wave elements such as wind speed, significant wave height, and average period, as well as corresponding wave spectrum data for the target sea area, are collected. After preprocessing, data stitching, and null value cleaning, model input data containing meteorological and wave elements and model forecast target data corresponding to the real wave spectrum are generated, forming a complete dataset that can be used for model training and validation. Specifically, this includes:

[0055] (1) Data acquisition and preprocessing: Collect effective wave height, average period, sea surface wind speed data of the target sea area and wave spectrum data of the corresponding sea area.

[0056] (2) Data splicing: The significant wave height, average period, and sea surface wind speed are used as input features and spliced ​​into the model input tensor.

[0057] (3) Null value cleaning: Replace the 0 elements in the input data and wave spectrum with preset constants. This is to avoid problems with subsequent logarithmic and division operations. Simultaneously, null values ​​are replaced with this constant, and a mask M is created to identify the ocean region (1) and the land region (0) so that the land portion is excluded when calculating the loss. The mask M is to prevent invalid data (land regions) from affecting the loss function and thus the reasonableness of the results.

[0058] (4) Dataset partitioning and loading: The model input consists of significant wave height, mean period, and sea surface wind speed data, and the model training target is the wave spectrum data of the corresponding sea area. The constructed dataset is divided into training set and validation set in a 4:1 ratio to support batch training of the model.

[0059] S2. Hybrid Model Construction and Training: Constructing a parameter spectrum-constrained hybrid model;

[0060] like Figure 2 As shown, this invention employs a deep learning hybrid model architecture, which comprises two modules: a Jonswap spectral constraint module that dynamically outputs the spectral peak factor of the target region, and then combines the significant wave height and average period with the spectral formula to calculate a physically reasonable wave spectrum. The other module learns the energy distribution difference between the Jonswap spectrum and the actual wave spectrum and outputs it as energy compensation for the Jonswap spectral constraint module. The model concatenates and fuses the output feature tensors of these two modules to obtain a rapid wave spectrum construction result. Specifically, it includes:

[0061] (1) Construct the Jonswap spectral constraint module;

[0062] This module, based on a convolutional neural network, extracts distribution features from the input regional meteorological wave data, including significant wave height, average period, and sea surface wind speed. It learns the correlation between these features and the regional spectral peak factor, predicting the key physical parameter of the Jonswap spectrum: the spectral peak factor. Subsequently, combining the significant wave height and average period extracted from the input data, it calculates a physically plausible wave spectrum energy distribution using a pre-defined Jonswap spectrum formula. The system employs a CNN (Convolutional Neural Network) to receive a 4-channel input image. The encoder uses two sets of convolution-pooling operations to progressively increase the number of channels from 4 to 64, then 128, finally reaching 256 at the bottleneck layer, effectively halving the input image size twice. The decoder uses two 2×2 transposed convolutions to upsample, restoring the original size and reducing the number of channels from 256 back to 128 and then 64. Finally, a 3×3 convolutional layer adjusts the number of channels to 34, outputting the final result. The entire network primarily uses 3×3 convolutional kernels and the ReLU activation function.

[0063] By embedding the Jonswap spectral constraint module into the empirical wave spectrum formula, the spectral line shape can be dynamically adjusted based on the input meteorological wave conditions. This can more accurately describe the morphology of the wave spectrum, truly reflect the physical characteristics of the waves, and demonstrate the model's generalization ability.

[0064] ;

[0065] ;

[0066] ;

[0067] ;

[0068] In the formula, The wave spectrum energy distribution output by the Jonswap spectral constraint module. For input data, For frequency, The normalization coefficient is... For the effective wave height, The peak average period, Peak frequency, It is a natural exponential function. For the average period, The Jonswap spectral constraint module is used for parametric spectral constraint hybrid models. Calculate parameters for the Jonswap spectral constraint module. For shape parameters.

[0069] (2) Construct a spectral energy compensation module;

[0070] Real-world wave spectra are typically more complex than those described by the Jonswap empirical spectra. To better capture the wave spectral details neglected by the empirical spectra and further enhance the model's flexibility, this module learns the energy distribution differences between the Jonswap empirical spectra and real wave spectra based on the input meteorological wave data, and outputs as... Energy compensation is performed, and the output results from the Jonswap spectral constraint module are fused and spliced ​​to finally output the wave spectrum energy distribution. .

[0071] ;

[0072] In the formula, Output the wave spectrum energy distribution for the model. For the model spectral energy compensation module, These are the parameters calculated for the spectral energy compensation module.

[0073] S3. Wave spectrum construction: Input the meteorological and wave element data of the target sea area to be predicted into the trained hybrid model, and output the wave spectrum of the sea area.

[0074] The constructed dataset is input into the hybrid model for training. The model calculates and predicts wave spectra through forward propagation and compares them with actual wave spectra, using mean squared error (MSE) as the loss function. Model weights are updated through backpropagation. During training, the model is evaluated on a validation dataset to monitor convergence. Specifically, this includes:

[0075] (1) Model training: Input the constructed training dataset into the hybrid model. In order to avoid interference from land data on model training, the wave spectrum calculation is masked and filtered to output the wave spectrum energy distribution. The mean square error (MSE) of the output wave spectrum is used as the loss function.

[0076] Next, backpropagation is performed to calculate the gradient and update the model weights, enabling the model to learn the patterns of wave spectrum construction from the input conditions.

[0077] (2) Model validation: After each training round, the model is evaluated on the validation dataset, the validation loss is calculated and the learning rate is adjusted.

[0078] Ocean wave spectrum construction accuracy evaluation: The construction results of the trained model in the target sea area are evaluated, and compared with the results of a pure data-driven model and a Jonswap spectral model with fixed peak factors. Mean squared error (MSE), mean absolute error (MAE), and correlation coefficient (R²) are used. 2 The evaluation indicators, such as [list of indicators], are used to assess the effectiveness of the method of this invention in improving the accuracy of wave spectrum construction. Specifically, this includes:

[0079] This invention uses mean squared error (MSE), mean absolute error (MAE), and correlation coefficient (R²). 2 Three error evaluation indicators are used to assess the error between the actual value and the model prediction value of the wave spectrum in the target sea area.

[0080] ;

[0081] ;

[0082] ;

[0083] in, This represents the total number of sample points. and The first The true and predicted values ​​of the wave spectrum at each sample point. This represents the average value of the true wave spectrum.

[0084] Example 2: This embodiment of the invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the intelligent and rapid construction method of wave spectrum based on parameter spectrum constraints.

[0085] To further demonstrate the positive effects of the above embodiments, the present invention conducts the following experiments based on the above technical solutions.

[0086] During the evaluation phase, this invention constructs wave spectra on a complete validation dataset using the trained pure data-driven model, the fixed-parameter Jonswap spectral model, and the parameter-spectral-constrained hybrid model, with the same input wave meteorological conditions for all three models. The pure data-driven model directly outputs the wave spectrum energy distribution based on the input data and model parameter calculations. The fixed-parameter Jonswap spectral model, under the default condition of a peak factor γ=3.3, combines significant wave height and average period with the Jonswap spectral empirical formula to obtain the wave spectrum energy distribution. The parameter-spectral-constrained hybrid model first predicts the peak factor of sample points in the target area, then combines significant wave height and average period with the Jonswap spectral formula to calculate the energy distribution of the Jonswap spectral constraint module. Finally, the spectral energy compensation module completes the spectral details, outputting the final wave spectrum energy distribution.

[0087] The mean square error (MSE), mean absolute error (MAE), and coefficient of determination (R²) between the wave spectrum output by the calculation model and the actual wave spectrum are calculated. 2 The performance of each model was quantitatively compared. The comparison results of the three model validation datasets, MAE and MSE, are as follows: Figure 3 and Figure 4 As shown.

[0088] Experimental results show that the parameter-spectral-constrained hybrid model proposed in this invention significantly outperforms the pure data-driven model and the fixed-parameter Jonswap spectral model in key performance indicators, demonstrating excellent performance.

[0089] (1) Comparison with the pure data-driven model: As shown in Table 1, the MSE of the parameter spectrum-constrained hybrid model decreased significantly from 0.187 in the data-driven model to 0.039, and the MAE decreased from 0.125 to 0.066, while R 2 The accuracy improved from 0.916 to 0.983. This demonstrates that introducing physical constraints can effectively improve the model's prediction accuracy.

[0090] (2) Comparison with the fixed-parameter Jonswap spectral model: Compared with the Jonswap spectral physics model that only relies on a fixed peak factor of 3.3, the parametric spectral constraint hybrid model has more obvious advantages, and R2 The value of 0.983 is also much higher than the 0.602 of the fixed-parameter Jonswap spectral physics model.

[0091] By combining the flexibility of data-driven approaches with the rationality of physical mechanisms, the parametric spectrum-constrained hybrid model of this invention corrects the potential biases of pure data-driven deep learning models, while overcoming the limitations of traditional physical models under complex sea conditions, achieving a breakthrough in the accuracy and reliability of wave spectrum construction.

[0092] Table 1. Errors in the Model Validation Dataset

[0093]

[0094] Data Source: The dataset used in this invention is a set of high-resolution, multivariate spatiotemporal marine environmental data derived from ERA5 reanalysis data. The dataset covers the period from January to June 2021, with a temporal resolution of 1 hour. Spatially, it covers an area from 2°N to 42°N and from 105°E to 135°E, with a spatial resolution of 1 / 12°. This high spatiotemporal resolution dataset provides the model with detailed information on the marine dynamic environment.

[0095] The dataset contains physical variables that are used for model training and validation, where:

[0096] Input features include: U-component wind speed (u10), V-component wind speed (v10), significant wave height (hs), and mean wave period (tm) at a height of 10 meters above sea level.

[0097] The target output is: wave energy spectrum (ef variable), which contains 34 channels along the frequency dimension.

[0098] Research and development process:

[0099] (1) Data Loading and Preprocessing (OceanDataset Class): An OceanDataset class is defined to process the data, loading multiple sets of NetCDF files from 6 months (containing hs, t01, u10, v10 and ef variables). First, the high-resolution data is spatially downsampled by sampling every 12 points; then, the input (hs, tm, u10, v10) is stacked into a 4-channel X tensor, the spectrum ef is set as the Y tensor, and a key land and sea mask M is generated based on the NaN value.

[0100] (2) Model architecture definition (OceanSpectrumCNN and HybridModel classes):

[0101] The script defines two models. OceanSpectrumCNN is a standard encoder-decoder architecture that includes two MaxPool2d (downsampling) iterations and two ConvTranspose2d (upsampling) iterations. The HybridModel class is the core of this method, and it has two branches:

[0102] direct_branch (data branch): Directly predicts the wave spectrum (as a baseline or residual).

[0103] `gamma_branch_cnn` (Physics Branch): Predicts the gamma parameter in the JONSWAP physics formula. During the forward propagation of the HybridModel, the model runs both branches simultaneously. It feeds the output of `gamma_branch_cnn` along with the inputs `hs` and `tm` into the `Jonswap` function (a physics formula implemented in PyTorch within a script) to calculate the physics-directed `spectrum_gamma`. Ultimately, the model's prediction is the sum of the outputs from the data branch and the physics branch (`spectrum_direct + spectrum_gamma`).

[0104] (3) Training logic (train_direct_model and train_hybrid_model functions):

[0105] The script defines training functions for both models. Both functions follow a standard procedure: splitting the OceanDataset into an 80% training set and a 20% validation set, setting the Adam optimizer, MSE loss function, and learning rate scheduler. A key operation in the training loop is calculating the loss using a mask M (loss = criterion(outputs * M, Y * M)), which ensures the model only calculates error in the ocean region, ignoring land areas.

[0106] (4) Evaluation and Comparison (evaluate_and_compare_models function):

[0107] For final performance evaluation, the script defines an evaluation function. This function loads two pre-trained models and introduces a third comparison—a purely physical formula (a Jonswap model with a fixed gamma of 3.3). It runs all three models on the validation set, extracts the ground truth and predicted values ​​for all ocean points using a mask M, and then calls the `calculate_final_metrics` function to calculate and print a clear comparison table showing each model's performance on MSE, MAE, and R² metrics.

[0108] Model generalization test: To evaluate the model's generalization ability, this study used a model trained on data from January to June 2021 to predict completely unseen sea state data from different seasons (July to December 2021). The evaluation results are shown in the table, which details the mean squared error (MSE), mean absolute error (MAE), and coefficient of determination (R²) of the "baseline model," "mixed model," and "Jonswap (γ=3.3)" physical model on different time slices.

[0109] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any modifications, equivalent substitutions and improvements made by those skilled in the art within the scope of the technology disclosed in the present invention and within the spirit and principles of the present invention should be covered within the scope of protection of the present invention.

Claims

1. A method for intelligent and rapid construction of ocean wave spectra based on parametric spectrum constraints, characterized in that, The method includes the following steps: S1. Dataset Construction: Collect meteorological and wave element data of the target sea area and the corresponding sea wave spectrum data, and construct the training dataset after preprocessing; the preprocessing includes creating a mask M to identify the ocean area and the land area. S2. Hybrid Model Construction and Training: Construct a parameter spectrum-constrained hybrid model, which includes: The Jonswap spectral constraint module is used to dynamically predict the spectral peak factor based on the meteorological and wave element data, and to calculate the initial wave spectral energy distribution by combining the significant wave height and average period using the Jonswap spectral formula. The Jonswap spectral constraint module, based on a convolutional neural network, extracts distribution features from the significant wave height, average period, and sea surface wind speed of the input target sea area, learns the correlation between these features and the regional spectral peak factor, and predicts the key physical parameter of the Jonswap spectrum, the spectral peak factor. Combining the extracted significant wave height and average period, it calculates the wave spectral energy distribution using a preset Jonswap spectral formula. In the formula, The wave spectrum energy distribution output by the Jonswap spectral constraint module, where X is the input data, f is the frequency, and β is the frequency. j The normalization coefficient is... For the effective wave height, T p For the peak average period, f p Let be the peak frequency, exp[] be the natural exponential function, T be the average period, and M be the peak frequency. Jonswap () represents the Jonswap spectral constraint module of the parametric spectral constraint hybrid model, θ1 represents the calculation parameters of the Jonswap spectral constraint module, and σ represents the shape parameter; The spectral energy compensation module is used to output spectral energy compensation values ​​based on the meteorological and wave element data. The spectral energy compensation module is implemented through a neural network and is used to learn and output the complex wave spectral energy details that the Jonswap spectral formula fails to describe. The fusion module is used to fuse the initial wave spectrum energy distribution with the spectrum energy compensation value and output the final wave spectrum energy distribution. The parameter spectrum constrained hybrid model is trained using the training dataset. During the training process, the mask M is used to filter land area data so that the loss function is calculated only based on ocean area data. S3. Wave spectrum construction: Input the meteorological and wave element data of the target sea area to be predicted into the trained hybrid model, and output the wave spectrum of the sea area.

2. The intelligent and rapid wave spectrum construction method based on parametric spectrum constraints according to claim 1, characterized in that, In step S1, the preprocessing further includes: replacing null and zero values ​​in the input data and wave spectrum data with a preset constant 1×10. -6 .

3. The intelligent and rapid wave spectrum construction method based on parametric spectrum constraints according to claim 1, characterized in that, In step S2, the spectral energy compensation module learns the energy distribution difference between the Jonswap empirical spectral type and the actual wave spectrum based on the input meteorological wave data, and outputs as... The energy compensation is combined with the output of the Jonswap spectral constraint module to finally output the wave spectrum energy distribution. In the formula, To output the wave spectrum energy distribution for the model, M comp () represents the spectral energy compensation module of the model, and θ2 represents the calculation parameters of the spectral energy compensation module.

4. The intelligent and rapid wave spectrum construction method based on parametric spectrum constraints according to claim 1, characterized in that, In step S2, the fusion module obtains the final wave spectrum energy distribution by performing a tensor addition operation between the initial wave spectrum energy distribution and the spectrum energy compensation value.

5. The intelligent and rapid wave spectrum construction method based on parametric spectrum constraints according to claim 1, characterized in that, In step S2, the fusion module performs a tensor splicing operation between the initial wave spectrum energy distribution and the spectrum energy compensation value to obtain the final wave spectrum energy distribution.

6. The intelligent and rapid wave spectrum construction method based on parametric spectrum constraints according to claim 1, characterized in that, In step S2, during the training of the hybrid model, the predicted wave spectrum is calculated through forward propagation, and the mean square error between the predicted wave spectrum and the actual wave spectrum is used as the loss function; the gradient is calculated through backpropagation, and the model weights are updated. The model is evaluated on the validation dataset, and the convergence of the model is monitored.

7. The intelligent and rapid wave spectrum construction method based on parametric spectrum constraints according to claim 1, characterized in that, The method also includes model evaluation, comparing the wave spectrum constructed by the hybrid model with the wave spectra constructed by the pure data-driven model and the fixed-parameter Jonswap spectral model, using mean squared error (MSE), mean absolute error (MAE), and correlation coefficient (R²). 2 Error assessment is performed using at least one of the indicators.

8. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the intelligent and rapid wave spectrum construction method based on parametric spectrum constraints as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Sea wave spectrum intelligent correction method and system based on neural network

    CN120850802A

  • Port wave spectrum parametric modeling algorithm based on machine learning

    CN120850820A