Multi-working-condition identification method, system and equipment for all-electric ship and medium
Through data noise reduction and reconstruction, two-stage dynamic recognition framework, Bayesian optimization and weighted iteration strategy, combined with core principal component analysis and Bayesian optimization LightGBM model, the problems of noise interference, feature redundancy and low recognition accuracy in ship operating conditions are solved, and high-precision and high-reality multi-condition recognition are achieved.
Patent Information
- Application Number
- CN202510694087.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-28
- Publication Date
- 2025-06-27
- Estimated Expiration
- 2045-05-28
AI Technical Summary
The existing ship operating conditions recognition methods are susceptible to noise interference and have high-dimensional feature redundancy, making it difficult to achieve high-precision multi-condition recognition, especially in sudden conditions and random environment changes.
Using data noise reduction and reconstruction, two-stage dynamic recognition framework, Bayesian optimization and weighted iteration strategy, key features are screened through variational modal decomposition and maximum information coefficient, combined with core principal component analysis and Bayesian optimization LightGBM model, high-dimensional features are streamlined and adaptive adjustment of the model are achieved.
It significantly improves the accuracy and real-timeness of fully electric ship operating conditions, can effectively deal with high fluctuation operating conditions in complex scenarios, reduces the computational complexity and improves the engineering applicability of the model.
Smart Images

Figure CN120217210A_ABST
Abstract
Description
Background Art
[0002] An all-electric ship refers to a ship that relies entirely on electric drive, and its power system, propulsion system, and other auxiliary equipment all use electric energy as the energy source. Compared with traditional diesel ships, the electric power system of all-electric ships has low inertia and is vulnerable to interference. The severe fluctuations in propulsion load will directly affect the stability of the power system, which makes high-precision propulsion load prediction a core link to ensure the efficient and stable operation of the ship. However, the actual operating conditions of the ship are complex and changeable, and are affected by multiple factors such as the environment and tasks, resulting in severe challenges for the load prediction model. Establishing an accurate multi-condition recognition system to dynamically distinguish different navigation states is the key to improving the load prediction performance and ensuring the stable operation of the ship.
[0003] Regarding the problem of ship condition recognition, the existing technologies mainly optimize the fuel consumption of generators by constructing a condition dataset for hybrid ships and combining deep learning strategies, or fuse condition models based on mathematical mechanisms, and use machine learning algorithms to achieve condition classification. For example, data noise is processed through a signal decomposition algorithm, clustering methods are used to divide basic condition categories, and an ensemble learning model is introduced to improve the recognition accuracy. These methods can achieve a certain degree of condition differentiation in specific scenarios, providing a technical basis for ship operation state monitoring.
[0004] However, the existing ship condition recognition methods still have significant limitations. The operating environment of all-electric ships is complex, and sensor data is vulnerable to noise interference, resulting in high-dimensional, non-linear, and non-stationary characteristics of the original data. Traditional methods are difficult to effectively reduce noise and extract key features. At the same time, sudden conditions and random environmental changes have high requirements for real-time recognition. Existing single clustering or classification models are difficult to adaptively adjust strategies, resulting in insufficient recognition accuracy for high-fluctuation conditions. In addition, the problem of feature redundancy in the condition recognition process has not been effectively solved, and the model calculation burden is large, restricting the engineering applicability in complex scenarios. Summary of the Invention
[0005] Aiming at the technical problems of the existing ship condition recognition methods, such as being vulnerable to noise interference, high-dimensional feature redundancy, low recognition accuracy for high-fluctuation conditions, and poor adaptability due to fixed model parameters, this application provides a multi-condition recognition method, system, device, and medium for all-electric ships. Through data denoising and reconstruction, a two-stage dynamic recognition framework, Bayesian optimization, and a weighted iteration strategy, high-dimensional feature reduction, accurate recognition of sudden conditions, and model adaptive adjustment are achieved, which can improve the condition recognition accuracy and real-time performance of all-electric ships in complex scenarios.
[0006] In the first aspect, this application provides a multi-condition recognition method for all-electric ships, including the following steps: S1. Obtain historical operation data of the all-electric ship, which consists of samples at each time stamp, and each sample includes propulsion load, first-order derivative of propulsion load, propulsion motor parameters, environmental parameters and power battery output parameters at the corresponding time stamp; S2. Extract features and reduce noise from historical operation data to obtain a noise-reduced data set for each sample, including propulsion load after noise reduction, first-order derivative of propulsion load, propulsion motor parameters, environmental parameters, and power battery output parameters; S3. Input the propulsion load and the first-order derivative of the propulsion load after noise reduction of each sample into the K-means clustering algorithm for preliminary clustering, classify them into multiple basic working conditions, and add a unique basic working condition label to each noise reduction data group; S4. Determine whether the absolute value of the first-order derivative of the propulsion load of each sample after noise reduction is higher than a preset threshold, aggregate the noise reduction data group corresponding to all samples with a yes result into a high-volatility data set, and aggregate the propulsion load, the first-order derivative of the propulsion load, and the basic working condition label corresponding to all samples with a no result into a general data set; S5. Conduct secondary subdivision, including: The kernel principal component analysis algorithm is used to uniformly extract the main features of the data in the high volatility data set and the general data set, and then the pre-trained working condition segmentation model is input to output the specific working condition category. The working condition segmentation model is a Bayesian optimized weighted iterative LightGBM model.
[0007] It should be further explained that, in step S1, the propulsion motor parameters include the propulsion motor speed and active power, the environmental parameters include wind speed, flow velocity and water surface wave height, and the power battery output parameters include lithium battery output power and fuel cell output power.
[0008] It should be further explained that in step S2, feature extraction and noise reduction of historical operation data include: Decompose the original operating data into multiple eigenmodes through variational modes; Calculate the maximum information coefficient of each eigenmode and the original data, and retain the eigenmode whose maximum information coefficient exceeds the preset threshold as the main signal; The main signal is reconstructed and the interference noise is removed to obtain the denoised data set of each sample.
[0009] It should be further explained that the steps of variational mode decomposition include: The variational model is iteratively solved by the alternating direction multiplier method and Fourier isometric transform to obtain the decomposed mode function set and the corresponding center frequency. The steps to calculate the maximum information coefficient include: The intrinsic modes obtained by decomposing the propulsion load data and the original data are discretized into a two-dimensional grid space, and the normalized maximum mutual information value is calculated as the maximum information coefficient; The steps of removing interference noise include: The intrinsic modes with the maximum information coefficient lower than the preset threshold are removed as noise signals, and the signals are reconstructed by linearly superimposing the remaining intrinsic modes.
[0010] Furthermore, it should be noted that the number of intrinsic modes of variational mode decomposition is set to 3 - 7, and the noise tolerance parameter is determined by the residual index method.
[0011] Furthermore, it should be noted that the preset threshold of the maximum information coefficient is determined by the grid search method, and the maximum information coefficient threshold of the propulsion load data is 0.12.
[0012] Furthermore, it should be noted that in step S3, there are 4 types of basic working conditions, and the classification basis is the distribution characteristics of the propulsion load range and the first derivative; the basic working condition labels are basic working condition 1 to basic working condition 4.
[0013] Furthermore, it should be noted that in step S4, the preset threshold is 40 - 50.
[0014] Furthermore, it should be noted that in step S5, kernel principal component analysis maps the original data to a high-dimensional space by introducing a radial basis kernel function, and the number of principal components extracted is 6 - 12.
[0015] Furthermore, it should be noted that in step S5, the working condition subdivision model includes the following hierarchical structure: The input layer receives the main features extracted by kernel principal component analysis as input features; The feature processing layer includes a mutually exclusive feature bundling module and a gradient unilateral sampling module, which respectively perform sparse feature compression and high-information sample screening on the input features to obtain optimized features; The decision tree generation layer generates a binary tree structure according to the leaf growth strategy based on the optimized features and the hyperparameters provided by the Bayesian optimization framework layer, and the information gain is calculated by the weighted iterative objective function for each split node; The Bayesian optimization framework layer dynamically adjusts the hyperparameter combination of the decision tree generation layer, including the number of leaf nodes, the maximum depth, the learning rate, and the feature sampling ratio; The output layer maps the leaf node weights through a weighted iterative classifier to generate specific working condition category labels.
[0016] Furthermore, it should be noted that the weighted iterative objective function is:
[0017]
[0018]
[0019] Wherein, is the total number of samples; is the sample weight adjustment coefficient; is the cross-entropy loss function; is the output of the th decision tree; is the vector representation of the sample is the decision tree complexity regularization term; is the constant term; is the confidence of the sample ; is the average distance between the feature point and other data of the same category; is the average distance between the feature point and the feature data points of other categories; is the working condition category where it is located; and are constants, set according to the quantity and scale of the training set.
[0020] It should be further noted that in step S5, the training steps of the working condition subdivision model include: S501. Obtain the historical operation data of all-electric ships with known specific working condition categories, perform the same operations as in steps S1-S4 to obtain the training high-fluctuation data set and the training general data set, then use the kernel principal component analysis algorithm to uniformly extract the main features of the data in the high-fluctuation data set and the general data set, and then divide them into a training set, a validation set, and a test set according to the ratio of 7:2:1. During the division, stratified sampling is used to ensure the balanced distribution of samples for each specific working condition category; S502. Initialize the hyperparameters of the working condition subdivision model through the parameter space search strategy optimized by Bayesian, including the number of leaf nodes, the maximum depth, the learning rate, and the feature sampling ratio; S503. Dynamically adjust the hyperparameters through the Bayesian optimization framework layer: calculate the weighted iterative objective function value on the validation set, generate the posterior probability distribution of the hyperparameters according to the change of the function value, and iteratively update the hyperparameters of the working condition subdivision model; S504. Input the training set into the working condition subdivision model for training, including: Compress and screen the input features through the mutually exclusive feature bundling module and the gradient unilateral sampling module; In the decision tree generation layer, generate a binary tree structure according to the leaf growth strategy, and calculate the information gain for each splitting node based on the correlation between the first-order derivative of the propulsion load and the environmental parameters; Based on the sample confidence Dynamically calculate the weight coefficient , update the decision tree structure by weighted iterative objective function, and output the specific working condition category label; S505. Input the test set into the working condition subdivision model, calculate the classification accuracy of each specific working condition category according to the output of each sample and the actual specific working condition category. If the classification accuracy does not meet the preset conditions, return to step S503 to readjust the hyperparameters and iterate the training. If it meets the preset conditions, output the final model to obtain the pre-trained working condition subdivision model.
[0021] It should be further noted that in step S5, after using kernel principal component analysis to extract the main features, source labels are added to the data from the high-fluctuation data set and the general data set respectively, and then input into the working condition subdivision model.
[0022] It should be further noted that in step S5, the specific working condition categories include low-speed driving conditions, normal navigation conditions, high-speed cruising conditions, operation conditions, and emergency or port conditions. Among them, low-speed driving conditions, normal navigation conditions, and high-speed cruising conditions belong to general operation conditions, and operation conditions, emergency or port conditions belong to high-fluctuation conditions.
[0023] In the second aspect, the present application provides a multi-condition recognition system for an all-electric ship, which is used to implement the multi-condition recognition method for the all-electric ship of the above integrated energy system, including: A data acquisition module for acquiring the historical operation data of the all-electric ship; A data processing module for extracting features and denoising the historical operation data to obtain the denoised data group of each sample; A preliminary clustering module for inputting the propulsion load and the first-order derivative of the propulsion load after denoising each sample into the K-means clustering algorithm for preliminary clustering, classifying them into multiple basic working conditions, and adding a unique basic working condition label to each denoised data group; A judgment classification module for judging whether the absolute value of the first-order derivative of the propulsion load after denoising each sample is higher than a preset threshold, summarizing the denoised data groups corresponding to all samples with the result being yes into a high-fluctuation data set, and summarizing the propulsion load, the first-order derivative of the propulsion load, and the basic working condition label corresponding to all samples with the result being no into a general data set; The secondary subdivision module is used to uniformly extract the main features of the data in the high-fluctuation data set and the general data set using the kernel principal component analysis algorithm, and then input them into the pre-trained working condition subdivision model to output specific working condition categories.
[0024] In a third aspect, the present application provides an electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. The processor is configured to implement the steps of the multi-condition recognition method for the all-electric ship when executing the computer program.
[0025] In a fourth aspect, the present application provides a storage medium with a computer program stored thereon. The computer program, when executed by a processor, implements the steps of the multi-condition recognition method for the all-electric ship.
[0026] From the above technical solutions, it can be seen that the present application has the following advantages: 1. Based on the data reconstruction method of variational mode decomposition and maximum information coefficient, the present application performs mode decomposition and feature screening on multi-source heterogeneous data such as ship propulsion load and environmental parameters, effectively removing noise interference and retaining the key mode components strongly related to the working conditions, solving the problem that traditional methods are difficult to distinguish effective signals from noise in non-linear and non-stationary data, significantly improving the signal-to-noise ratio of the input data, and providing a highly reliable data basis for the subsequent working condition recognition model.
[0027] 2. By adopting a two-stage recognition framework that combines K-means clustering and a weighted iterative LightGBM model optimized by Bayesian optimization, the present application initially clusters and divides the basic working conditions through the propulsion load and its change rate, and then performs secondary subdivision on the high-fluctuation data in combination with multi-dimensional operation characteristics, overcoming the problem that a single clustering algorithm is sensitive to sudden working conditions and random environmental changes, achieving accurate discrimination of high-fluctuation scenarios such as low-speed ship navigation, operation tasks, and extreme environments, and enhancing the robustness and continuity of recognition under complex working conditions.
[0028] 3. By performing dimensionality reduction on high-dimensional features through kernel principal component analysis and designing a weighted iterative LightGBM objective function, the present application dynamically adjusts the sample weights and model parameters, solving the problem of insufficient model generalization ability caused by feature redundancy and fixed hyperparameters in traditional methods, enabling the algorithm to adapt to the data distribution characteristics of different working conditions, reducing the computational complexity while ensuring the recognition accuracy, and improving the real-time performance and scalability of engineering deployment. Description of the Drawings
[0029] To more clearly illustrate the technical solutions of the present application, the accompanying drawings required in the description will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other accompanying drawings can be obtained based on these drawings.
[0030] Figure 1 It is a flowchart of a multi-condition recognition method for an all-electric ship in an embodiment of the present application.
[0031] Figure 2 It is a flowchart of the training steps of a condition subdivision model in an embodiment of the present application.
[0032] Figure 3 It is a two-dimensional scatter plot of propulsion power and its change rate drawn using the preliminary clustering results in an embodiment of the present application.
[0033] Figure 4 It is a two-dimensional scatter plot of propulsion power and its change rate drawn using the secondary subdivision results in an embodiment of the present application.
[0034] Figure 5 It is a basic condition classification diagram of an all-electric ship under a continuous working time in an embodiment of the present application.
[0035] Figure 6 It is a specific condition category classification diagram of an all-electric ship under a continuous working time in an embodiment of the present application.
[0036] Figure 7 It is a schematic block diagram of a multi-condition recognition system for an all-electric ship in an embodiment of the present application.
[0037] Figure 8 It is a schematic diagram of the hardware structure of an electronic device in an embodiment of the present application. Specific embodiments
[0038] To make the application purpose, features, and advantages of the present application more obvious and understandable, the technical solutions protected by the present application will be clearly and completely described below using specific embodiments and the accompanying drawings. Obviously, the embodiments described below are only some embodiments of the present application, rather than all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts belong to the scope of protection of the present application.
[0039] The multi-condition recognition method for all-electric ships involved in this application will be described in detail below. For the purpose of illustration rather than limitation, specific details such as specific system structures and technologies are proposed to thoroughly understand the embodiments of this application. However, those skilled in the art should clearly understand that this application can also be implemented in other embodiments without these specific details.
[0040] In the multi-condition recognition method for all-electric ships involved in this application, the term "including" indicates the existence of the described features, wholes, steps, operations, elements, and / or components, but does not exclude the existence or addition of one or more other features, wholes, steps, operations, elements, components, and / or their combinations. The terms "including", "comprising", "having" and their variants all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0041] For the convenience of clearly describing the technical solutions of this application, terms such as "first" and "second" are used to distinguish the same items or similar items with basically the same functions and roles. Those skilled in the art can understand that the terms "first", "second", etc. do not limit the quantity and execution order, and the terms "first", "second", etc. do not necessarily limit to being different.
[0042] The statements such as "an embodiment" or "some embodiments" described in this application mean that the specific features, structures, or characteristics described in this embodiment are included in one or more embodiments of this application. Thus, the statements such as "in an embodiment", "in some embodiments", "in other some embodiments", "in still other embodiments" and the like that appear in different parts of this application do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways.
[0043] Next, the technical solutions in the embodiments of this application will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of this application. Obviously, the described embodiments are only a part of the embodiments of this application, rather than all the embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative efforts belong to the scope protected by this application.
[0044] The multi-condition recognition method for all-electric ships provided by the embodiments of this application is executed by a computer device. Correspondingly, the multi-condition recognition system for all-electric ships runs in the computer device.
[0045] The following are some noun explanations in this solution to facilitate a better understanding of this solution: K-means Clustering Algorithm: The K-means Clustering Algorithm is an unsupervised learning algorithm that iteratively divides samples into K clusters (Clusters), minimizing the Euclidean distance within the same cluster and maximizing the distance between different clusters. The number of clusters K needs to be specified in advance.
[0046] Kernel Principal Component Analysis Algorithm: The Kernel Principal Component Analysis (KPCA) algorithm is a non-linear extension of the Principal Component Analysis (PCA). After mapping the data to a high-dimensional feature space through a kernel function (such as a radial basis kernel function), it performs linear dimensionality reduction, capable of capturing complex non-linear structures in the data and is suitable for feature extraction and visualization.
[0047] Weighted Iterative LightGBM Model Optimized by Bayesian Optimization: The LightGBM (Light Gradient Boosting Machine) model is an efficient machine learning framework based on the Gradient Boosting Decision Tree (GBDT). It accelerates training through the histogram algorithm, reduces memory occupancy based on the leaf node growth strategy, supports parallel learning and categorical feature processing; Weighted Iteration refers to dynamically adjusting the weights of samples or features during model training. For example, increasing the weight of mispredicted samples to enhance the model's attention to difficult examples; Bayesian Optimization is a hyperparameter tuning method that intelligently selects parameter combinations by constructing a probabilistic surrogate model (such as a Gaussian process) of the objective function and an acquisition function (such as the Expected Improvement EI), finding the global optimal solution with fewer iterations and being suitable for the automated tuning of hyperparameters such as the learning rate and tree depth in LightGBM.
[0048] Figure 1 It is a flowchart of the multi-condition recognition method for an all-electric ship in an embodiment of this application. Among them, Figure 1 The execution subject can be a multi-condition recognition system for an all-electric ship. According to different requirements, the order of steps in this flowchart can be changed, and some can be omitted.
[0049] As Figure 1 shown, the multi-condition recognition method for this all-electric ship includes: Step S1: Obtain the historical operation data of the all-electric ship. The historical operation data consists of samples at each timestamp. Each sample includes the propulsion load, the first derivative of the propulsion load, the propulsion motor parameters, the environmental parameters, and the power battery output parameters at the corresponding timestamp.
[0050] The system collects all-dimensional historical operation data such as propulsion load, motor speed, environmental parameters, and battery output, which completely covers the multi-physical field coupling characteristics of the ship power system in the time series, provides underlying data support with spatio-temporal correlation for subsequent working condition division, effectively avoids the problem of misjudging working conditions caused by single-parameter analysis, and at the same time realizes the standardized preprocessing of massive heterogeneous data through structured storage.
[0051] In some specific embodiments, the propulsion motor parameters include the propulsion motor speed and the active power, the environmental parameters include the wind speed, the flow velocity, and the water surface wave height, and the power battery output parameters include the lithium battery output power and the fuel cell output power.
[0052] By clearly defining that the propulsion motor parameters include speed and active power, the environmental parameters cover wind speed, flow velocity, and wave height, and the power battery parameters include lithium battery and fuel cell output power, a multi-dimensional data acquisition system covering the coupling effects of mechanics, electricity, and environment is constructed. It not only ensures the complete coverage of the energy transfer link of the ship power system by the feature engineering, but also eliminates the magnitude difference of cross-sensor data through the standardized definition of physical dimensions, provides feature inputs with engineering interpretability for subsequent clustering and classification models, and enhances the mapping consistency between the working condition recognition results and the actual operation scenarios.
[0053] Step S2: Perform feature extraction and noise reduction on the historical operation data to obtain the noise-reduced data group of each sample, including the noise-reduced propulsion load, the first derivative of the propulsion load, the propulsion motor parameters, the environmental parameters, and the power battery output parameters.
[0054] Through feature extraction and noise reduction processing, the high-frequency noise and interference signals in the original data are effectively eliminated, the data quality is improved, and more accurate and stable input information is provided for subsequent clustering and subdivision models.
[0055] In some specific embodiments, the feature extraction and noise reduction of the historical operation data include: Decompose the original operation data into multiple intrinsic modes through variational mode decomposition; Calculate the maximum information coefficient between each intrinsic mode and the original data, and retain the intrinsic modes with the maximum information coefficient exceeding the preset threshold as the main signals; Reconstruct the main signals and eliminate the interference noise to obtain the noise-reduced data group of each sample.
[0056] Among them, Variational Mode Decomposition (VMD) is an adaptive and completely non-recursive signal processing algorithm. By constructing a constrained variational problem, the signal is decomposed into multiple Intrinsic Mode Functions (IMFs) with different center frequencies. Each intrinsic mode is closely distributed around its center frequency in the frequency domain. The center frequency and bandwidth of each intrinsic mode (Intrinsic Mode Function, IMF) are determined by iteratively searching for the optimal solution of the variational model, which is applicable to non-stationary signal processing; The Maximal Information Coefficient (MIC) is a statistic for measuring the non-linear correlation between variables. It is calculated through grid division and mutual information normalization, with a value range of [0,1]. The larger the value, the stronger the correlation, which is applicable to feature selection in high-dimensional data mining; The original signal is adaptively decomposed into multi-scale intrinsic modes by variational mode decomposition, and the correlation between each mode and the original data is quantified by combining the maximal information coefficient, realizing the precise separation of noise signals and effective features. It not only overcomes the empirical dependence on the selection of basis functions in traditional wavelet decomposition but also retains the time-domain integrity of the propulsion load mutation event through the linear superposition mechanism in the signal reconstruction process, thus avoiding the over-smoothing of key operating condition features during the denoising process and providing high-quality input data with both time-series continuity and feature significance for subsequent algorithms.
[0057] In some specific embodiments, the steps of variational mode decomposition include: Iteratively solve the variational model through the alternating direction method of multipliers and Fourier isometric transformation to obtain the set of decomposed mode functions and the corresponding center frequencies; The steps of calculating the maximal information coefficient include: Discretize the intrinsic modes and the original data after decomposing the propulsion load data into a two-dimensional grid space, and calculate the normalized maximal mutual information value as the maximal information coefficient; The steps of removing interference noise include: Take the intrinsic modes with maximal information coefficients lower than the preset threshold as noise signals to be removed, and reconstruct the signal by linearly superposing the remaining intrinsic modes.
[0058] Among them, the Alternating Direction Method of Multipliers (ADMM) is a distributed optimization algorithm applicable to decomposable large-scale convex optimization problems. By decomposing the original problem into multiple sub-problems for alternating solution and introducing Lagrange multipliers to coordinate the constraint conditions between sub-problems, it features fast convergence speed and is friendly for parallel computing; The Variational Model is a mathematical model constructed based on the variational principle. By minimizing the energy functional, the problem is transformed into an optimization problem for solution, and it is widely applied in fields such as image processing and physical modeling.
[0059] In the calculation process of variational mode decomposition, it is first necessary to construct a variational problem, introduce the Lagrange multiplication operator and the quadratic penalty factor to construct the augmented Lagrangian equation:
[0060] In the formula, K is a positive integer representing the number of modes to be decomposed, represents the set of modal functions after decomposition and the corresponding central frequencies; is the Dirac function; is the convolution operator; f is the input signal; After that, using the alternating direction method of multipliers, Fourier isometric transformation to solve the equation, the modal components and their central frequencies can be obtained:
[0061]
[0062]
[0063] In the formula, n represents the number of iterations, represents the noise tolerance, , , represents the form after Fourier transform.
[0064] The solution of the maximum mutual information coefficient is based on mutual information (MI). MI is a measure of information, indicating the amount of information contained in one random variable about another random variable, and can be expressed as:
[0065] Among them x, y represents two different variables, p(x, y) is the joint probability density between variables, p(x)p(y) represents the marginal density; The basic calculation principle of the maximum information coefficient includes: (1) Discretize two variables into a two-dimensional space, x, y Perform i column, j row grid division on the formed scatter plot, and solve for the maximum mutual information value; (2) Normalize the maximum mutual information value; (3) Select the maximum mutual information value at different scales as the MIC value, and the calculation formula is:
[0066] In the formula, a, b represents the number of grids divided in the x, y direction, B is a variable, and its numerical value is approximately the 0.6th power of the data volume. The larger the MIC value, the higher the correlation between the two variables.
[0067] By using the alternating direction method of multipliers to solve the constrained optimization problem of variational mode decomposition, and combining the Fourier equidistant transform to accelerate the frequency domain iterative calculation, the convergence speed and stability of complex signal decomposition are significantly improved. At the same time, the maximum mutual information value is calculated by grid-based spatial discretization, which solves the numerical instability problem of continuous variable mutual information estimation. Through the directional elimination of noise modes and the linear reconstruction of retained modes, the optimal trade-off between signal fidelity and computational complexity is achieved, providing a theoretically rigorous and engineering-feasible technical path for real-time data processing in industrial scenarios.
[0068] In some specific embodiments, the number of intrinsic mode functions of variational mode decomposition is set to 3 - 7, and the noise tolerance parameter is determined by the residual index method.
[0069] Among them, the Residual Index Method evaluates the model performance or detects outliers by analyzing the statistical characteristics (such as residual distribution, trend change, etc.) of the model prediction residuals (the difference between the predicted value and the true value), and is commonly used in time series analysis and quality control.
[0070] By dynamically determining the number of modes and the noise tolerance parameter of variational mode decomposition through the residual index method, the adaptive matching of the decomposition granularity and data characteristics is achieved, avoiding the over-decomposition or under-decomposition problems caused by presetting parameters based on artificial experience. At the same time, the number of modes is limited within a reasonable range of 3 - 7, which not only ensures the completeness of signal feature extraction but also prevents the sharp increase in the algorithm's computational load caused by modal redundancy, providing a signal preprocessing scheme with strong universality and high robustness for the all-electric ship data in different navigation environments.
[0071] In some specific embodiments, the preset threshold of the maximum information coefficient is determined by the grid search method, and the maximum information coefficient threshold of the propulsion load data is 0.12.
[0072] The grid search method is a hyperparameter optimization method that traverses the predefined parameter combination space, trains the model one by one and evaluates the performance to select the optimal parameters. It has a large computational amount but is easy to parallelize, and is suitable for scenarios with a low parameter dimension.
[0073] By traversing the threshold candidate set of the maximum information coefficient through the grid search method, and combining cross-validation to evaluate the signal reconstruction error and the classification model accuracy under different thresholds, the optimal threshold of 0.12 is determined in a data-driven manner. This not only avoids the subjective deviation of manually setting the threshold, but also ensures the stability of the effective modes through the quantitative screening criteria, enabling the noise reduction process to maintain high robustness under different ship load fluctuation scenarios, and providing a reproducible and verifiable parameter configuration benchmark for engineering deployment.
[0074] Step S3: Input the propulsion load and the first derivative of the propulsion load after noise reduction of each sample into the K-means clustering algorithm for preliminary clustering, classify them into multiple basic working conditions, and add a unique basic working condition label to each noise-reduced data group.
[0075] The clustering steps of the K-means algorithm include: Let the sample data contain n objects, where each object has m-dimensional attributes, and initialize k clustering centers , and define the loss function:
[0076] Let t = 0, 1, 2...d be the number of iterations, and repeat the following process until the loss function converges: For each sample xi, assign it to the nearest center Ci:
[0077] For each cluster, recalculate the center point of this class:
[0078] Use the K-means algorithm to perform unsupervised clustering on the propulsion load after noise reduction and its derivative. By constructing the initial partition boundary of the four-dimensional feature space through the Euclidean distance metric, a coarse-grained modeling of the typical ship operation modes is realized. This process not only reduces the manual annotation cost, but also enhances the physical interpretability of the basic working condition categories through the iterative optimization of the clustering centers, and establishes a stable classification benchmark framework for secondary subdivision.
[0079] In some specific embodiments, the basic operating conditions are divided into 4 categories, and the classification basis is the distribution characteristics of the propulsion load range and the first-order derivative; the basic operating condition labels are basic operating condition 1 to basic operating condition 4.
[0080] A hierarchical operating condition classification system was constructed through the division of four basic operating conditions and the definition of unique labels. The propulsion load range reflects the steady-state energy demand characteristics, and the first-order derivative distribution represents the dynamic response characteristics. The combination of the two realizes the deep integration of the physical mechanism and data characteristics of the ship operation mode, which not only provides an explainable classification basis for unsupervised clustering, but also avoids the cross-contamination problem of multi-label data through label uniqueness constraints, and provides a highly consistent pseudo-annotated data set for secondary segmentation model training.
[0081] Step S4, determine whether the absolute value of the first-order derivative of the propulsion load of each sample after denoising is higher than a preset threshold, summarize the denoised data group corresponding to all samples with yes results into a high-volatility data set, and summarize the propulsion load, first-order derivative of the propulsion load and basic operating condition label corresponding to all samples with no results into a general data set.
[0082] The absolute value of the first-order derivative of the propulsion load is subjected to binary screening through a preset threshold, and the high-fluctuation condition is physically separated from the steady-state condition, which significantly reduces the interference of dynamic mutation conditions on the conventional classification model. At the same time, through the differentiated processing strategy of the data set, multi-dimensional original parameters are retained for high-fluctuation data to capture transient characteristics, and only key parameters are retained for general data to improve computational efficiency, thus achieving a dynamic balance between computing resource allocation and model accuracy, and providing a structured input basis for subsequent multimodal data fusion and refined modeling.
[0083] In some specific embodiments, the preset threshold is 40-50.
[0084] By setting the absolute value threshold of the first-order derivative of the propulsion load to an engineering experience range of 40-50, the sensitivity and specificity balance of this threshold to high-fluctuation conditions is verified based on historical data statistics. This not only effectively captures the boundary characteristics of transient events such as sudden acceleration and emergency braking of ships, but also avoids the false triggering problem caused by conventional wave disturbances. The standardized operation of dynamic condition segmentation is achieved through threshold quantization, which provides clear and configurable screening rules for the subsequent construction of high-fluctuation data sets.
[0085] Step S5, performing secondary subdivision, including: The kernel principal component analysis algorithm is used to uniformly extract the main features of the data in the high volatility data set and the general data set, and then the pre-trained working condition segmentation model is input to output the specific working condition category. The working condition segmentation model is a Bayesian optimized weighted iterative LightGBM model.
[0086] Different from the traditional principal component analysis algorithm, kernel principal component analysis uses the kernel trick to simplify calculations, maps the low-dimensional linearly inseparable input space to a linearly separable high-dimensional feature space, and then uses PCA for dimensionality reduction in the feature space, that is, first increasing the dimension and then reducing the dimension.
[0087] The basis of kernel principal component analysis lies in the inner product transformation of vectors. Let represent the original data with dimension k. First, map the original data to a high-dimensional feature space, and use to represent the mapped data with dimension d. Then, use PCA for dimensionality reduction in the feature space and calculate the covariance matrix of :
[0088] Solve for the eigenvectors and calculate the principal component directions p :
[0089]
[0090] In the formula, represents the coefficient vector; Finally, introduce the kernel function Solve the formula, and project the original data in the principal component direction to extract the main features.
[0091] The sampling technique of the LightGBM model filters the data through the one-sided sampling technique based on the gradient values of the data, retains the large-gradient samples, discards the useless samples, and samples the small-gradient samples, reducing the amount of data in each round of training, thereby improving the training speed. The specific calculation steps are as follows: (1) Calculate the absolute value of the gradient of the training data and sort it from largest to smallest by absolute value; (2) Select the first a% of the samples as the large-gradient sample set A, and select b% of the samples from the remaining samples to form the small-gradient sample set B; (3) Multiply the small-gradient sample set B by the coefficient (1 - a) / b to increase the attention; (4) Recombine A and B to calculate the information gain:
[0092] Among them , , , , n is the total number of samples, G(.) represents the sample gradient, d is the node number, and j is the splitting feature value; The mutually exclusive feature bundling technique of the LightGBM model can effectively combine multiple mutually exclusive features, thereby reducing the number of features. By introducing a deviation constant, the sparse matrix is transformed into a dense matrix, thus reducing the number of features. Without losing feature information, it reduces the feature dimension, thereby reducing the computational cost; The LightGBM model uses the histogram algorithm instead of the pre-sorting algorithm to find split points, effectively utilizing the sparsity of high-dimensional data, converting continuous features into discrete values, and significantly reducing the computational amount. Specifically, it discretizes continuous floating-point feature values into h integers and constructs a histogram with a width of h; when traversing the data, it accumulates statistics in the histogram according to the discretized values as indices; according to the discrete values of the histogram, it traverses to find the optimal split point; The LightGBM model adopts the strategy of growing by leaves. Each time it splits, it selects the leaf with the highest gain among all the leaves at the current same level, which is generally the leaf with the largest amount of data, and then loops until the tree is formed; in practical applications, to avoid overfitting caused by excessive depth, the LightGBM model will set the maximum depth; The Bayesian optimization algorithm is a parameter optimization algorithm, consisting of two key parts: the probabilistic surrogate model and the acquisition function. First, it initializes the prior distribution of the surrogate model, maximizes the acquisition function and obtains the evaluation points, then calculates the objective function value and updates the surrogate function, and finally iteratively solves to obtain the optimal parameter distribution.
[0093] Through kernel principal component analysis, non-linear dimensionality reduction is performed on high-dimensional heterogeneous data, effectively extracting the potential correlation features of propulsion load fluctuations, environmental parameters and battery output, solving the problem of feature loss of traditional linear dimensionality reduction methods under high-fluctuation working conditions. At the same time, combined with the Bayesian optimization framework, the hyperparameter combination of the LightGBM model is dynamically adjusted. Through the global optimization strategy guided by the probability model, the discrimination accuracy of the classification boundary in the overlapping area of complex working conditions is significantly improved, and finally the fine-grained division of five specific working conditions is realized, providing high-confidence working condition label support for ship energy efficiency optimization and fault warning.
[0094] In some specific embodiments, the working condition subdivision model includes the following hierarchical structure: The input layer receives the main features extracted by kernel principal component analysis as input features; The feature processing layer includes a mutually exclusive feature bundling module and a gradient unilateral sampling module, which respectively perform sparse feature compression and high-information sample screening on the input features to obtain optimized features; The decision tree generation layer generates a binary tree structure based on the hyperparameters provided by the Bayesian optimization framework layer, and each split node calculates the information gain through a weighted iterative objective function; The Bayesian optimization framework layer dynamically adjusts the hyperparameter combinations of the decision tree generation layer, including the number of leaf nodes, maximum depth, learning rate, and feature sampling ratio; The output layer maps the leaf node weights through a weighted iterative classifier to generate specific working condition category labels.
[0095] By constructing a multi-level model architecture that includes feature bundling, gradient sampling, and Bayesian optimization, effective compression of high-dimensional sparse features and improvement of information density are achieved. Among them, the mutually exclusive feature bundling module reduces the dimensional redundancy of environmental parameters and battery output parameters, the gradient unilateral sampling module focuses on high-information samples to accelerate model convergence, and the Bayesian optimization framework dynamically adjusts the hyperparameter space through Gaussian process modeling. The three work together to significantly improve the generalization ability and computational efficiency of the model under limited training data.
[0096] In some specific embodiments, the weighted iterative objective function is:
[0097]
[0098]
[0099] In the formula, is the total number of samples; is the sample weight adjustment coefficient; is the cross-entropy loss function; is the output of the th decision tree; is the vector representation of sample ; is the decision tree complexity regularization term; is the constant term; is the confidence of sample ; is the average distance between the feature point and other data of the same category; is the average distance between the feature point and the feature data points of other categories; is the working condition category where it is located; and are constants, set according to the quantity and scale of the training set.
[0100] By introducing a confidence-weighted objective function design, the sample classification confidence is associated with the feature space distribution, and the loss weights of different samples are dynamically adjusted, enabling the model to strengthen the attention to samples with fuzzy boundaries during the training process. At the same time, the risk of overfitting is suppressed through regularization terms and complexity constraints. This design effectively alleviates the interference of class imbalance and noisy labels on model training and improves the recognition recall rate of low-frequency but high-value categories such as emergency working conditions and port working conditions.
[0101] In some specific embodiments, the training steps of the working condition subdivision model include: S501. Obtain the historical operation data of all-electric ships with known specific working condition categories, perform the same operations as in steps S1 - S4 to obtain a training high-fluctuation dataset and a training general dataset. Then, use the kernel principal component analysis algorithm to uniformly extract the main features of the data in the high-fluctuation dataset and the general dataset, and divide them into a training set, a validation set, and a test set according to the ratio of 7:2:1. During the division, ensure the balanced distribution of samples for each specific working condition category through stratified sampling; S502. Initialize the hyperparameters of the working condition subdivision model through the parameter space search strategy optimized by Bayesian, including the number of leaf nodes, the maximum depth, the learning rate, and the feature sampling ratio; S503. Dynamically adjust the hyperparameters through the Bayesian optimization framework layer: Calculate the weighted iterative objective function value on the validation set, generate the posterior probability distribution of the hyperparameters according to the change of the function value, and iteratively update the hyperparameters of the working condition subdivision model; S504. Input the training set into the working condition subdivision model for training, including: Compress and screen the input features through the mutually exclusive feature bundling module and the gradient unilateral sampling module; In the decision tree generation layer, generate a binary tree structure according to the leaf growth strategy, and calculate the information gain for each split node based on the correlation between the first derivative of the propulsion load and the environmental parameters; Based on the sample confidence Dynamically calculate the weight coefficient , update the decision tree structure through the weighted iterative objective function, and output the specific working condition category label; S505. Input the test set into the working condition subdivision model, calculate the classification accuracy of each specific working condition category according to the output of each sample and the actual specific working condition category. If the classification accuracy does not meet the preset conditions, return to step S503 to readjust the hyperparameters and perform iterative training. If it meets the preset conditions, output the final model to obtain the pre-trained working condition subdivision model.
[0102] By using a stratified sampling strategy to balance the operating condition distributions of the training set, validation set, and test set, the problem of model preference caused by data skew is avoided. At the same time, Bayesian optimization is combined to perform probability-guided global search in the hyperparameter space. By means of the acquisition function, the contradiction between exploration and exploitation is balanced, realizing the collaborative optimization of the model convergence speed and the quality of the optimal solution. Finally, through iterative verification, the stability of the model on unknown data is ensured, providing a highly reliable operating condition segmentation model for actual deployment.
[0103] In some specific embodiments, after using kernel principal component analysis to extract the main features, source labels are added to the data from the high-fluctuation dataset and the general dataset respectively, and then input into the operating condition segmentation model.
[0104] By adding source labels to the high-fluctuation and general datasets, prior knowledge of data distribution is embedded in the feature vectors after kernel principal component analysis, enabling the model to distinguish the topological structures of the feature spaces of samples with different fluctuation characteristics, enhancing the ability to differentially process transient and steady-state operating conditions during the classification decision-making process. At the same time, by guiding the feature weight allocation through label information, the sensitivity and discrimination accuracy of the model to short-term high-load modes such as operating conditions are improved.
[0105] In some specific embodiments, kernel principal component analysis maps the original data to a high-dimensional space by introducing a radial basis kernel function, and the number of principal components extracted is 6 - 12.
[0106] The radial basis kernel function (Radial Basis Function, RBF) is a symmetric kernel function based on the distance between samples, with the form of, widely used in machine learning models such as support vector machines (SVMs) and kernel methods to handle non-linearly separable problems.
[0107] By non-linearly mapping the original data to a high-dimensional reproducing kernel Hilbert space through the radial basis kernel function, the problem of dimensionality reduction failure caused by non-linear feature coupling in ship multi-operating condition data in traditional principal component analysis is solved. At the same time, the number of principal components is extended to 6 - 12, fully retaining the interaction information between the dynamic characteristics of the propulsion system and environmental disturbances, providing a low-dimensional and highly discriminative feature representation for the subsequent classification model, and significantly reducing the computational complexity and memory occupancy of model training.
[0108] In some specific embodiments, the specific operating condition categories include low-speed driving conditions, normal navigation conditions, high-speed cruising conditions, operating conditions, and emergency or port conditions. Among them, low-speed driving conditions, normal navigation conditions, and high-speed cruising conditions belong to general operating conditions, and operating conditions, emergency or port conditions belong to high-fluctuation conditions.
[0109] By strictly corresponding five specific working conditions to the actual operation scenarios of ships, a direct mapping relationship between algorithm outputs and engineering decisions is constructed. Among them, the operation conditions cover typical high-power demand scenarios such as crane operation and cargo handling, while emergency or port conditions focus on sudden failures and berthing energy consumption management. This classification system not only meets the multi-objective requirements of ship energy efficiency optimization but also provides a unified and standardized working condition management interface for different departments.
[0110] In a specific embodiment, the multi-condition recognition method for all-electric ships includes: Step S1, obtain the historical operation data of the all-electric ship. The historical operation data is composed of samples at each timestamp, and each sample includes the propulsion load, the first derivative of the propulsion load, propulsion motor parameters, environmental parameters, and power battery output parameters at the corresponding timestamp; Among them, the propulsion motor parameters include the propulsion motor speed and active power, the environmental parameters include wind speed, flow velocity, and water surface wave height, and the power battery output parameters include lithium battery output power and fuel cell output power; Step S2, perform feature extraction and noise reduction on the historical operation data to obtain a denoised data set for each sample, including the denoised propulsion load, the first derivative of the propulsion load, propulsion motor parameters, environmental parameters, and power battery output parameters; Performing feature extraction and noise reduction on the historical operation data includes: Decompose the original operation data into multiple intrinsic modes by variational mode decomposition. The number of intrinsic modes of variational mode decomposition is set to 3 - 7, and the noise tolerance parameter is determined by the residual index method. The steps of variational mode decomposition include: Iteratively solve the variational model by the alternating direction multiplier method and Fourier isometric transformation to obtain the decomposed set of mode functions and the corresponding central frequencies; Calculate the maximum information coefficient between each intrinsic mode and the original data, and retain the intrinsic modes with the maximum information coefficient exceeding the preset threshold as the main signals. The preset threshold of the maximum information coefficient is determined by the grid search method. The maximum information coefficient threshold for the propulsion load data is 0.12. The steps for calculating the maximum information coefficient include: Discretize the intrinsic modes after decomposing the propulsion load data and the original data into a two-dimensional grid space, and calculate the normalized maximum mutual information value as the maximum information coefficient; Table 1 shows the maximum information coefficient values of each intrinsic mode of the propulsion composite data and the original propulsion load data in this embodiment. According to the data in the table, it can be concluded that the maximum information values of different modes are quite different. The smaller the value, the weaker the correlation between the mode and the original propulsion load and the lower the information content; Table 1 Maximum Information Coefficient Table of Intrinsic Modes
[0111] Reconstruct the main body signal and eliminate the interference noise to obtain the noise-reduced data group of each sample. The steps of eliminating the interference noise include: Eliminate the intrinsic mode with the maximum information coefficient lower than the preset threshold as the noise signal, and reconstruct the signal by linearly superposing the remaining intrinsic modes; The formula for reconstructing the main body signal and eliminating the interference noise is:
[0112] In the formula, is the preset threshold of the maximum information coefficient corresponding to the i th intrinsic mode; After reconstructing the main body signal and eliminating the interference noise, the improvement of the maximum information coefficient of each input feature is shown in Table 2: Table 2 Improvement of the maximum information coefficient of input features
[0113] It can be seen that the maximum information coefficients of the processed ship feature data have been greatly improved. Among them, the improvement amplitudes of the daily load and wind speed are relatively large, reaching 28.5% and 26.8% respectively. Followed by the flow velocity, wave height, fuel cell output, etc. The relevant parameters of the propulsion motor have a relatively large maximum information coefficient itself, so the improvement amplitude is relatively small, about 10%. The smallest improvement amplitude is the output of the power lithium battery. This shows that the data processing method of this scheme can retain a large amount of information of the data and eliminate the irrelevant or interfering components; Step S3: Input the propulsion load and the first derivative of the propulsion load after noise reduction of each sample into the K-means clustering algorithm for preliminary clustering, classify them into multiple basic working conditions, and add a unique basic working condition label to each noise-reduced data group; Among them, there are 4 types of basic working conditions, and the classification basis is the distribution characteristics of the propulsion load interval and the first derivative; the basic working condition label is from basic working condition 1 to basic working condition 4 Step S4: Judge whether the absolute value of the first derivative of the propulsion load after noise reduction of each sample is higher than the preset threshold, and the preset threshold is 48; Summarize the noise-reduced data groups corresponding to all samples with the result of yes into a high-fluctuation data set, and summarize the propulsion load, the first derivative of the propulsion load and the basic working condition label corresponding to all samples with the result of no into a general data set; Step S5: Perform secondary subdivision, including: Use the kernel principal component analysis algorithm to uniformly extract the main features of the data in the high-fluctuation dataset and the general dataset. Then, add source tags to the data from the high-fluctuation dataset and the general dataset respectively, and input them into the pre-trained working condition segmentation model to output specific working condition categories, including low-speed driving condition, normal navigation condition, high-speed cruising condition, operation condition, and emergency or port condition. Among them, the low-speed driving condition, normal navigation condition, and high-speed cruising condition belong to general operating conditions, and the operation condition, emergency or port condition belong to high-fluctuation conditions. Among them, kernel principal component analysis maps the original data to a high-dimensional space by introducing a radial basis kernel function, and the number of principal components extracted is 6-12; The working condition segmentation model is a Bayesian-optimized weighted iterative LightGBM model, which includes the following hierarchical structure: Input layer, which receives the main features extracted by kernel principal component analysis as input features; Feature processing layer, which includes a mutually exclusive feature bundling module and a gradient unilateral sampling module, and respectively performs sparse feature compression and high-information sample screening on the input features to obtain optimized features; Decision tree generation layer, based on the hyperparameters provided by the Bayesian optimization framework layer, generates a binary tree structure according to the leaf growth strategy, and calculates the information gain for each split node through a weighted iterative objective function. The weighted iterative objective function is:
[0114]
[0115]
[0116] In the formula, is the total number of samples; is the sample weight adjustment coefficient; is the cross-entropy loss function; is the output of the th decision tree; is the vector representation of the sample is the decision tree complexity regularization term; is a constant term; is the confidence of the sample ; is the average distance between the feature point and other data of the same category; is the average distance between the feature point and the feature data points of other categories; is the working condition category where it is located; and is a constant, set according to the quantity and scale of the training set; The Bayesian optimization framework layer dynamically adjusts the hyperparameter combinations of the decision tree generation layer, including the number of leaf nodes, maximum depth, learning rate, and feature sampling ratio; The output layer maps the leaf node weights through a weighted iterative classifier to generate specific working condition category labels; Figure 2 is the flowchart of the training steps of the working condition subdivision model in this embodiment, as Figure 2 shown, the training steps of the working condition subdivision model include: S501. Obtain the historical operation data of the all-electric ship with known specific working condition categories, perform the same operations as in steps S1 - S4 to obtain the training high-fluctuation dataset and the training general dataset, then use the kernel principal component analysis algorithm to uniformly extract the main features of the data in the high-fluctuation dataset and the general dataset, and then divide them into a training set, a validation set, and a test set according to the ratio of 7:2:1. During the division, stratified sampling is used to ensure the balanced sample distribution of each specific working condition category; S502. Initialize the hyperparameters of the working condition subdivision model through the parameter space search strategy of Bayesian optimization, including the number of leaf nodes, maximum depth, learning rate, and feature sampling ratio; S503. Dynamically adjust the hyperparameters through the Bayesian optimization framework layer: calculate the weighted iterative objective function value on the validation set, generate the posterior probability distribution of the hyperparameters according to the change of the function value, and iteratively update the hyperparameters of the working condition subdivision model; In this factual example, the hyperparameter values finally obtained after iterative update are shown in Table 3: Table 3 Hyperparameter values and optimal values table
[0117] S504. Input the training set into the working condition subdivision model for training, including: Compress and screen the input features through the mutually exclusive feature bundling module and the gradient unilateral sampling module; In the decision tree generation layer, generate a binary tree structure according to the leaf growth strategy, and calculate the information gain for each split node according to the correlation between the first derivative of the propulsion load and the environmental parameters; Based on the sample confidence dynamically calculate the weight coefficient , update the decision tree structure through the weighted iterative objective function, and output specific working condition category labels; S505. Input the test set into the working condition subdivision model, calculate the classification accuracy of each specific working condition category according to the output of each sample and the actual specific working condition category. If the classification accuracy does not meet the preset conditions, return to step S503 to re-adjust the hyperparameters and iterate the training. If it meets the preset conditions, output the final model to obtain the pre-trained working condition subdivision model.
[0118] Use the multi-working condition recognition method of this embodiment to build a working condition recognition framework. The specific parameter settings of the working condition recognition framework are as follows: The variational mode decomposition is constructed by the subpross module. Among them, the optimal variational mode decomposition is used to determine the number of intrinsic mode functions for decomposition KVMD = 7*(3~7), that is, each input feature is decomposed into 3 to 7 intrinsic mode functions, and then the residual exponential index method REI is used to determine the noise tolerance tau; The penalty parameter α is set in the range of 1500 - 2500, and grid search is performed with a step size of 100; The kernel PCA is constructed by the scikit-learn library. According to the actual prediction effect and the sum of variances, the number of principal components is determined to be 12; K-means determines the number of clusters K according to the silhouette coefficient. The closer the silhouette coefficient is to 1, the better the clustering effect. Then, the number of clusters K is selected by the iterative method, as shown in Table 4: Table 4 Parameter settings table of the working condition recognition framework
[0119] Use the working condition recognition method of this embodiment and the common model classification method to conduct a simulation experiment together. The internal index is used to evaluate the accuracy of ship working condition recognition, that is, the attribute characteristics of the data set are used to compare the advantages and disadvantages of the algorithms, and the clustering quality is determined by comparing the average similarity between clusters or the average similarity within clusters; The common model classification methods include K-means mean clustering, K-nearest neighbor algorithm, random forest method, and LightGBM; The specific evaluation criteria are the Calinski-Harabaz index (CH index), Davies-Bouldin Index (DB index), and stability score.
[0120] Among them, the CH index calculates the ratio of the within-cluster distance to the between-cluster distance in a form similar to variance:
[0121] Among them, x is the data set, N is the data volume, and K is the number of categories; Bk and Wk are the between-class and within-class covariance matrices respectively, and the calculation formulas are: ; The DB index is an algorithm for evaluating clustering metrics. This method calculates the average sum of the within-class distances of any two categories divided by the distance between the centers of these two categories, and then finds the maximum value:
[0122]
[0123] where s i represents the sample dispersion in the i-th category, M ij represents the distance between the i-th and j-th categories; The smaller the DB, the smaller the within-class distance and the larger the between-class distance, which means the better the clustering effect; The specific calculation process of the stability score is as follows. First, test all models using the same dataset, and each model runs 10 times; then add a certain amount of noise interference to the dataset and run the models 10 times on the perturbed dataset, and calculate the average similarity between all running results. The formula is:
[0124] where N is the number of runs, C i is the result of the i-th run, C ref is the reference result (using the first result as the reference); The value range of the stability coefficient is [0, 1]. A value of 1 indicates that the clustering result is exactly the same as the first time, and the model has high stability; a value of 0 indicates that the result has nothing to do with the first result, and the model has low stability.
[0125] The operating environment of the simulation experiment is Python 3.7, and the libraries include tensorflow1.13.1, keras 2.24, and sklearn 0.23.2; the computer hardware configuration for running the prediction model is: 12th Gen Intel(R) Core(TM) i5-12400F 2.50 GHz processor, 16GB of onboard RAM, and a 64-bit operating system. Use 15,000 data points as the test set for verification. The test set contains various navigation states of the ship and can cover most situations encountered during the ship's operation.
[0126] In this embodiment, the two-dimensional scatter plot of the propulsion power and its change rate drawn using the preliminary clustering results is as Figure 3 shown, Figure 3 where the abscissa is the propulsion power and the ordinate is the first derivative corresponding to it, that is, the change rate. Points of different colors represent different categories. Through Figure 3The characteristics of the preliminary classification of K-means can be summarized as follows: The dataset is horizontally divided into four basic operating condition categories mainly based on the propulsion power, and the change rate has little influence on the category distinction; The basic parameters of the 4 basic operating condition categories formed by the preliminary clustering are shown in Table 5: Table 5 Basic Operating Condition Parameter Table
[0127] Summarizing Table 5, it can be seen that from basic operating condition 1 to basic operating condition 4, the average propulsion loads of the four basic operating conditions gradually increase. The basic operating condition intervals are adjacent to each other, and the differences in the average and maximum change rates are not significant. Among them, basic operating condition 3 has the largest amount of data, reaching 40%. At the same time, from the data proportion and the proportion of fluctuating data in Table 5, it can be seen that although the amount of data in basic operating condition 4 is small, the proportion of fluctuating data is relatively high; The two-dimensional scatter plot of the propulsion power and its change rate drawn using the secondary subdivision results is as Figure 4 shown. By comparing Figure 4 and Figure 3 it can be seen that in Figure 4 , the basic operating condition categories with horizontal distribution obtained by the preliminary clustering are simplified from 4 to 3; The data points with high change rates and the data with low change rates are reclassified; The number of categories increases, forming two new operating conditions with high volatility; The basic parameters of the 5 specific operating condition categories formed by the secondary subdivision are shown in Table 6: Table 6 Operating Condition Parameter Table in the Secondary Subdivision Stage
[0128] It can be seen that under the low-speed driving condition, the propulsion load remains in a relatively low range, the output powers of the fuel cell and the lithium battery are low, and at this time the ship behavior is to drive at a relatively low ship speed; Compared with the low-speed driving condition, the propulsion load and the battery output power increase in the normal navigation condition, and the average change rate of the propulsion load is similar. At this time, the ship is shown to be sailing in open waters; When in the high-speed cruise condition, the propulsion load can reach the rated output, and the average output power of the battery rises. At this time, the ship is shown to complete the cruise task at a relatively high ship speed; The above three operating conditions have the same characteristics, including a low proportion of fluctuating data (the highest is 10%), low average and maximum change rates of the propulsion load, and the fuel cell is the main power output. Combining the ship behavior, they are classified as general operating conditions; Different from the general operating conditions, the average and maximum values of the propulsion load change rate in the remaining conditions are relatively high, the propulsion load range is large, the proportion of fluctuating data is high, and the power battery is the main power output. Among them, in the operation condition, the proportion of fluctuating data reaches 60.7%. Compared with the high-speed cruise condition, the average propulsion load change rate increases by 61.2%. At this time, the ship is carrying goods or passengers; in the emergency or port condition, the proportion of fluctuating data is as high as 75.4%, and the average propulsion load change rate increases by 108% compared with the high-speed cruise condition. At this time, the ship is in extreme weather or entering or leaving the port. Based on the above characteristic analysis, the 5 detailed conditions are divided into 2 categories, namely the general operating condition and the high-fluctuation condition. It can be seen that through secondary subdivision, some large-fluctuation data points and low-fluctuation data points are distinguished, and the high-fluctuation condition and the general operating condition are successfully distinguished.
[0129] In this embodiment, the basic condition classification diagram of the all-electric ship under a continuous working time is as Figure 5 shown, and the specific condition category classification diagram of the all-electric ship under a continuous working time is as Figure 6 shown. Figure 5 and Figure 6 both include 2000 data points of the all-electric ship under the same continuous working time. Among them, the line segments of different colors represent different condition categories identified by the model, and the cross signs represent the connection points between different conditions for observing the distribution of conditions more clearly.
[0130] From Figure 5 it can be seen that the initial identification feature is a parallel distribution formed based on the propulsion power. Corresponding to Figure 3 , in the initial K-means identification stage, due to the isotropy of the method, the load change rate cannot be effectively concerned, resulting in the repeated appearance of multiple different categories in a continuous curve; while through Figure 6 it can be seen that the secondary subdivision ensures the continuity of the conditions well.
[0131] The simulation experiment results are shown in Table 7. It should be particularly noted that in Table 7, the multi-condition identification method of this embodiment is abbreviated as K-Bo-LightGBM: Table 7 Comparison Table of Simulation Experiment Results
[0132] As can be seen from Table 7, the CH index of the multi-condition recognition method in this embodiment is the highest and the DB index is the lowest. In particular, compared with the K-means method and LightGBM, the CH index of the multi-condition recognition method in this embodiment is increased by 14% and 27% respectively, and the DB index is decreased by 6% and 17% respectively. In terms of the stability score, the highest of the multi-condition recognition method in this embodiment is 0.93.
[0133] The above simulation experiment results reflect that the multi-condition recognition method of this application has strong reliability and high recognition stability when dealing with environmental interference and outliers.
[0134] The following are embodiments of the multi-condition recognition system of an all-electric ship provided by the embodiments of the present disclosure. The multi-condition recognition system of the all-electric ship and the multi-condition recognition methods of the all-electric ship in the above embodiments belong to the same inventive concept. For the details not described in detail in the embodiments of the multi-condition recognition system of the all-electric ship, reference may be made to the embodiments of the multi-condition recognition method of the all-electric ship.
[0135] Now, the mobile terminals implementing the embodiments of the present application will be described with reference to the drawings. In the following description, suffixes such as "module", "component", or "unit" used to represent elements are only for the convenience of description of the embodiments of the present application, and they have no specific meaning in themselves. Therefore, "module" and "component" can be used interchangeably.
[0136] As Figure 7 shown, the multi-condition recognition system of the all-electric ship includes: A data acquisition module, configured to obtain the historical operation data of the all-electric ship; A data processing module, configured to perform feature extraction and noise reduction on the historical operation data to obtain a noise-reduced data group for each sample; A preliminary clustering module, configured to input the propulsion load and the first derivative of the propulsion load after noise reduction of each sample into the K-means clustering algorithm for preliminary clustering, classify them into multiple basic conditions, and add a unique basic condition label to each noise-reduced data group; A judgment classification module, configured to judge whether the absolute value of the first derivative of the propulsion load after noise reduction of each sample is higher than a preset threshold, summarize the noise-reduced data groups corresponding to all samples with the result being yes into a high-fluctuation data set, and summarize the propulsion load, the first derivative of the propulsion load, and the basic condition label corresponding to all samples with the result being no into a general data set; A secondary subdivision module, configured to uniformly extract the main features of the data in the high-fluctuation data set and the general data set using the kernel principal component analysis algorithm, and then input them into a pre-trained condition subdivision model to output specific condition categories.
[0137] The multi-condition recognition system of the all-electric ship in the integrated energy system of this embodiment is used to implement the multi-condition recognition method of the all-electric ship. The steps include: S1. Obtain the historical operation data of the all-electric ship. The historical operation data is composed of samples at each time stamp. Each sample includes the propulsion load, the first derivative of the propulsion load, the propulsion motor parameters, the environmental parameters, and the power battery output parameters at the corresponding time stamp. S2. Extract features and denoise the historical operation data to obtain the denoised data group of each sample, including the denoised propulsion load, the first derivative of the propulsion load, the propulsion motor parameters, the environmental parameters, and the power battery output parameters. S3. Input the denoised propulsion load and the first derivative of the propulsion load of each sample into the K-means clustering algorithm for preliminary clustering, classify them into multiple basic conditions, and add a unique basic condition label to each denoised data group. S4. Judge whether the absolute value of the first derivative of the denoised propulsion load of each sample is higher than the preset threshold. Summarize the denoised data groups corresponding to all samples with the result of yes into a high-fluctuation data set, and summarize the propulsion load, the first derivative of the propulsion load, and the basic condition label corresponding to all samples with the result of no into a general data set. S5. Perform secondary subdivision, including: Use the kernel principal component analysis algorithm to uniformly extract the main features of the data in the high-fluctuation data set and the general data set, and then input them into the pre-trained condition subdivision model, and output the specific condition categories. The condition subdivision model is a weighted iterative LightGBM model optimized by Bayesian.
[0138] This application also provides an electronic device for implementing each embodiment of this application. The electronic device includes a memory, a processor, and a computer program stored on the memory and executable on the processor.
[0139] Figure 8 The hardware structure diagram of an electronic device for implementing each embodiment of this application.
[0140] The electronic device includes, but is not limited to, components such as a processor and a memory. Those skilled in the art can understand that the structure of the electronic device involved in the embodiments of this application does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or have different component arrangements.
[0141] In the embodiments of the present application, the electronic device includes, but is not limited to, a laptop computer, a desktop computer, a workbench, a personal digital assistant, a server, a blade server, a mainframe computer, and other suitable computers. The electronic device may also represent various forms of mobile devices and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the embodiments of the present application described herein and / or claimed.
[0142] In the embodiments of the present application, the processor may be implemented by using at least one of an application specific integrated circuit (ASIC), a digital signal processor (DSP), a digital signal processing device (DSPD), a processor, a controller, a microcontroller, a microprocessor, and an electronic unit designed to execute the functions described herein. In some cases, such an implementation may be implemented in the controller. For a software implementation, an implementation of a process or function may be implemented with a separate software module that permits execution of at least one function or operation. The software code may be implemented by a software application (or program) written in any suitable programming language, and the software code may be stored in a memory and executed by the controller.
[0143] In addition, the electronic device includes some functional modules not shown herein, which will not be elaborated herein.
[0144] Those skilled in the art can understand that various aspects of the electronic device provided by the present application can be implemented as a system, a method, or a program product. Therefore, various aspects of the present disclosure can be specifically implemented in the following forms, namely: a complete hardware implementation, a complete software implementation (including firmware, microcode, etc.), or an implementation combining hardware and software aspects, which can be collectively referred to as "circuit", "module", or "system" herein.
[0145] The present application also provides a storage medium in which a program product capable of implementing the multi-condition recognition method of an all-electric ship is stored. In some possible implementation manners, various aspects of the present disclosure may also be implemented in the form of a program product, which includes program code. When the program product runs on a terminal device, the program code is used to cause the terminal device to execute the steps according to various exemplary embodiments of the present disclosure described in the "Exemplary Method" section of this specification.
[0146] The storage medium may adopt any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may, for example, but not be limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0147] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be obvious to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to these embodiments shown herein, but rather should be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A multi-condition recognition method for all-electric ships, characterized in that, Including: S1. Obtain the historical operation data of the all-electric ship. The historical operation data is composed of samples at each timestamp. Each sample includes the propulsion load, the first derivative of the propulsion load, the propulsion motor parameters, the environmental parameters, and the power battery output parameters at the corresponding timestamp; S2. Perform feature extraction and noise reduction on the historical operation data to obtain the noise-reduced data group of each sample, including the noise-reduced propulsion load, the first derivative of the propulsion load, the propulsion motor parameters, the environmental parameters, and the power battery output parameters; S3. Input the noise-reduced propulsion load and the first derivative of the propulsion load of each sample into the K-means clustering algorithm for preliminary clustering, classify them into multiple basic working conditions, and add a unique basic working condition label to each noise-reduced data group; S4. Judge whether the absolute value of the first derivative of the noise-reduced propulsion load of each sample is higher than the preset threshold. Summarize the noise-reduced data groups corresponding to all samples with the result of "yes" into the high-fluctuation data set, and summarize the propulsion load, the first derivative of the propulsion load, and the basic working condition label corresponding to all samples with the result of "no" into the general data set; S5. Perform secondary subdivision, including: Use the kernel principal component analysis algorithm to uniformly extract the main features of the data in the high-fluctuation data set and the general data set, and then input them into the pre-trained working condition subdivision model to output the specific working condition category. The working condition subdivision model is a weighted iterative LightGBM model optimized by Bayesian; 2. The multi-condition recognition method according to claim 1, characterized in that, In step S2, performing feature extraction and noise reduction on the historical operation data includes: Decompose the original operation data into multiple intrinsic modes through variational mode decomposition; Calculate the maximum information coefficient between each intrinsic mode and the original data, and retain the intrinsic modes with the maximum information coefficient exceeding the preset threshold as the main signals; Reconstruct the main signals and eliminate the interference noise to obtain the noise-reduced data group of each sample.
3. The multi-condition recognition method according to claim 2, wherein The steps of variational mode decomposition include: Iteratively solve the variational model through the alternating direction multiplier method and the Fourier isometric transform to obtain the decomposed set of mode functions and the corresponding central frequencies; The steps of calculating the maximum information coefficient include: Discretize the intrinsic modes after decomposing the propulsion load data and the original data into a two-dimensional grid space, and calculate the normalized maximum mutual information value as the maximum information coefficient; The steps of eliminating the interference noise include: Regard the intrinsic modes with the maximum information coefficient lower than the preset threshold as noise signals and eliminate them, and reconstruct the signals by linearly superposing the retained intrinsic modes.
4. The multi-condition recognition method according to claim 1, wherein In step S5, the working condition subdivision model includes the following hierarchical structure: Input layer, receiving the main features extracted by the kernel principal component analysis as input features; Feature processing layer, including a mutually exclusive feature bundling module and a gradient unilateral sampling module, respectively performing sparse feature compression and high-information sample screening on the input features to obtain optimized features; Decision tree generation layer, generating a binary tree structure according to the leaf growth strategy based on the hyperparameters provided by the Bayesian optimization framework layer, and calculating the information gain of each split node through the weighted iterative objective function; Bayesian optimization framework layer, dynamically adjusting the combination of hyperparameters of the decision tree generation layer, including the number of leaf nodes, the maximum depth, the learning rate, and the feature sampling ratio; Output layer, mapping the leaf node weights through the weighted iterative classifier to generate the specific working condition category label.
5. The multi-condition recognition method according to claim 4, characterized in that, The weighted iterative objective function is as follows: In the formula, is the total number of samples; is the sample weight adjustment coefficient; is the cross-entropy loss function; is the output of the th decision tree; is the vector representation of the sample ; is the regularization term for the decision tree complexity; is the constant term; is the sample confidence; is the average distance between the feature point and other data of the same category; is the average distance between the feature point and the feature data points of other categories; For the working condition category where it is located; and is a constant, which is set according to the quantity and scale of the training set.
6. The multi-condition recognition method according to claim 4, wherein In step S5, the training steps of the working condition subdivision model include: S501. Obtain the historical operation data of the all-electric ship with known specific working condition categories, perform the same operations as in steps S1 - S4 to obtain the training high-fluctuation dataset and the training general dataset, then use the kernel principal component analysis algorithm to uniformly extract the main features of the data in the high-fluctuation dataset and the general dataset, and then divide them into a training set, a validation set, and a test set according to the ratio of 7:2:
1. During the division, ensure the balanced sample distribution of each specific working condition category through stratified sampling; S502. Initialize the hyperparameters of the working condition subdivision model through the parameter space search strategy optimized by Bayesian, including the number of leaf nodes, the maximum depth, the learning rate, and the feature sampling ratio; S503. Dynamically adjust the hyperparameters through the Bayesian optimization framework layer: calculate the weighted iterative objective function value on the validation set, generate the posterior probability distribution of the hyperparameters according to the change of the function value, and iteratively update the hyperparameters of the working condition subdivision model; S504. Input the training set into the working condition subdivision model for training, including: Compress and screen the input features through the mutually exclusive feature bundling module and the gradient unilateral sampling module; In the decision tree generation layer, generate a binary tree structure according to the leaf growth strategy, and calculate the information gain for each split node according to the correlation between the first derivative of the propulsion load and the environmental parameters; Based on sample confidence Dynamically calculate the weight coefficient , update the decision tree structure by weighted iteration of the objective function, and output the specific working condition category label; S505. Input the test set into the working condition subdivision model, calculate the classification accuracy of each specific working condition category according to the output of each sample and the actual specific working condition category. If the classification accuracy does not meet the preset conditions, return to step S503 to readjust the hyperparameters and perform iterative training. If it meets the preset conditions, output the final model to obtain the pre-trained working condition subdivision model.
7. The multi-condition recognition method according to claim 5, characterized in that, The specific working condition categories include the low-speed driving condition, the normal navigation condition, the high-speed cruising condition, the operation condition, and the emergency or port condition. Among them, the low-speed driving condition, the normal navigation condition, and the high-speed cruising condition belong to the general operation conditions, and the operation condition and the emergency or port condition belong to the high-fluctuation conditions.
8. A multi-condition recognition system for an all-electric ship, characterized in that, For implementing the multi-condition recognition method as described in any one of claims 1 - 7, it includes: A data acquisition module for obtaining the historical operation data of the all-electric ship; A data processing module for performing feature extraction and noise reduction on the historical operation data to obtain the noise-reduced data group of each sample; A preliminary clustering module for inputting the propulsion load and the first derivative of the propulsion load after noise reduction of each sample into the K-means clustering algorithm for preliminary clustering, classifying them into multiple basic working conditions, and adding a unique basic working condition label to each noise-reduced data group; A judgment classification module for judging whether the absolute value of the first derivative of the propulsion load after noise reduction of each sample is higher than a preset threshold, summarizing the noise-reduced data groups corresponding to all samples with the result being yes into a high-fluctuation dataset, and summarizing the propulsion load, the first derivative of the propulsion load, and the basic working condition label corresponding to all samples with the result being no into a general dataset; A secondary subdivision module for using the kernel principal component analysis algorithm to uniformly extract the main features of the data in the high-fluctuation dataset and the general dataset, and then inputting them into the pre-trained working condition subdivision model to output the specific working condition category.
9. An electronic device, characterized in that, It includes a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the multi-condition recognition method according to any one of claims 1-7.
10. A storage medium, characterized in that, A computer program is stored on a storage medium. When the computer program is executed by a processor, it implements the steps of the multi-condition recognition method according to any one of claims 1-7.
Citation Information
Patent Citations
A loader work condition identification model construction and identification method thereof
CN109359524A
Comprehensive power load prediction method for electric propulsion ship
CN112389607A
Ship working condition online identification method and system based on random forest algorithm
CN117892230A
Remote control tower air traffic controller visual fatigue monitoring method
CN119969950A
Systems and Methods for Deriving and Optimizing Classifiers from Multiple Datasets
US20200303078A1
Cited By
Model hyper-parameter determination method and device, electronic equipment and medium
CN120893528A
Ship power system load prediction method, system, equipment and medium
CN121055328A
Intelligent bridge crane fault diagnosis method and early warning system based on deep learning
CN121959389A
A Deep Learning-Based Fault Diagnosis Method and Early Warning System for Intelligent Bridge Cranes
CN121959389B