Fuel cell membrane electrode performance attenuation prediction method and system based on deep learning
Through deep learning methods, combining Bayesian optimization and multi-layer perceptron, gated cycle unit and multi-head attention mechanism, a hybrid fuel cell voltage prediction model is built, solving the problems of low efficiency and limited prediction accuracy in the existing technology, and achieving efficient and accurate prediction of fuel cell voltage attenuation.
Patent Information
- Application Number
- CN202510622848.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-15
- Publication Date
- 2025-08-29
AI Technical Summary
The existing fuel cell voltage prediction methods have problems such as low efficiency of hyperparameters relying on manual settings, difficulty in capturing short-term fluctuations and long-term trends at the same time, and instability in the training process, which affects the prediction accuracy.
Using a deep learning-based method, the optimal hyperparameter combination is selected through Bayesian optimization, combined with multi-layer perceptrons, gated cycle units and multi-head attention mechanisms, a hybrid fuel cell voltage prediction model is constructed, fuel cell operation data is obtained and data feature preprocessing is carried out to capture the short-term fluctuations and long-term evolution trends of voltage attenuation.
It realizes efficient and accurate prediction of the fuel cell voltage attenuation process, improves the prediction accuracy and stability of the model, and can find the optimal solution in fewer iterations.
Smart Images

Figure CN120561452A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of fuel cell voltage prediction, and in particular to a method and system for predicting fuel cell membrane electrode performance attenuation based on deep learning. Background Art
[0002] Fuel cells, particularly proton exchange membrane fuel cells (PEMFCs), are widely used in clean energy applications such as automotive propulsion and distributed power generation due to their high efficiency, low operating temperature, rapid response, and zero emissions. However, over long-term operation, their output voltage can gradually decrease due to factors such as material aging, catalyst degradation, and humidity and temperature fluctuations. This can affect system efficiency and stability, and may even lead to failure or premature failure. Therefore, developing an efficient and accurate method for predicting voltage decay is crucial for fuel cell lifespan management and operational optimization.
[0003] Currently, voltage prediction methods are primarily categorized into mechanism-based models and data-driven models. The former relies on complex physical modeling and has limited applicability; the latter, relying on extensive operational data, offers advantages such as flexible modeling and strong adaptability, and has become a research hotspot. However, existing data-driven methods suffer from three major issues: first, hyperparameters rely on manual setup, resulting in low optimization efficiency; second, it is difficult to simultaneously capture short-term voltage fluctuations and long-term trends; and third, the training process is unstable, limiting prediction accuracy. Summary of the Invention
[0004] In order to solve the above technical problems, the purpose of the present invention is to provide a fuel cell membrane electrode performance attenuation prediction method and system based on deep learning, which can simultaneously capture the short-term fluctuations and long-term evolution trends of voltage attenuation, thereby achieving efficient and accurate prediction of the fuel cell voltage attenuation process.
[0005] The first technical solution adopted by the present invention is: a method for predicting fuel cell membrane electrode performance degradation based on deep learning, comprising the following steps:
[0006] Acquire fuel cell operation data and perform data feature preprocessing to obtain multidimensional time series features of the fuel cell operation data;
[0007] The optimal hyperparameter combination is selected through Bayesian optimization, and a hybrid fuel cell voltage prediction model is constructed by combining a multilayer perceptron, a gated recurrent unit, and a multi-head attention mechanism.
[0008] The multidimensional time series characteristics of fuel cell operation data are input into the hybrid fuel cell voltage prediction model for voltage prediction, and the fuel cell voltage prediction value is obtained to realize the fuel cell membrane electrode performance attenuation prediction.
[0009] Furthermore, the step of acquiring the fuel cell operation data and performing data feature preprocessing to obtain a key feature data set of the fuel cell specifically includes:
[0010] Acquiring fuel cell operation data, wherein the fuel cell operation data includes time, total voltage, current density, air outlet pressure, air flow, hydrogen flow, and air humidity;
[0011] The fuel cell operation data is cleaned and spliced in turn to obtain a complete fuel cell operation data set;
[0012] The complete operating data set of the fuel cell is smoothed by using a wavelet denoising method to obtain a denoised complete operating data set of the fuel cell;
[0013] Perform feature selection on the denoised fuel cell complete operation data set, and use the Pearson correlation coefficient to filter the eigenvalues to obtain the key feature data set of the fuel cell.
[0014] The key feature data set of the fuel cell is format converted to obtain the multi-dimensional time series characteristics of the fuel cell operation data.
[0015] Furthermore, the step of selecting the optimal hyperparameter combination through Bayesian optimization, combining a multilayer perceptron, a gated recurrent unit, and a multi-head attention mechanism to construct a hybrid fuel cell voltage prediction model specifically includes:
[0016] A multilayer perceptron is used as a feature extraction module and a gated recurrent unit is used as a time series modeling module. A multi-head attention mechanism is introduced to construct an initial hybrid fuel cell voltage prediction model.
[0017] Based on the Bayesian optimization algorithm, a set of initial hyperparameter combinations are selected and evaluated through the objective function to obtain the initial observation data;
[0018] Based on the initial observation data, a surrogate model of the objective function is constructed through Gaussian process regression;
[0019] Based on the proxy model of the objective function, the evaluation point for the next optimization step is selected through the acquisition function;
[0020] Substitute the evaluation points optimized in the next step into the initial observation data, update the surrogate model of the objective function, and obtain the optimal hyperparameter combination;
[0021] The optimal hyperparameter combination is embedded into the initial hybrid fuel cell voltage prediction model to construct a hybrid fuel cell voltage prediction model.
[0022] Furthermore, the step of inputting the multi-dimensional time series characteristics of the fuel cell operation data into the hybrid fuel cell voltage prediction model to perform voltage prediction, obtain the fuel cell voltage prediction value, and realize the fuel cell membrane electrode performance attenuation prediction specifically includes:
[0023] Inputting the multidimensional time series features of the fuel cell operation data into a hybrid fuel cell voltage prediction model, wherein the hybrid fuel cell voltage prediction model includes a feature extraction module, a time series modeling module, an attention mechanism, a splicing module and a fully connected layer;
[0024] Based on the feature extraction module of the hybrid fuel cell voltage prediction model, the multi-dimensional time series features of the fuel cell operation data are extracted to obtain the high-dimensional features of the fuel cell operation data;
[0025] Based on the time series modeling module of the hybrid fuel cell voltage prediction model, the high-dimensional features of the fuel cell operation data are captured and processed in time series to obtain the time series features of the fuel cell operation data;
[0026] Based on the attention mechanism of the hybrid fuel cell voltage prediction model, the correlation between each time step of the time series characteristics of the fuel cell operation data is calculated to obtain the weighted characteristics of the fuel cell operation data;
[0027] Based on the splicing module of the hybrid fuel cell voltage prediction model, the high-dimensional features of the fuel cell operation data, the time series features of the fuel cell operation data, and the weight features of the fuel cell operation data are fused through residual connection to obtain the comprehensive features of the fuel cell operation data;
[0028] Based on the fully connected layer of the hybrid fuel cell voltage prediction model, feature mapping is performed on the comprehensive characteristics of the fuel cell operation data to obtain the fuel cell voltage prediction value, thereby realizing the prediction of fuel cell membrane electrode performance attenuation.
[0029] Furthermore, the feature extraction module based on the hybrid fuel cell voltage prediction model extracts features from the multi-dimensional time series features of the fuel cell operation data to obtain high-dimensional features of the fuel cell operation data, which specifically includes:
[0030] Inputting the multidimensional time series features of the fuel cell operation data into the feature extraction module of the hybrid fuel cell voltage prediction model;
[0031] Performing linear transformation processing on the multidimensional time series characteristics of the fuel cell operation data to obtain the transformed multidimensional time series characteristics of the fuel cell operation data;
[0032] Adding a bias vector to the transformed multi-dimensional time series features of the fuel cell operation data to obtain preliminary high-dimensional features of the fuel cell operation data;
[0033] The high-dimensional features of the preliminary fuel cell operation data are captured by performing nonlinear mapping relationship processing through a nonlinear activation function to obtain the high-dimensional features of the fuel cell operation data.
[0034] Furthermore, the time series modeling module based on the hybrid fuel cell voltage prediction model performs time series capture processing on the high-dimensional features of the fuel cell operation data to obtain the time series features of the fuel cell operation data. This step specifically includes:
[0035] Inputting high-dimensional features of fuel cell operation data into a time series modeling module of a hybrid fuel cell voltage prediction model;
[0036] Get the initial hidden state of the time series modeling module;
[0037] Calculate the update gate value and reset gate value of the time series modeling module based on the high-dimensional features and initial hidden state of the fuel cell operation data;
[0038] The initial hidden state is adjusted by resetting the gate value, and the candidate hidden state is obtained by calculation based on the adjusted hidden state combined with the high-dimensional features of the fuel cell operation data;
[0039] According to the value of the update gate, the candidate hidden state is fused with the initial hidden state to obtain the time series characteristics of the fuel cell operation data.
[0040] Furthermore, the attention mechanism based on the hybrid fuel cell voltage prediction model calculates the correlation between each time step of the time series characteristics of the fuel cell operation data to obtain the weight characteristics of the fuel cell operation data, which specifically includes:
[0041] An attention mechanism that inputs the time series features of fuel cell operation data into the hybrid fuel cell voltage prediction model;
[0042] The time series features of the fuel cell operation data are transformed through three different linear transformation layers to obtain the corresponding query matrix, key matrix and value matrix;
[0043] Divide the query matrix, key matrix, and value matrix into multiple subspaces and perform scaled dot product attention calculations to obtain several weighted value matrices;
[0044] Several weighted value matrices are spliced and fused to obtain the weight characteristics of fuel cell operation data.
[0045] The second technical solution adopted by the present invention is: a fuel cell membrane electrode performance degradation prediction system based on deep learning, comprising:
[0046] The first module is used to obtain the fuel cell operation data and perform data feature preprocessing to obtain the multi-dimensional time series features of the fuel cell operation data;
[0047] The second module is used to select the optimal hyperparameter combination through Bayesian optimization, combining multi-layer perceptron, gated recurrent unit and multi-head attention mechanism to build a hybrid fuel cell voltage prediction model;
[0048] The third module is used to input the multi-dimensional time series characteristics of the fuel cell operation data into the hybrid fuel cell voltage prediction model to perform voltage prediction, obtain the fuel cell voltage prediction value, and realize the fuel cell membrane electrode performance attenuation prediction.
[0049] The beneficial effects of the method and system of the present invention are as follows: the present invention obtains the operating data of the fuel cell and performs data feature preprocessing, and then selects the optimal hyperparameter combination through Bayesian optimization, combines the multi-layer perceptron, the gated recurrent unit and the multi-head attention mechanism, and constructs a hybrid fuel cell voltage prediction model to simultaneously capture the short-term fluctuations and long-term evolution trends of voltage attenuation. Bayesian optimization can find the optimal solution of the hybrid fuel cell voltage prediction model within a relatively small number of iterations, thereby improving the model prediction accuracy and stability. Finally, the multi-dimensional time series characteristics of the fuel cell operating data are input into the hybrid fuel cell voltage prediction model for voltage prediction, thereby achieving efficient and accurate prediction of the fuel cell voltage attenuation process. BRIEF DESCRIPTION OF THE DRAWINGS
[0050] Figure 1 This is a flowchart of the steps of the fuel cell membrane electrode performance degradation prediction method based on deep learning of the present invention;
[0051] Figure 2 This is a structural block diagram of the fuel cell membrane electrode performance degradation prediction system based on deep learning of the present invention;
[0052] Figure 3 1 is a flow chart of a wavelet denoising process provided by a specific embodiment of the present invention;
[0053] Figure 4 1. It is a thermodynamic diagram of the correlation between key characteristics of a fuel cell provided by a specific embodiment of the present invention;
[0054] Figure 5 is a schematic diagram of a feature extraction module provided in a specific embodiment of the present invention;
[0055] Figure 6 is a schematic diagram of a time series modeling module provided by a specific embodiment of the present invention;
[0056] Figure 7 Schematic diagram of the Bayesian optimization process provided by a specific embodiment of the present invention;
[0057] Figure 8 is a schematic diagram of a hybrid fuel cell voltage prediction model provided by a specific embodiment of the present invention;
[0058] Figure 9 It is a flowchart of voltage prediction provided by a specific embodiment of the present invention. DETAILED DESCRIPTION
[0059] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. The step numbers in the following embodiments are provided for ease of description only and do not limit the order of the steps. The order of execution of the steps in the embodiments can be adaptively adjusted based on the understanding of those skilled in the art.
[0060] Reference Figure 1 The present invention provides a method for predicting fuel cell membrane electrode performance degradation based on deep learning, which includes the following steps:
[0061] S100, acquiring fuel cell operation data and performing data feature preprocessing to obtain multi-dimensional time series features of the fuel cell operation data;
[0062] S110, acquiring fuel cell operation data, wherein the fuel cell operation data includes time, total voltage, current density, air outlet pressure, air flow, hydrogen flow, and air humidity;
[0063] In this embodiment, the degradation of a fuel cell is accompanied by microstructural changes, which directly affect the dynamic characteristics of the voltage. To extract features related to voltage decay, this embodiment first collected fuel cell operating data from multiple datasets, including the following key features: time, total voltage, current density, air outlet pressure, air flow, hydrogen flow, and air humidity.
[0064] S120, performing data cleaning and data splicing processing on the fuel cell operation data in sequence to obtain a complete fuel cell operation data set;
[0065] In this example, since the data comes from multiple independent datasets, we first check the temporal continuity to ensure seamless connection between the datasets. We then merge the multiple datasets into a complete dataset through timestamp alignment and data splicing, and reset the index to ensure data index continuity.
[0066] S130, performing data smoothing processing on the complete operating data set of the fuel cell by a wavelet denoising method to obtain a denoised complete operating data set of the fuel cell;
[0067] In this embodiment, if Figure 3 As shown in the figure, during the data acquisition process, noise is present in the raw data due to signal fluctuations, sensor errors, and the operating environment. This noise can interfere with the model's ability to capture voltage decay trends. To address this issue, the present invention uses wavelet denoising technology to smooth the raw data. First, an appropriate symlet wavelet and decomposition level are selected, and a soft thresholding method is used to remove high-frequency noise components. Then, an inverse wavelet transform is used to reconstruct the signal, ensuring that the main trends are preserved while reducing noise interference.
[0068] S140, performing feature selection processing on the denoised fuel cell complete operation data set, and performing feature value screening processing using the Pearson correlation coefficient to obtain a key feature data set of the fuel cell;
[0069] In this embodiment, to effectively extract characteristic variables highly correlated with fuel cell voltage decay, the present invention systematically analyzes the correlations between various physical quantities and the target variable. The analysis targets include original operating parameters (such as time, voltage, current density, hydrogen inlet and outlet temperatures, air inlet and outlet temperatures, cooling water inlet and outlet temperatures, hydrogen inlet and outlet pressures, air inlet and outlet pressures, hydrogen inlet and outlet flow rates, air inlet and outlet flow rates, cooling water flow rates, and intake air humidity) and structural characteristics (such as the interaction term between current density and air flow rates, and the time-difference term of voltage).
[0070] To quantify the linear relationship between each feature and the voltage decay trend, the embodiment of the present invention uses the Pearson correlation coefficient to screen the feature values. This index reflects the degree of linear correlation between variables by calculating the ratio of the covariance and standard deviation of the feature value and the target value. Its calculation formula is:
[0071]
[0072] Where X and Y are the eigenvalue and target value respectively. and The value of the Pearson coefficient ranges from -1 to 1. The closer the absolute value is to 1, the stronger the correlation is, and the closer it is to 0, the weaker the correlation is.
[0073] By calculating and ranking the correlation coefficients between all candidate features and the target variable, the embodiment of the present invention selects the nine key features with the strongest correlation as the core input variables of the model. These features include time, current density, air outlet pressure, air flow, hydrogen flow, air humidity, structural interaction features, and differential features. In addition, by drawing a feature correlation heat map, the degree of mutual correlation between the input features is visualized and analyzed, thereby avoiding the problem of excessive collinearity, ensuring the independence and representativeness of the model input, and improving the stability and prediction performance of the subsequent modeling process. Figure 4 shown.
[0074] S150 , performing format conversion processing on a key feature data set of the fuel cell to obtain multi-dimensional time series features of the fuel cell operation data.
[0075] Specifically, the data is structured into a time series format, with appropriate time steps and strides set to generate sequence data containing multiple time steps. The dataset is then split into a training set and a test set in chronological order. The training set is used for model training, and the test set is used to evaluate model performance.
[0076] S200, select the optimal hyperparameter combination through Bayesian optimization, combine multi-layer perceptron, gated recurrent unit and multi-head attention mechanism to build a hybrid fuel cell voltage prediction model;
[0077] Specifically, a multilayer perceptron is used as a feature extraction module and a gated recurrent unit is used as a time series modeling module, and a multi-head attention mechanism is introduced to construct an initial hybrid fuel cell voltage prediction model; based on the Bayesian optimization algorithm, a set of initial hyperparameter combinations are selected and evaluated through the objective function to obtain initial observation data; based on the initial observation data, a proxy model of the objective function is constructed through Gaussian process regression; based on the proxy model of the objective function, the evaluation point for the next optimization is selected through the acquisition function; the evaluation point for the next optimization is substituted into the initial observation data, the proxy model of the objective function is updated, and the optimal hyperparameter combination is obtained; the optimal hyperparameter combination is embedded into the initial hybrid fuel cell voltage prediction model to construct a hybrid fuel cell voltage prediction model.
[0078] In this embodiment, if Figure 7 As shown in Figure 1, Bayesian optimization is a global optimization method based on a probabilistic model. It is suitable for optimizing black-box functions (such as hyperparameter optimization of machine learning models) and can find the optimal solution within a small number of iterations. Its core idea is to construct a surrogate model of the objective function and combine it with the acquisition function to select the next evaluation point. The main steps of Bayesian optimization are as follows:
[0079] Initialization: Randomly select a set of initial points (hyperparameter combinations) and evaluate the objective function (such as the R of the model on the test set). 2 score) to obtain the initial observation data.
[0080] Surrogate model: Gaussian Process Regression (GPR) is used to build a surrogate model of the target function to predict the function value and its uncertainty at unevaluated points.
[0081] Acquisition function: The next evaluation point is selected through the acquisition function (such as Expected Improvement, EI), which balances exploration (high uncertainty area) and exploitation (high prediction value area).
[0082] Iterative update: Add the results of the new evaluation point to the observation data, update the proxy model, and repeat the above steps until the termination condition is met (such as reaching the maximum number of iterations).
[0083] In this paper, Bayesian optimization is used to automatically search for the hyperparameters of the hybrid MLP-GRU model, including learning rate, hidden layer dimension, and dropout rate. The optimization goal is to maximize the R 2 Scores, constructing hyperparameters via Gaussian process regression with R 2 A surrogate model between the scores is combined with the expected improvement acquisition function to select the optimal hyperparameter combination. Bayesian optimization significantly improves the efficiency of hyperparameter optimization and avoids the inefficiency of manual parameter adjustment. This embodiment of the present invention proposes a hybrid MLP-GRU model, combined with a Bayesian optimization strategy, to accurately capture short-term fluctuations and long-term trends in fuel cell voltage, addressing the inability of traditional models to model multi-timescale variations. Through orderly inter-module collaboration and hyperparameter optimization, the model achieves high-precision prediction of voltage decay.
[0084] The Bayesian optimization strategy is used to automatically search for the hyperparameters of the hybrid MLP-GRU model, including the learning rate, hidden layer dimension, and dropout rate. Bayesian optimization constructs the hyperparameters and the objective function (test set R) through Gaussian process regression (GPR). 2 The optimization process includes initial random exploration and subsequent iterative optimization. Each iteration calculates R by model training and evaluation. 2 The Bayesian optimization ensures that the model can achieve the best performance under different working conditions and enhances the adaptability of the model to the prediction of fuel cell voltage decay.
[0085] S300 , inputting the multi-dimensional time series characteristics of the fuel cell operation data into the hybrid fuel cell voltage prediction model to perform voltage prediction, obtain a fuel cell voltage prediction value, and realize the fuel cell membrane electrode performance attenuation prediction.
[0086] S310, inputting the multidimensional time series features of the fuel cell operation data into a hybrid fuel cell voltage prediction model, wherein the hybrid fuel cell voltage prediction model includes a feature extraction module, a time series modeling module, an attention mechanism, a splicing module, and a fully connected layer;
[0087] S320, extracting features from the multidimensional time series features of the fuel cell operation data using a feature extraction module based on the hybrid fuel cell voltage prediction model to obtain high-dimensional features of the fuel cell operation data;
[0088] Specifically, the multidimensional time series features of the fuel cell operation data are input into the feature extraction module of the hybrid fuel cell voltage prediction model; the multidimensional time series features of the fuel cell operation data are linearly transformed to obtain the multidimensional time series features of the transformed fuel cell operation data; a bias vector is added to the multidimensional time series features of the transformed fuel cell operation data to obtain preliminary high-dimensional features of the fuel cell operation data; and the high-dimensional features of the preliminary fuel cell operation data are captured by performing nonlinear mapping relationship processing through a nonlinear activation function to obtain the high-dimensional features of the fuel cell operation data.
[0089] In this embodiment, if Figure 5 As shown in Figure 1, a multilayer perceptron (MLP) is a feedforward neural network widely used for feature extraction and nonlinear modeling. An MLP consists of an input layer, multiple hidden layers, and an output layer, all of which are fully connected. Each neuron receives input from the previous layer, processes it through a linear transformation and a nonlinear activation function, and then outputs it to the next layer. Its core calculation formula is:
[0090] h=f(Wx+b)
[0091] Where x is the input vector, W is the weight matrix, b is the bias vector, f is the activation function (such as SiLU or GELU), and h is the output.
[0092] In this paper, the MLP is used as a feature extraction module to extract deep representations from input features. The MLP captures the complex nonlinear relationships between features through multiple layers of linear transformations and nonlinear activations (such as SiLU and GELU). Layer normalization and dropout mechanisms are introduced to improve the stability and generalization ability of the model. The output of the MLP is a high-dimensional feature representation, which is then input into the GRU module and attention mechanism for further processing.
[0093] In some specific embodiments, a multi-layer perceptron (MLP) is used to extract a deep representation of input features, where the input is the multi-dimensional time series features of fuel cell operation data. The MLP includes multiple layers of linear transformation, layer normalization, SiLU activation function, Dropout and GELU activation function. Through multiple layers of nonlinear transformation, the complex relationship between features is mined to generate a high-dimensional feature representation. MLP MLP introduces nonlinearity through SiLU and GELU activation functions to ensure the richness and robustness of feature representation and provide high-quality feature input for subsequent time series modeling.
[0094] S330, based on the time series modeling module of the hybrid fuel cell voltage prediction model, performing time series capture processing on the high-dimensional features of the fuel cell operation data to obtain the time series features of the fuel cell operation data;
[0095] Specifically, the high-dimensional features of the fuel cell operation data are input into the time series modeling module of the hybrid fuel cell voltage prediction model; the initial hidden state of the time series modeling module is obtained; based on the high-dimensional features of the fuel cell operation data and the initial hidden state, the value of the update gate and the value of the reset gate of the time series modeling module are calculated; the initial hidden state is adjusted by the value of the reset gate, and the candidate hidden state is obtained by calculation based on the adjusted hidden state combined with the high-dimensional features of the fuel cell operation data; according to the value of the update gate, the candidate hidden state is fused with the initial hidden state to obtain the time series features of the fuel cell operation data.
[0096] In this embodiment, if Figure 6 As shown in Figure 2, the Gated Recurrent Unit (GRU) is an improved recurrent neural network (RNN) specifically designed for processing time series data. It effectively captures long-term dependencies while alleviating the vanishing gradient problem of traditional RNNs. The GRU controls the flow of information through update gates and reset gates, reducing the number of parameters and improving computational efficiency. Its core formula is shown below:
[0097] Update gate: determines how much historical information is retained in the current time step. Its calculation formula is:
[0098] z t =σ(W z x t +U z h t-1 +b z )
[0099] Among them, W z and U z are the weight matrices from input and hidden state to update gate, b z is the bias term.
[0100] Reset gate: determines how much historical information is ignored in the current time step. Its calculation formula is:
[0101] r t =σ(W r x t +U r h t-1 +b r )
[0102] Among them, σ is the sigmoid activation function, W r and U r are the weight matrices from input and hidden state to reset gate, b r is the bias term, x t is the input at the current moment, h t-1 is the hidden state at the previous moment.
[0103] Candidate hidden state: Calculate the candidate state of the current time step, the expression is:
[0104]
[0105] Among them, tanh is the hyperbolic tangent activation function, W h and U h are the weight matrices from the hidden state adjusted by the input and reset gates to the candidate hidden state, b h is the bias term, and ⊙ represents element-by-element multiplication.
[0106] Final hidden state: Fusion of historical information and current candidate state, its expression is:
[0107]
[0108] In this paper, the GRU module is used to capture the temporal dependence of fuel cell voltage. Taking the high-dimensional feature representation extracted by the MLP as input, the GRU dynamically adjusts the flow of information through update and reset gates, capturing both short-term voltage fluctuations and long-term trends. The GRU output is fused with the output of the attention mechanism to further enhance the model's predictive capabilities.
[0109] In some embodiments, a gated recurrent unit (GRU) is used to capture long-term dependencies in time series. GRU generates a hidden state sequence gru out ,The key information in the MLP features is dynamically selected through the gating mechanism, and the modeling capability of the ,long-term voltage trend is enhanced.
[0110] S340, based on the attention mechanism of the hybrid fuel cell voltage prediction model, calculating the correlation between each time step of the time series characteristics of the fuel cell operation data to obtain the weight characteristics of the fuel cell operation data;
[0111] Specifically, the time series features of the fuel cell operation data are input into the attention mechanism of the hybrid fuel cell voltage prediction model; the time series features of the fuel cell operation data are transformed through three different linear transformation layers to obtain the corresponding query matrix, key matrix and value matrix; the query matrix, key matrix and value matrix are divided into multiple subspaces, and scaled dot product attention calculations are performed to obtain several weighted value matrices; and several weighted value matrices are spliced and fused to obtain the weight features of the fuel cell operation data.
[0112] In this embodiment, the attention mechanism is a method that calculates the importance weight of each element in the input sequence, which can enhance the model's ability to focus on key information. The multi-head attention mechanism is an extension of the attention mechanism. It captures the relationship between different aspects of the input sequence by computing multiple attention heads in parallel. Its core calculation process is as follows:
[0113] Input Transformation: The input sequence first passes through three different linear transformation layers to obtain query, key, and value matrices. These transformations are usually implemented through fully connected layers.
[0114] Head splitting: The query, key, and value matrices are divided into multiple heads (i.e., multiple subspaces), each with different linear transformation parameters.
[0115] Attention calculation: For each head, a scaled dot-product attention operation is performed. Specifically, the dot product of the query and key is calculated, scaled, biased, and then softmaxed to obtain attention weights. These weights are used to add a weighted value matrix to generate a weighted sum as the output of each head:
[0116]
[0117] Splicing and fusion: The outputs of all heads are spliced together to form a long vector. Then, a final linear transformation is performed on the spliced vector to integrate the information from different heads to obtain the final multi-head attention output:
[0118] MultiHead(Q,K,V)=Concat(head1,…,head h )W O
[0119] In this paper, a multi-head attention mechanism is introduced to enhance the model's ability to focus on critical time steps. The input is the output sequence of the GRU module. The attention mechanism calculates the correlation between each time step and dynamically assigns weights to highlight the time steps that are most important for voltage decay prediction. The output of the attention mechanism is fused with the outputs of the GRU and MLP through residual connections, further improving the model's expressiveness.
[0120] In some embodiments, the attention mechanism generates query (Q), key (K) and value (V) matrices, calculates attention weights and outputs weighted features attn out The attention mechanism uses multi-head computation to highlight key time steps, such as voltage dips, enhancing the model's ability to capture short-term fluctuations. The synergy between the attention mechanism and the GRU lies in the fact that the long-term dependency information captured by the GRU is further weighted by the attention mechanism, highlighting the most important time steps for voltage decay prediction and improving the model's expressiveness.
[0121] S350, a splicing module based on the hybrid fuel cell voltage prediction model, performing residual connection fusion on the high-dimensional features of the fuel cell operation data, the time series features of the fuel cell operation data, and the weight features of the fuel cell operation data to obtain comprehensive features of the fuel cell operation data;
[0122] In this embodiment, the outputs of MLP, GRU, and attention mechanism are fused through residual connections to generate comprehensive features, which are expressed as:
[0123] combined out =feat MLP +gru out +attn out
[0124] Among them, MLP 、gru out and attn out They are the outputs of MLP, GRU, and attention mechanism, with the same dimensions. The residual connection retains the feature information of each module through direct addition, avoiding information loss and improving the expressiveness of the model. The fused features are flattened and input to the output module. The output module contains multiple layers of fully connected layers, batch normalization, ReLU activation function, and Dropout, and is finally mapped to the predicted voltage value U tot (V) The output module enhances generalization capability through batch normalization and Dropout to ensure the stability of prediction results.
[0125] S360, based on the fully connected layer of the hybrid fuel cell voltage prediction model, performs feature mapping on the comprehensive features of the fuel cell operation data to obtain the fuel cell voltage prediction value, thereby realizing the prediction of the fuel cell membrane electrode performance attenuation.
[0126] In this embodiment, features are mapped to predicted voltage values through a fully connected layer, including a linear layer, batch normalization, ReLU activation function, and Dropout.
[0127] In summary, if Figure 8 As shown in the figure, the model input is a multidimensional time series of fuel cell operating data, and the output is the predicted voltage value. The MLP is responsible for extracting deep representations of features, the GRU captures long-term dependencies in the time series, the attention mechanism highlights key time steps, residual connections fuse the outputs of each module, and Bayesian optimization ensures the optimality of hyperparameters. The synergy between modules is reflected in the following aspects: the high-dimensional features extracted by the MLP provide rich input for the GRU, the long-term dependency modeling of the GRU provides the foundation for the attention mechanism, and the weighted features of the attention mechanism further enhance the model's focus on key time steps. Finally, residual connections fuse all this information, jointly achieving high-precision voltage decay prediction.
[0128] Therefore, if Figure 9 As shown, the embodiment of the present invention first collects the operating data of the fuel cell under different operating conditions, focusing on characteristic data such as time, total voltage, current density, air outlet pressure, air flow, hydrogen flow, and air humidity. The data is then standardized to ensure that data of different dimensions are comparable during the analysis process. The original data is then smoothed using wavelet denoising technology. First, a suitable symlet wavelet and decomposition level are selected, and high-frequency noise components are removed using the soft threshold method. The signal is then reconstructed using an inverse wavelet transform to ensure that the main trend is retained while reducing noise interference. Interactive features and differential features are further constructed through feature engineering. The interactive feature is the product of current density and air flow, and the differential feature is the rate of change of voltage over time. Combined with the original features, a feature data set containing multiple physical quantities is generated. The correlation between the feature quantities (including original features, construction features, and other operating parameters such as temperature, pressure, flow, etc.) and the target variable (total voltage) is then analyzed using the Pearson correlation coefficient. The Pearson correlation coefficient is calculated by the formula, and the features with the highest correlation with the total voltage, such as time, current density, air outlet pressure, air flow, hydrogen flow, air humidity, interaction features, and differential features, are selected as the main input features of the model. The data is constructed into a time series format, and the appropriate time step and stride are set to generate sequence data containing multiple time steps. The data set is divided into a training set and a test set in chronological order. The training set is used for model training, and the test set is used to evaluate model performance. The parameters of Bayesian optimization are defined, including the search range and the number of iterations. The R of the test set is used as the training set. 2The score is the fitness function. The optimal hyperparameters of the model, such as learning rate, hidden layer dimension and dropout rate, are searched through Bayesian optimization, and the optimal hyperparameters are applied to the hybrid MLP-GRU model. A hybrid MLP-GRU model is constructed, and the model is trained using the training set. The weighted Huber loss function and learning rate scheduler are used to optimize the training process. An early stopping strategy is set according to the performance of the validation set to ensure that the model is not overfitting. Finally, the trained model is used for voltage decay prediction. The test set data is used as input, the predicted voltage value is output, and the predicted voltage value is evaluated through various evaluation indicators (such as R 2 , MAE, RMSE, etc.) to analyze model performance.
[0129] Therefore, the embodiment of the present invention proposes a fuel cell voltage decay prediction method based on a hybrid MLP-GRU model and Bayesian optimization, aiming to solve the problems of low efficiency of hyperparameter optimization, insufficient ability to capture short-term fluctuations and long-term trends, and unstable training process in the prediction process of existing data-driven methods. This method effectively suppresses high-frequency noise in the data through wavelet denoising technology, and extracts key feature information in combination with feature engineering; constructs a fusion (GRU) hybrid model to simultaneously capture short-term fluctuations and long-term evolution trends of voltage decay; and uses a Bayesian optimization algorithm to automatically search for the optimal hyperparameters of the model, thereby improving the model's prediction accuracy and stability, thereby achieving efficient and accurate prediction of the fuel cell voltage decay process.
[0130] Reference Figure 2 , a fuel cell membrane electrode performance degradation prediction system based on deep learning, including:
[0131] The first module 201 is used to obtain fuel cell operation data and perform data feature preprocessing to obtain multi-dimensional time series features of the fuel cell operation data;
[0132] The second module 202 is used to select the optimal hyperparameter combination through Bayesian optimization, combine the multi-layer perceptron, the gated recurrent unit and the multi-head attention mechanism to build a hybrid fuel cell voltage prediction model;
[0133] The third module 203 is used to input the multi-dimensional time series characteristics of the fuel cell operation data into the hybrid fuel cell voltage prediction model to perform voltage prediction, obtain the fuel cell voltage prediction value, and realize the fuel cell membrane electrode performance attenuation prediction.
[0134] The contents of the above method embodiments are all applicable to the present system embodiments. The functions specifically implemented by the present system embodiments are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.
[0135] The above is a specific description of the preferred implementation of the present invention, but the invention is not limited to the embodiments. Those skilled in the art can make various equivalent modifications or substitutions without violating the spirit of the present invention. These equivalent modifications or substitutions are all included in the scope defined by the claims of this application.
Claims
1. A fuel cell membrane electrode performance degradation prediction method based on deep learning, characterized in that: The following steps are involved: Acquire fuel cell operation data and perform data feature preprocessing to obtain multidimensional time series features of the fuel cell operation data; The optimal hyperparameter combination is selected through Bayesian optimization, and a hybrid fuel cell voltage prediction model is constructed by combining a multilayer perceptron, a gated recurrent unit, and a multi-head attention mechanism. The multidimensional time series characteristics of fuel cell operation data are input into the hybrid fuel cell voltage prediction model for voltage prediction, and the fuel cell voltage prediction value is obtained to realize the fuel cell membrane electrode performance attenuation prediction.
2. The method for predicting fuel cell membrane electrode performance degradation based on deep learning according to claim 1 is characterized in that: The step of acquiring the fuel cell operation data and performing data feature preprocessing to obtain a key feature data set of the fuel cell specifically includes: Acquiring fuel cell operation data, wherein the fuel cell operation data includes time, total voltage, current density, air outlet pressure, air flow, hydrogen flow, and air humidity; The fuel cell operation data is cleaned and spliced in turn to obtain a complete fuel cell operation data set; The complete operating data set of the fuel cell is smoothed by using a wavelet denoising method to obtain a denoised complete operating data set of the fuel cell; Perform feature selection on the denoised fuel cell complete operation data set, and use the Pearson correlation coefficient to filter the eigenvalues to obtain the key feature data set of the fuel cell. The key feature data set of the fuel cell is format converted to obtain the multi-dimensional time series characteristics of the fuel cell operation data.
3. The method for predicting fuel cell membrane electrode performance degradation based on deep learning according to claim 2 is characterized in that: The step of selecting the optimal hyperparameter combination through Bayesian optimization, combining a multilayer perceptron, a gated recurrent unit, and a multi-head attention mechanism to construct a hybrid fuel cell voltage prediction model specifically includes: A multilayer perceptron is used as a feature extraction module and a gated recurrent unit is used as a time series modeling module. A multi-head attention mechanism is introduced to construct an initial hybrid fuel cell voltage prediction model. Based on the Bayesian optimization algorithm, a set of initial hyperparameter combinations are selected and evaluated through the objective function to obtain the initial observation data; Based on the initial observation data, a surrogate model of the objective function is constructed through Gaussian process regression; Based on the proxy model of the objective function, the evaluation point for the next optimization step is selected through the acquisition function; Substitute the evaluation points optimized in the next step into the initial observation data, update the surrogate model of the objective function, and obtain the optimal hyperparameter combination; The optimal hyperparameter combination is embedded into the initial hybrid fuel cell voltage prediction model to construct a hybrid fuel cell voltage prediction model.
4. The method for predicting fuel cell membrane electrode performance degradation based on deep learning according to claim 3 is characterized in that: The step of inputting the multi-dimensional time series characteristics of the fuel cell operation data into the hybrid fuel cell voltage prediction model to perform voltage prediction, obtain the fuel cell voltage prediction value, and realize the fuel cell membrane electrode performance attenuation prediction specifically includes: Inputting the multidimensional time series features of the fuel cell operation data into a hybrid fuel cell voltage prediction model, wherein the hybrid fuel cell voltage prediction model includes a feature extraction module, a time series modeling module, an attention mechanism, a splicing module and a fully connected layer; Based on the feature extraction module of the hybrid fuel cell voltage prediction model, the multi-dimensional time series features of the fuel cell operation data are extracted to obtain the high-dimensional features of the fuel cell operation data; Based on the time series modeling module of the hybrid fuel cell voltage prediction model, the high-dimensional features of the fuel cell operation data are captured and processed in time series to obtain the time series features of the fuel cell operation data; Based on the attention mechanism of the hybrid fuel cell voltage prediction model, the correlation between each time step of the time series characteristics of the fuel cell operation data is calculated to obtain the weighted characteristics of the fuel cell operation data; Based on the splicing module of the hybrid fuel cell voltage prediction model, the high-dimensional features of the fuel cell operation data, the time series features of the fuel cell operation data, and the weight features of the fuel cell operation data are fused through residual connection to obtain the comprehensive features of the fuel cell operation data; Based on the fully connected layer of the hybrid fuel cell voltage prediction model, feature mapping is performed on the comprehensive characteristics of the fuel cell operation data to obtain the fuel cell voltage prediction value, thereby realizing the prediction of fuel cell membrane electrode performance attenuation.
5. The method for predicting fuel cell membrane electrode performance degradation based on deep learning according to claim 4 is characterized in that: The feature extraction module based on the hybrid fuel cell voltage prediction model extracts the multi-dimensional time series features of the fuel cell operation data to obtain the high-dimensional features of the fuel cell operation data. This step specifically includes: Inputting the multidimensional time series features of the fuel cell operation data into the feature extraction module of the hybrid fuel cell voltage prediction model; Performing linear transformation processing on the multidimensional time series characteristics of the fuel cell operation data to obtain the transformed multidimensional time series characteristics of the fuel cell operation data; Adding a bias vector to the transformed multi-dimensional time series features of the fuel cell operation data to obtain preliminary high-dimensional features of the fuel cell operation data; The high-dimensional features of the preliminary fuel cell operation data are captured by performing nonlinear mapping relationship processing through a nonlinear activation function to obtain the high-dimensional features of the fuel cell operation data.
6. The method for predicting fuel cell membrane electrode performance degradation based on deep learning according to claim 5, characterized in that: The time series modeling module based on the hybrid fuel cell voltage prediction model performs time series capture processing on the high-dimensional features of the fuel cell operation data to obtain the time series features of the fuel cell operation data. This step specifically includes: Inputting high-dimensional features of fuel cell operation data into a time series modeling module of a hybrid fuel cell voltage prediction model; Get the initial hidden state of the time series modeling module; Calculate the update gate value and reset gate value of the time series modeling module based on the high-dimensional features and initial hidden state of the fuel cell operation data; The initial hidden state is adjusted by resetting the gate value, and the candidate hidden state is obtained by calculation based on the adjusted hidden state combined with the high-dimensional features of the fuel cell operation data; According to the value of the update gate, the candidate hidden state is fused with the initial hidden state to obtain the time series characteristics of the fuel cell operation data.
7. The method for predicting fuel cell membrane electrode performance degradation based on deep learning according to claim 6, characterized in that: The attention mechanism based on the hybrid fuel cell voltage prediction model calculates the correlation between each time step of the time series characteristics of the fuel cell operation data to obtain the weight characteristics of the fuel cell operation data. This step specifically includes: An attention mechanism that inputs the time series features of fuel cell operation data into the hybrid fuel cell voltage prediction model; The time series features of the fuel cell operation data are transformed through three different linear transformation layers to obtain the corresponding query matrix, key matrix and value matrix; Divide the query matrix, key matrix, and value matrix into multiple subspaces and perform scaled dot product attention calculations to obtain several weighted value matrices; Several weighted value matrices are spliced and fused to obtain the weight characteristics of fuel cell operation data.
8. A fuel cell membrane electrode performance degradation prediction system based on deep learning, characterized by: Includes the following modules: The first module is used to obtain the fuel cell operation data and perform data feature preprocessing to obtain the multi-dimensional time series features of the fuel cell operation data; The second module is used to select the optimal hyperparameter combination through Bayesian optimization, combining multi-layer perceptron, gated recurrent unit and multi-head attention mechanism to build a hybrid fuel cell voltage prediction model; The third module is used to input the multi-dimensional time series characteristics of the fuel cell operation data into the hybrid fuel cell voltage prediction model to perform voltage prediction, obtain the fuel cell voltage prediction value, and realize the fuel cell membrane electrode performance attenuation prediction.
Citation Information
Cited By
Hydrogen fuel cell performance prediction method based on deep learning
CN122065085A
