Fuel cell system hydrogen leakage diagnosis method and system based on hydrogen concentration and pressure

The hydrogen pressure and concentration data of the hydrogen fuel cell system are processed through discrete wavelet transformation and the LSTM-AE neural network model. Combined with the hydrogen leakage detection neural network, the problem of insufficient hydrogen leakage detection accuracy in the hydrogen fuel cell system is solved, and high-precision and efficient hydrogen leakage detection are achieved.

CN120261637APending Publication Date: 2025-07-04GUANGZHOU POWER SUPPLY BUREAU GUANGDONG POWER GRID CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202510438252.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-09
Publication Date
2025-07-04

AI Technical Summary

Technical Problem

The detection accuracy of hydrogen leakage detection in hydrogen fuel cell systems is insufficient, especially in the case of dynamic environmental changes and data fluctuations.

Method used

Discrete wavelet transformation is used to decompose the hydrogen pressure and concentration data on multiple scales, combine the LSTM-AE neural network model and the hydrogen leakage detection neural network, and extract and analyze data through timing feature vectors and sensor network graph data to capture weak abnormal signals before hydrogen leakage.

Benefits of technology

It improves the detection accuracy and inspection efficiency of hydrogen leakage detection, ensures the safety monitoring and risk warning capabilities of fuel cell systems, and adapts to data uncertainty in complex operating environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120261637A_ABST
    Figure CN120261637A_ABST
Patent Text Reader

Abstract

The invention provides a fuel cell system hydrogen leakage diagnosis method and system based on hydrogen concentration and pressure, and relates to the technical field of hydrogen fuel cells, and the method comprises the steps: obtaining hydrogen pressure data and hydrogen concentration data of a fuel cell system; performing data smoothing processing on the hydrogen pressure data and the hydrogen concentration data based on discrete wavelet transform to obtain time sequence data; inputting the time sequence data into a preset LSTM-AE neural network model, and obtaining a time sequence feature vector and sensor network diagram data corresponding to the time sequence data; and performing data extraction and analysis operation on the time sequence feature vector and the sensor network diagram data based on a hydrogen leakage detection neural network model to obtain a hydrogen leakage detection result. According to the invention, the detection precision of hydrogen leakage detection can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of hydrogen fuel cells, and particularly to a method and system for diagnosing hydrogen leakage in a fuel cell system based on hydrogen concentration and pressure. Background Art

[0002] A hydrogen fuel cell is a power generation device that directly converts the chemical energy of hydrogen and oxygen into electrical energy, and its basic principle is the reverse reaction of electrolyzing water. Specifically, after hydrogen diffuses outward through the anode and reacts with the electrolyte, electrons are released and reach the cathode through an external load. One electron in the hydrogen atom is separated, and the hydrogen ion (proton) that loses the electron passes through the proton exchange membrane and reaches the cathode plate of the fuel cell, while the electrons can only reach the cathode plate through the external circuit, thereby generating an electric current in the external circuit. After the electrons reach the cathode plate, they recombine with oxygen atoms and hydrogen ions to form water.

[0003] Chinese Patent with publication number CN118107392A discloses a method and device for detecting hydrogen leakage in a fuel cell, and a computer-readable storage medium. The method includes: obtaining the hydrogen concentration and auxiliary parameters of the fuel cell, where the auxiliary parameters include at least one of the following: gas pressure, temperature parameter; determining the hydrogen leakage risk level of the fuel cell based on the hydrogen concentration and auxiliary parameters; controlling the vehicle according to a preset treatment measure based on the hydrogen leakage risk level, and outputting an alarm message or a prompt message to the client. However, the detection algorithm provided in the above solution directly determines the risk level based on the hydrogen concentration and limited auxiliary parameters, lacking adaptive optimization for dynamic environmental changes and data fluctuations, which easily leads to a reduction in the detection accuracy of hydrogen leakage detection. Therefore, it is very necessary to provide a method and system for diagnosing hydrogen leakage in a fuel cell system based on hydrogen concentration and pressure to improve the detection accuracy of hydrogen leakage detection. Summary of the Invention

[0004] In view of this, the present invention proposes a method and system for diagnosing hydrogen leakage in a fuel cell system based on hydrogen concentration and pressure. By applying discrete wavelet transform to perform multi-scale decomposition on the original hydrogen pressure and concentration data, and at the same time fusing the time series feature vector and the sensor network graph data, weak abnormal signals before the occurrence of hydrogen leakage are captured, improving the detection accuracy and inspection efficiency of hydrogen leakage detection.

[0005] The present invention provides a method for diagnosing hydrogen leakage in a fuel cell system based on hydrogen concentration and pressure, and the method includes:

[0006] Obtaining the hydrogen pressure data and hydrogen concentration data of the fuel cell system;

[0007] Performing data smoothing processing on the hydrogen pressure data and the hydrogen concentration data based on discrete wavelet transform to obtain time series data;

[0008] Input the time series data into a preset LSTM-AE neural network model to obtain a time series feature vector and sensor network graph data corresponding to the time series data;

[0009] Based on the hydrogen leakage detection neural network model, perform data extraction and analysis operations on the time series feature vector and the sensor network graph data to obtain a hydrogen leakage detection result.

[0010] On the basis of the above technical solutions, preferably, the obtaining of the hydrogen pressure data and hydrogen concentration data of the fuel cell system specifically includes:

[0011] Construct a three-dimensional model corresponding to the fuel cell system, simulate the flow of hydrogen inside and outside the three-dimensional model based on COMSOL simulation software, set multiple probes in a preset area of the three-dimensional model, and use the probe position with the largest pressure change rate in the three-dimensional model as the installation position of the pressure sensor in the fuel cell system, and use the probe position with the largest hydrogen concentration change rate as the installation position of the hydrogen concentration sensor in the fuel cell system to respectively obtain the hydrogen pressure data and the hydrogen concentration data.

[0012] On the basis of the above technical solutions, preferably, the LSTM-AE neural network model includes an encoder and a decoder connected in sequence, where,

[0013] The encoder includes a first input layer and a first LSTM network layer connected in sequence. The first input layer is used to receive the time series data, and the first LSTM network layer is used to gradually receive the time series data input at each time step, screen the time series data through a gating mechanism, generate one or a group of hidden states, and transmit the hidden states to the decoder;

[0014] The decoder includes a second input layer, a second LSTM network layer, a fully connected layer, and a second output layer connected in sequence. The second input layer is used to receive the hidden state sent by the encoder. The second LSTM network layer is used to receive the current input hidden state and the hidden state of the previous moment at each moment, integrate and output a high-dimensional hidden state. The fully connected layer is used to map the high-dimensional hidden state input by the second LSTM network layer to the final output space to obtain a time series feature vector, and the second output layer is used to output the time series feature vector.

[0015] Even more preferably, the hydrogen leakage detection neural network model includes a one-dimensional convolution module, a first attention mechanism module, a second attention mechanism module, a first fully connected module, a second fully connected module, and a third fully connected module connected in sequence, where,

[0016] The one-dimensional convolutional layer includes a first one-dimensional convolutional neural network layer, a first batch normalization layer, a first activation function layer, and a first max pooling layer connected in sequence. The first one-dimensional convolutional neural network layer is used to extract local features from the time series feature vector. The first batch normalization layer is used to normalize all the local feature outputs of the one-dimensional convolutional neural network layer. The first activation function layer is used to enhance the non-linearity of the feature output by the one-dimensional convolutional neural network layer. The first max pooling layer is used to downsample the normalized local features to obtain the first-dimensional features;

[0017] The first attention mechanism module includes an efficient attention mechanism layer, a second one-dimensional convolutional neural network layer, a second batch normalization layer, a second activation function layer, and a second max pooling layer connected in sequence. The efficient attention mechanism layer is used to weight the input first-dimensional features with attention weights. The second one-dimensional convolutional neural network layer is used to extract local features from the first-dimensional features enhanced by the efficient attention mechanism layer. The second batch normalization layer is used to normalize the local features output by the second one-dimensional convolutional layer. The second max pooling layer is used to downsample the local features in the first-dimensional features after normalization to obtain the second-dimensional features;

[0018] The first attention mechanism module has the same structure as the second attention mechanism module. The second attention mechanism module is used to receive the second-dimensional features and output the third-dimensional features;

[0019] The first fully connected module includes a first fully connected layer and a third activation function layer. The first fully connected layer is used to map the third-dimensional features to the first output space to obtain the first leakage intensity feature vector. The first fully connected module, the second fully connected module, and the third fully connected module have the same structure. The second fully connected module is used to receive the first leakage intensity feature vector and output the second leakage intensity feature vector. The third fully connected module is used to receive the second leakage intensity feature vector and output the third leakage intensity feature vector.

[0020] More preferably, the first activation function layer, the second activation function layer, and the third activation function layer all use the ReLU function.

[0021] More preferably, the method further includes:

[0022] Obtaining the historical monitoring data of the hydrogen concentration sensor and the pressure sensor;

[0023] When a leakage occurs in the fuel cell system, the time series data in the historical monitoring data collected by the hydrogen concentration sensor and the pressure sensor are marked as positive samples. Under normal operating conditions of the fuel cell system, the time series data in the historical monitoring data collected by the hydrogen concentration sensor and the pressure sensor are marked as negative samples;

[0024] The historical detection data is augmented according to the generative model, and the augmented historical detection data is selected as the training set to train the hydrogen leakage detection neural network model.

[0025] More preferably, the concentration time series expression in the time series data is:

[0026]

[0027] where J represents the number of scales of the concentration time series decomposition, k represents the position at a specific j scale, C j,k represents the approximation coefficient of the low-frequency component, D j,k represents the detail coefficient of the high-frequency component, φ j,k (t) represents the scaling function in the low-frequency part of the signal, represents the wavelet function in the high-frequency part of the signal.

[0028] In the second aspect of the present application, a hydrogen leakage diagnosis system for a fuel cell system based on hydrogen concentration and pressure is provided. The hydrogen leakage diagnosis system for the fuel cell system includes a data acquisition module, a data processing module, and a leakage detection module, where

[0029] The data acquisition module is used to obtain the hydrogen pressure data and hydrogen concentration data of the fuel cell system;

[0030] The data processing module is used to perform data smoothing processing on the hydrogen pressure data and the hydrogen concentration data based on discrete wavelet transform to obtain time series data, and input the time series data into a preset LSTM-AE neural network model to obtain a time series feature vector and sensor network diagram data corresponding to the time series data;

[0031] The leakage detection module is used to perform data extraction and analysis operations on the time series feature vector and the sensor network diagram data based on the hydrogen leakage detection neural network model to obtain a hydrogen leakage detection result.

[0032] In the third aspect of the present application, an electronic device is provided, including a processor, a memory, a user interface, and a network interface. The memory is used to store instructions, the user interface and the network interface are used to communicate with other devices, and the processor is used to execute the instructions stored in the memory.

[0033] In a fourth aspect of the present application, a computer-readable storage medium is provided, on which a computer program is stored, and the computer program is executed by a processor to implement the steps of a hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure.

[0034] The hydrogen leakage diagnosis method and system for a fuel cell system based on hydrogen concentration and pressure provided by the present invention have the following beneficial effects compared with the prior art:

[0035] (1) By applying discrete wavelet transform to perform multi-scale decomposition on the original hydrogen pressure and concentration data, useful signals and noises can be effectively distinguished. The long short-term memory network is used to capture the long-term dependencies in the time series, and then combined with the autoencoder model to compress and reconstruct the data, so as to obtain an effective representation of the data in the low-dimensional space. After being processed by the LSTM-AE neural network model, the extracted time series feature vectors can accurately reflect the subtle state changes that occur during the operation of the fuel cell system. At the same time, by fusing the time series feature vectors with the sensor network graph data, the hydrogen leakage detection neural network model can comprehensively utilize multi-dimensional information for in-depth learning, capture the weak abnormal signals before the occurrence of hydrogen leakage, analyze the abnormal data in real time, and quickly identify potential hydrogen leakage risks, greatly improving the detection accuracy and inspection efficiency of hydrogen leakage detection.

[0036] (2) By adopting a first input layer and a first LSTM network layer connected in sequence, the LSTM-AE neural network model uses a gating mechanism to screen the time series data gradually input during the encoding stage, ensuring that noise data is effectively filtered and focusing on the effective signals reflecting the actual operating state of the fuel cell system. Through the second input layer, the second LSTM network layer and the fully connected layer in the decoder, the hidden states passed by the encoder are gradually fused, integrating the current input and the information of the previous moment at each moment to generate a high-dimensional hidden state. Then, the fully connected layer maps this state to the target output space to obtain accurate time series feature vectors, which not only improves the detection accuracy of abnormal states, but also takes into account real-time performance and stability. Through the organic combination of the encoding and decoding parts, the model can better adapt to the uncertainty of data in a complex operating environment, providing a reliable feature basis for subsequent analysis based on the hydrogen leakage detection neural network, thus strengthening the overall safety monitoring and risk warning capabilities of the fuel cell system. Description of the Drawings

[0037] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the following drawings are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.

[0038] Figure 1 Schematic flow diagram of the hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure provided by the present invention;

[0039] Figure 2 Schematic structural diagram of the LSTM-AE neural network model provided by the present invention;

[0040] Figure 3 Schematic structural diagram of the hydrogen leakage detection neural network model provided by the present invention;

[0041] Figure 4 Schematic structural diagram of the hydrogen leakage diagnosis system for a fuel cell system provided by the present invention;

[0042] Figure 5 Schematic structural diagram of the electronic device provided by the present invention.

[0043] Explanation of reference numerals: 1. Hydrogen leakage diagnosis system for fuel cell system; 11. Data acquisition module; 12. Data processing module; 13. Leakage detection module; 2. Electronic device; 21. Processor; 22. Communication bus; 23. User interface; 24. Network interface; 25. Memory. Detailed implementation manners

[0044] Next, in combination with the embodiments of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.

[0045] The present invention discloses a hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure. Refer to Figure 1 , the steps of this method include S1 to S4.

[0046] Step S1, obtain the hydrogen pressure data and hydrogen concentration data of the fuel cell system.

[0047] In this step, a three-dimensional model corresponding to the fuel cell system is constructed, the flow of hydrogen inside and outside the three-dimensional model is simulated based on the COMSOL simulation software, and multiple probes are set at preset regions of the three-dimensional model. The position of the probe with the largest pressure change rate in the three-dimensional model is used as the installation position of the pressure sensor in the fuel cell system, and the position of the probe with the largest hydrogen concentration change rate is used as the installation position of the hydrogen concentration sensor in the fuel cell system, so as to obtain the hydrogen pressure data and hydrogen concentration data respectively.

[0048] In this embodiment, by setting a plurality of probes at different positions in the key areas of the model (such as pipe joints, around hydrogen storage tanks, near fuel cell stacks), the position with the largest pressure change rate is selected as the installation position of the internal sensor of the fuel cell system, and the position with the largest hydrogen concentration change rate is selected as the installation position of the external sensor of the fuel cell system.

[0049] Step S2: Based on discrete wavelet transform, perform data smoothing processing on the hydrogen pressure data and hydrogen concentration data to obtain time series data.

[0050] In this step, the data smoothing processing based on discrete wavelet transform uses the discrete wavelet transform based on the lifting algorithm, which is used to quickly remove the high-order noise generated by the sensor when obtaining time series data. The data smoothing processing uses the discrete wavelet transform (DWT) based on the lifting algorithm to smooth the data. For signal features, the tenth-order Daubechies wavelet is selected to remove high-order noise. For a given concentration time series X(t), first select the mother wavelet to determine the scaling function and the wavelet function, and decompose X(t):

[0051]

[0052] where J represents the number of scales of the concentration time series decomposition, k represents the position at a specific j scale, C j,k represents the approximation coefficient of the low-frequency component, D j,k represents the detail coefficient of the high-frequency component, φ j,k (t) represents the scaling function in the low-frequency part of the signal, represents the wavelet function in the high-frequency part of the signal.

[0053] The discrete wavelet transform (DWT) lifting algorithm decomposes the wavelet transform into prediction and update steps through the lifting scheme, thereby reducing the computational complexity and improving the performance. The lifting algorithm generally includes the following three steps:

[0054] First, divide the signal into even samples and odd samples. The even samples are x even (t) = x(2t); the odd samples are x odd (t) = x(2t + 1). Then use the even samples to predict the odd samples to obtain the detail coefficient (d(t) = x odd (t) - P(x even [t]), where P is the prediction operator), and finally use the detail coefficient to update the even samples to obtain the approximation coefficient (c[t] = x even [t] - U(d[t]), where U is the update operator).

[0055] In one example, time series data is input into a trained neural network model to obtain a gas leakage detection result. The neural network model includes: a feature extraction layer part for extracting deep features of the time series data to obtain deep feature data; a hydrogen leakage estimation part for processing the deep feature data and outputting a hydrogen leakage detection result; and a hydrogen leakage intensity inspection part for processing the deep feature data and outputting a gas leakage intensity estimation result.

[0056] The feature extraction layer part is an unsupervised model that combines an LSTM neural network and an AE for feature extraction, dimensionality reduction, and reconstruction of time series data. The model includes: an encoder part for compressing the input time series data into a low-dimensional latent variable; and a decoder part for reconstructing the original time series data from the low-dimensional latent variable.

[0057] The hydrogen leakage intensity estimation part includes: an attention mechanism that first performs global average pooling on the deep features to obtain statistical information for each channel; then, adaptively determines the kernel size k according to the channel dimension, and captures the dependencies between channels through one-dimensional convolution with k; finally, generates channel weights through a Sigmoid activation function and multiplies them with the original feature map to re-weight the features; a one-dimensional convolutional neural network part for extracting local features of one-dimensional time series data; and a fully connected layer part whose function is to integrate and transform the input features and output the final regression result to estimate the hydrogen leakage intensity.

[0058] Step S3: Input the time series data into a preset LSTM-AE neural network model to obtain a time series feature vector and sensor network graph data corresponding to the time series data.

[0059] As Figure 2 shown, the LSTM-AE neural network model includes an encoder and a decoder connected in sequence. Among them,

[0060] The encoder includes a first input layer and a first LSTM network layer connected in sequence. The first input layer is used to receive the time series data, and the first LSTM network layer is used to gradually receive the time series data input at each time step, screen the time series data through a gating mechanism, generate one or a group of hidden states, and pass the hidden states to the decoder;

[0061] The decoder includes a second input layer, a second LSTM network layer, a fully connected layer, and a second output layer connected in sequence. The second input layer is used to receive the hidden state sent by the encoder. The second LSTM network layer is used to receive the sum of the current input hidden state and the previous hidden state at each moment, and integrate and output a high-dimensional hidden state. The fully connected layer is used to map the high-dimensional hidden state input by the second LSTM network layer to the final output space to obtain a time series feature vector. The second output layer is used to output the time series feature vector.

[0062] In this embodiment, a first input layer and a first LSTM network layer are connected in sequence. The LSTM-AE neural network model uses a gating mechanism to screen the gradually input time series data during the encoding stage, ensuring that noise data is effectively filtered and focusing on the effective signals reflecting the actual operating state of the fuel cell system. Through the second input layer, the second LSTM network layer, and the fully connected layer in the decoder, the hidden state transmitted by the encoder is gradually fused, integrating the current input and the information of the previous moment at each moment to generate a high-dimensional hidden state. Then, the fully connected layer maps this state to the target output space to obtain an accurate time series feature vector, which not only improves the detection accuracy of abnormal states but also takes into account real-time performance and stability. Through the organic combination of the encoding and decoding parts, the model can better adapt to the uncertainty of data in a complex operating environment, providing a reliable feature basis for subsequent analysis based on the hydrogen leakage detection neural network, thereby enhancing the overall safety monitoring and risk warning capabilities of the fuel cell system.

[0063] Furthermore, the LSTM-AE neural network model is suitable for feature extraction, dimensionality reduction, and reconstruction of time series data. It uses the structure of AE to extract high-order features of the data, thereby reducing the data dimension. LSTM is a neural network that can process time series data. LSTM includes a forget gate, an input gate, and an output gate.

[0064] The formula for the forget gate is:

[0065] f l =σ(W f ·[h l-1 ,x l +b f );

[0066] Where x l represents the input vector with index l, σ represents the Sigmoid function, W f represents the weight matrix of the forget gate, b f represents the bias vector, and h represents the hidden state.

[0067] The formula for the input gate is:

[0068] i l= σ(W i · [h l-1 , x l + b i );

[0069] g l = tanh(W g · [h l-1 , x l + b g );

[0070] Among them, W i and W g represent the weight matrix of the input gate b, and b i and b g both represent the bias vector.

[0071] The output gate formula is:

[0072] o l = σ(W o · [h l-1 , x l + b o );

[0073] C l = f l · C l-1 + i l · g l ;

[0074] h l = o l · tanh(C l );

[0075] Among them, W o represents the weight matrix of the output gate, b o represents the bias vector, and C l represents the cell state.

[0076] The structure diagram of the LSTM-AE neural network is as shown in Figure 2 . The structure of the encoder is a 1-layer LSTM network, and the structure of the decoder is a 1-layer LSTM network and a fully connected layer. The input of the encoder is X with n-dimensional features and sequence length L, and the output is an m-dimensional high-level feature vector H, where m is the size of the hidden state dimension of the LSTM. The H' matrix is formed by repeating HL times. The input of the decoder is H', and the output is X'. This network is trained with the mean square error between X and X' as the loss function. When the time series data X is input into the LSTM-AE pre-training model, the output H of the encoder is extracted as the encoded feature vector of the input data, thus completing feature extraction.

[0077] Step S4: Based on the hydrogen leakage detection neural network model, perform data extraction and analysis operations on the time series feature vector and the sensor network diagram data to obtain the hydrogen leakage detection result.

[0078] As Figure 3 shown, the hydrogen leakage detection neural network model includes a one-dimensional convolutional module, a first attention mechanism module, a second attention mechanism module, a first fully connected module, a second fully connected module, and a third fully connected module connected in sequence. Among them,

[0079] The one-dimensional convolutional layer includes a first one-dimensional convolutional neural network layer, a first batch normalization layer, a first activation function layer, and a first max pooling layer connected in sequence. The first one-dimensional convolutional neural network layer is used to extract local features from the time series feature vector. The first batch normalization layer is used to normalize all the local feature outputs of the one-dimensional convolutional neural network layer. The first activation function layer is used to enhance the non-linear ability of the output features of the one-dimensional convolutional neural network layer. The first max pooling layer is used to downsample the normalized local features to obtain the first-dimensional features;

[0080] The first attention mechanism module includes an efficient attention mechanism layer, a second one-dimensional convolutional neural network layer, a second batch normalization layer, a second activation function layer, and a second max pooling layer connected in sequence. The efficient attention mechanism layer is used to weight the input first-dimensional features with attention weights. The second one-dimensional convolutional neural network layer is used to extract local features in the first-dimensional features strengthened by the efficient attention mechanism layer. The second batch normalization layer is used to normalize the local features output by the second one-dimensional convolutional layer. The second max pooling layer is used to downsample the local features in the first-dimensional features after normalization to obtain the second-dimensional features;

[0081] The first attention mechanism module has the same structure as the second attention mechanism module. The second attention mechanism module is used to receive the second-dimensional features and output the third-dimensional features;

[0082] The first fully connected module includes a first fully connected layer and a third activation function layer. The first fully connected layer is used to map the third-dimensional features to the first output space to obtain the first leakage intensity feature vector. The first fully connected module, the second fully connected module, and the third fully connected module have the same structure. The second fully connected module is used to receive the first leakage intensity feature vector and output the second leakage intensity feature vector. The third fully connected module is used to receive the second leakage intensity feature vector and output the third leakage intensity feature vector. The first activation function layer, the second activation function layer, and the third activation function layer all use the ReLU function.

[0083] In this embodiment, the hydrogen leakage detection part combines an image neural network on the basis of a convolutional neural network, inputs the extracted temporal features into the sensor network model of the fuel cell system, constructs graph-structured data for the GNN neural network to extract features from the sensor network graph data; captures the relationships between sensors; converts the graph features extracted by the GNN into an image format; uses the CNN to further analyze the converted image; uses the cross-entropy loss function to classify and evaluate the detection results, optimizes the algorithm with the adam optimizer, and jointly trains the LSTM-AE, GNN, and CNN neural network models, so as to realize hydrogen leakage detection in a spatial range.

[0084] The hydrogen leakage intensity estimation part adopts a neural network structure combining a one-dimensional convolutional neural network 1D-CNN and an efficient attention mechanism ECA module. The time series matrix X ∈ R T×D , where T is the time step and D is the feature dimension (hydrogen concentration, pressure, etc. at different positions). The high-dimensional time series matrix X is input into the encoder of the LSTM-AE, and the output is the low-dimensional encoded feature H. The encoded feature H is used as the input to construct the LSTM-AE-ECA-CNN model to judge the hydrogen leakage level. The structure diagram of the LSTM-AE-ECA-CNN neural network is as shown in Figure 3 Figure.

[0085] 1D-CNN (one-dimensional convolutional neural network) is a variant of the convolutional neural network, specifically designed to process sequence data. In this implementation, the ReLU function is selected as the activation function of the neural network. The deep feature sequence output by the feature extraction part forms a new feature sequence through 1D-CNN, and then batch normalization is used to normalize the input of each layer to reduce the internal covariate shift. The steps of the batch normalization operation are as follows:

[0086] First, calculate the mean of the sequence, then calculate the variance of the sequence, and then perform normalization. The normalization formula is:

[0087] where, μ B is the sequence mean, σ B is the sequence variance, and ε is a very small constant used to prevent the denominator from being zero, taking 10 -8 . Finally, scaling and offset are performed to reduce the internal covariate shift of the neural network. The data after batch normalization passes through the ReLU activation function and then through max pooling to reduce the computational amount and the number of parameters while retaining important features.

[0088] The Efficient Channel Attention (ECA) mechanism is inserted to model the channel attention of features. During the training process, the ECA module can be optimized together with other layers to improve the performance of the model. At the same time, one-dimensional convolution is repeated to highlight the sequence features. Then, through multiple fully connected layers and ReLU activation functions, the input features are integrated and transformed to output the final estimated result of hydrogen leakage intensity.

[0089] In this step, steps S41 to S43 are also included.

[0090] Step S41: Obtain the historical monitoring data of the hydrogen concentration sensor and the pressure sensor.

[0091] Step S42: When the fuel cell system has leaked, mark the time series data in the historical monitoring data collected by the hydrogen concentration sensor and the pressure sensor as positive samples. When the fuel cell system is in normal operation, mark the time series data in the historical monitoring data collected by the hydrogen concentration sensor and the pressure sensor as negative samples.

[0092] Step S43: Expand the historical detection data according to the generative model, and select the expanded historical detection data as the training set to train the hydrogen leakage detection neural network model.

[0093] It can be understood that the historical monitoring data of the hydrogen concentration sensor set in the external environment and the pressure sensor inside the fuel cell system is obtained. Based on the hydrogen concentration sensor and the pressure sensor, the time series data collected by the sensors for a period of time when leakage occurs is marked as positive samples, and the time series data collected by the sensors for a period of time under normal operating conditions of the fuel cell system is marked as negative samples; the historical detection data is expanded using the generative model, and the expanded historical detection data is selected as the training set, and the training set is used to train the hydrogen leakage detection neural network model to obtain a trained hydrogen leakage detection neural network model.

[0094] In one example, for the acquisition of sensor historical data, the leakage point was selected at the connection seal of the hydrogen pipeline between the hydrogen injector and the hydrogen fuel cell stack of the fuel cell system. Suppose there are a total of 6 leakage sources. Under environmental conditions (such as wind speed and wind direction), and the leakage rates of the hydrogen leakage sources formed 288 simulation scenarios. Each simulation involved continuous hydrogen leakage for 180 seconds, and the data was recorded every 0.5 seconds. The final obtained dataset had a dimension of X288×20×360, where 288 is the number of scenarios, 20 is the number of sensors, and 360 is the concentration time series data collected by each sensor within 180 seconds. The nature of the collected data is the hydrogen mole fraction monitored by 20 hydrogen concentration sensors. And X288×2×360, where 288 is the number of scenarios, 2 is the number of sensors, and 360 is the concentration time series data collected by each sensor within 180 seconds. The nature of the collected data is the hydrogen pressure monitored by 2 pressure sensors. In this embodiment, the trained and verified LSTM-AE-GNN-CNN and LSTM-AE-ECA-CNN models are used to implement hydrogen leakage detection and hydrogen leakage intensity estimation respectively. In the hydrogen leakage detection results, only 2 out of 60 test cases generated incorrect results, indicating a very high overall accuracy. Regarding the intensity estimation results, except for a few cases, most of the estimated leakage intensities are close to the true values. Even in these few cases, the difference between the estimated results and the true results is not significant. This shows that the proposed method is effective in both hydrogen leakage estimation and hydrogen leakage severity.

[0095] For the hydrogen leakage detection part, based on the temporal convolutional neural network, an image neural network is combined. By using the spatial topology structure information of the fuel cell system, the dependencies in both the time dimension and the spatial dimension are captured simultaneously, improving the modeling ability for complex system states. Through the application of discrete wavelet transform to perform multi-scale decomposition on the original hydrogen pressure and concentration data, useful signals and noises can be effectively distinguished. The long short-term memory network is used to capture the long-term dependencies in the time series, and then combined with the autoencoder model to compress and reconstruct the data, so as to obtain an effective representation of the data in the low-dimensional space. After being processed by the LSTM-AE neural network model, the extracted temporal feature vectors can accurately reflect the subtle state changes that occur during the operation of the fuel cell system. At the same time, by fusing the temporal feature vectors with the sensor network graph data, the hydrogen leakage detection neural network model can comprehensively utilize multi-dimensional information for in-depth learning, capture the weak abnormal signals before the occurrence of hydrogen leakage, analyze the abnormal data in real time, and quickly identify potential hydrogen leakage risks, greatly improving the detection accuracy and inspection efficiency of hydrogen leakage detection.

[0096] Based on the above method, an embodiment of this application discloses a hydrogen leakage diagnosis system for a fuel cell system based on hydrogen concentration and pressure, refer to Figure 5, the hydrogen leakage diagnosis system 1 of the fuel cell system includes a data acquisition module 11, a data processing module 12, and a leakage detection module 13. Among them,

[0097] The data acquisition module 11 is used to obtain the hydrogen pressure data and hydrogen concentration data of the fuel cell system;

[0098] The data processing module 12 is used to perform data smoothing processing on the hydrogen pressure data and hydrogen concentration data based on discrete wavelet transform to obtain time series data, input the time series data into a preset LSTM-AE neural network model, and obtain a time series feature vector and sensor network diagram data corresponding to the time series data;

[0099] The leakage detection module 13 is used to perform data extraction and analysis operations on the time series feature vector and sensor network diagram data based on the hydrogen leakage detection neural network model to obtain the hydrogen leakage detection result.

[0100] In one example, the data acquisition module 11 is used to construct a three-dimensional model corresponding to the fuel cell system, simulate the flow of hydrogen inside and outside the three-dimensional model based on the COMSOL simulation software, set multiple probes in a preset area of the three-dimensional model, and use the probe position with the largest pressure change rate in the three-dimensional model as the installation position of the pressure sensor in the fuel cell system, and use the probe position with the largest hydrogen concentration change rate as the installation position of the hydrogen concentration sensor in the fuel cell system to obtain the hydrogen pressure data and hydrogen concentration data respectively.

[0101] In one example, the LSTM-AE neural network model includes an encoder and a decoder connected in sequence, where

[0102] The encoder includes a first input layer and a first LSTM network layer connected in sequence. The first input layer is used to receive the time series data, and the first LSTM network layer is used to gradually receive the time series data input at each time step, screen the time series data through a gating mechanism, generate one or a group of hidden states, and transmit the hidden states to the decoder;

[0103] The decoder includes a second input layer, a second LSTM network layer, a fully connected layer, and a second output layer connected in sequence. The second input layer is used to receive the hidden states sent by the encoder. The second LSTM network layer is used to receive the sum of the current input hidden state and the previous hidden state at each moment, integrate and output a high-dimensional hidden state. The fully connected layer is used to map the high-dimensional hidden state input by the second LSTM network layer to the final output space to obtain the time series feature vector, and the second output layer is used to output the time series feature vector.

[0104] In one example, the hydrogen leakage detection neural network model includes a one-dimensional convolutional module, a first attention mechanism module, a second attention mechanism module, a first fully connected module, a second fully connected module, and a third fully connected module connected in sequence. Among them,

[0105] The one-dimensional convolutional layer includes a first one-dimensional convolutional neural network layer, a first batch normalization layer, a first activation function layer, and a first max pooling layer connected in sequence. The first one-dimensional convolutional neural network layer is used to extract local features from the time series feature vector. The first batch normalization layer is used to normalize all the local feature outputs of the one-dimensional convolutional neural network layer. The first activation function layer is used to enhance the non-linear ability of the feature output by the one-dimensional convolutional neural network layer. The first max pooling layer is used to downsample the normalized local features to obtain the first-dimensional features;

[0106] The first attention mechanism module includes an efficient attention mechanism layer, a second one-dimensional convolutional neural network layer, a second batch normalization layer, a second activation function layer, and a second max pooling layer connected in sequence. The efficient attention mechanism layer is used to weight the input first-dimensional features with attention weights. The second one-dimensional convolutional neural network layer is used to extract local features from the first-dimensional features strengthened by the efficient attention mechanism layer. The second batch normalization layer is used to normalize the local features output by the second one-dimensional convolutional layer. The second max pooling layer is used to downsample the local features in the first-dimensional features after normalization to obtain the second-dimensional features;

[0107] The first attention mechanism module has the same structure as the second attention mechanism module. The second attention mechanism module is used to receive the second-dimensional features and output the third-dimensional features;

[0108] The first fully connected module includes a first fully connected layer and a third activation function layer. The first fully connected layer is used to map the third-dimensional features to the first output space to obtain the first leakage intensity feature vector. The first fully connected module, the second fully connected module, and the third fully connected module have the same structure. The second fully connected module is used to receive the first leakage intensity feature vector and output the second leakage intensity feature vector. The third fully connected module is used to receive the second leakage intensity feature vector and output the third leakage intensity feature vector.

[0109] In one example, the first activation function layer, the second activation function layer, and the third activation function layer all use the ReLU function.

[0110] In one example, the data processing module 12 is configured to obtain historical monitoring data of a hydrogen concentration sensor and a pressure sensor; when a leakage has occurred in the fuel cell system, time series data in the historical monitoring data collected by the hydrogen concentration sensor and the pressure sensor are marked as positive samples, and when the fuel cell system is in normal operating conditions, time series data in the historical monitoring data collected by the hydrogen concentration sensor and the pressure sensor are marked as negative samples; the historical detection data is augmented according to a generative model, and the augmented historical detection data is selected as a training set to train a hydrogen leakage detection neural network model.

[0111] In one example, the concentration time series expression in the time series data is:

[0112]

[0113] where J represents the number of scales for decomposition of the concentration time series, k represents the position at a specific j scale, C j,k represents the approximation coefficient of the low-frequency component, D j,k represents the detail coefficient of the high-frequency component, φ j,k (t) represents the scaling function in the low-frequency part of the signal, represents the wavelet function in the high-frequency part of the signal.

[0114] Please refer to Figure 5 , which provides a schematic structural diagram of an electronic device for an embodiment of the present application. As Figure 5 shown, the electronic device 2 may include: at least one processor 21, at least one network interface 24, a user interface 23, a memory 25, and at least one communication bus 22.

[0115] Among them, the communication bus 22 is used to realize connection communication between these components.

[0116] Among them, the user interface 23 may include a display screen (Display), a camera (Camera), and optionally the user interface 23 may further include a standard wired interface and a wireless interface.

[0117] Among them, the network interface 24 may optionally include a standard wired interface and a wireless interface (such as a WI-FI interface).

[0118] Among them, the processor 21 may include one or more processing cores. The processor 21 connects various parts within the entire server through various interfaces and circuits, and executes various functions of the server and processes data by running or executing instructions, programs, code sets, or instruction sets stored in the memory 25, and by calling the data stored in the memory 25. Optionally, the processor 21 may be implemented in at least one hardware form of digital signal processing (DSP), field-programmable gate array (FPGA), or programmable logic array (PLA). The processor 21 may integrate a combination of one or several of a central processing unit (CPU), a graphics processing unit (GPU), and a modem, etc. Among them, the CPU mainly processes the operating system, user interface, application programs, etc.; the GPU is responsible for rendering and drawing the content to be displayed on the display screen; the modem is used to process wireless communication. It can be understood that the above-mentioned modem may not be integrated into the processor 21 and may be implemented separately by a single chip.

[0119] Among them, the memory 25 may include random access memory (RAM), and may also include read-only memory. Optionally, the memory 25 includes a non-transitory computer-readable storage medium. The memory 25 can be used to store instructions, programs, code, code sets, or instruction sets. The memory 25 may include a program storage area and a data storage area. Among them, the program storage area may store instructions for implementing the operating system, instructions for at least one function (such as touch function, sound playback function, image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store the data involved in the above-mentioned various method embodiments. Optionally, the memory 25 may also be at least one storage device located far from the aforementioned processor 21. As Figure 5 shown, the memory 25, as a computer storage medium, may include an operating system, a network communication module, a user interface module, and a hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure.

[0120] In Figure 5In the electronic device 2 shown, the user interface 23 is mainly used to provide an interface for the user to input and obtain the data input by the user; and the processor 21 can be used to call a hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure stored in the memory 25. When executed by one or more processors, the electronic device is caused to execute one or more methods as in the above embodiments.

[0121] A computer-readable storage medium stores instructions. When executed by one or more processors, the computer is caused to execute one or more methods as in the above embodiments.

[0122] It should be noted that, for the foregoing method embodiments, for the sake of simple description, they are all expressed as a series of action combinations. However, those skilled in the art should know that this application is not limited by the described action sequence, because according to this application, certain steps can be performed in other sequences or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily essential to this application.

[0123] In the above embodiments, the descriptions of the respective embodiments have their own emphases. For the parts not detailed in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0124] In the several embodiments provided by this application, it should be understood that the disclosed device can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of units is only a logical function division. In actual implementation, there can be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed coupling or direct coupling or communication connection to each other can be through some service interfaces. The indirect coupling or communication connection of the device or unit can be in an electrical or other form.

[0125] The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they can be located in one place, or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0126] In addition, in each embodiment of this application, the functional units can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit. The above integrated units can be implemented in the form of hardware or in the form of software functional units.

[0127] When the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable memory. Based on this understanding, the technical solution of the present application, in essence, or the part that contributes to the prior art, or all or part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a memory and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods in various embodiments of the present application. And the aforementioned memory includes: various media such as USB flash drives, mobile hard disks, magnetic disks, or optical discs that can store program codes.

[0128] The above are only exemplary embodiments of the present disclosure, and the scope of the present disclosure cannot be limited thereby. That is, any equivalent changes and modifications made in accordance with the teachings of the present disclosure still fall within the scope covered by the present disclosure. After considering the specification and the disclosure of the practical truth, those skilled in the art will easily think of other implementation manners of the present disclosure. The present application aims to cover any variations, uses, or adaptive changes of the present disclosure, and these variations, uses, or adaptive changes follow the general principles of the present disclosure and include the common general knowledge or conventional techniques in the technical field not recorded in the present disclosure.

[0129] The above description is only the preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A method for diagnosing hydrogen leakage in a fuel cell system based on hydrogen concentration and pressure, characterized in that, The method includes: Obtaining hydrogen pressure data and hydrogen concentration data of a fuel cell system; Performing data smoothing processing on the hydrogen pressure data and the hydrogen concentration data based on discrete wavelet transform to obtain time series data; Inputting the time series data into a preset LSTM-AE neural network model to obtain a time series feature vector and sensor network graph data corresponding to the time series data; Performing data extraction and analysis operations on the time series feature vector and the sensor network graph data based on a hydrogen leakage detection neural network model to obtain a hydrogen leakage detection result.

2. The hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure according to claim 1, characterized in that, The obtaining of the hydrogen pressure data and the hydrogen concentration data of the fuel cell system specifically includes: Constructing a three-dimensional model corresponding to the fuel cell system, simulating the flow of hydrogen inside and outside the three-dimensional model based on COMSOL simulation software, setting a plurality of probes in a preset area of the three-dimensional model, taking the probe position with the largest pressure change rate in the three-dimensional model as the installation position of the pressure sensor in the fuel cell system, and taking the probe position with the largest hydrogen concentration change rate as the installation position of the hydrogen concentration sensor in the fuel cell system, so as to obtain the hydrogen pressure data and the hydrogen concentration data respectively.

3. The hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure according to claim 1, wherein The LSTM-AE neural network model includes an encoder and a decoder connected in sequence, where The encoder includes a first input layer and a first LSTM network layer connected in sequence. The first input layer is used to receive the time series data, and the first LSTM network layer is used to gradually receive the time series data input at each time step, screen the time series data through a gating mechanism, generate one or a group of hidden states, and transmit the hidden states to the decoder; The decoder includes a second input layer, a second LSTM network layer, a fully connected layer, and a second output layer connected in sequence. The second input layer is used to receive the hidden state sent by the encoder. The second LSTM network layer is used to receive the current input hidden state and the previous hidden state at each moment, integrate and output a high-dimensional hidden state. The fully connected layer is used to map the high-dimensional hidden state input by the second LSTM network layer to the final output space to obtain a time series feature vector, and the second output layer is used to output the time series feature vector.

4. The hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure according to claim 1, wherein The hydrogen leakage detection neural network model includes a one-dimensional convolution module, a first attention mechanism module, a second attention mechanism module, a first fully connected module, a second fully connected module, and a third fully connected module connected in sequence, where The one-dimensional convolutional layer includes a first one-dimensional convolutional neural network layer, a first batch normalization layer, a first activation function layer, and a first max pooling layer connected in sequence. The first one-dimensional convolutional neural network layer is used to extract local features from the time series feature vector. The first batch normalization layer is used to normalize all local feature outputs of the one-dimensional convolutional neural network layer. The first activation function layer is used to enhance the non-linear ability of the features output by the one-dimensional convolutional neural network layer. The first max pooling layer is used to downsample the normalized local features to obtain first-dimensional features; The first attention mechanism module includes an efficient attention mechanism layer, a second one-dimensional convolutional neural network layer, a second batch normalization layer, a second activation function layer, and a second max pooling layer connected in sequence. The efficient attention mechanism layer is used to weight the input first-dimensional features with attention weights. The second one-dimensional convolutional neural network layer is used to extract local features from the first-dimensional features strengthened by the efficient attention mechanism layer. The second batch normalization layer is used to normalize the local features output by the second one-dimensional convolutional layer. The second max pooling layer is used to downsample the local features in the first-dimensional features after normalization to obtain second-dimensional features; The first attention mechanism module has the same structure as the second attention mechanism module. The second attention mechanism module is used to receive the second-dimensional features and output third-dimensional features; The first fully connected module includes a first fully connected layer and a third activation function layer. The first fully connected layer is used to map the third-dimensional features to a first output space to obtain a first leakage intensity feature vector. The first fully connected module, the second fully connected module, and the third fully connected module have the same structure. The second fully connected module is used to receive the first leakage intensity feature vector and output a second leakage intensity feature vector. The third fully connected module is used to receive the second leakage intensity feature vector and output a third leakage intensity feature vector.

5. The hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure according to claim 4, characterized in that, The first activation function layer, the second activation function layer, and the third activation function layer all use the ReLU function.

6. The hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure according to claim 2, characterized in that The method further includes: Obtaining historical monitoring data of the hydrogen concentration sensor and the pressure sensor; When the fuel cell system has a leak, marking the time series data in the historical monitoring data collected by the hydrogen concentration sensor and the pressure sensor as positive samples. Under normal operating conditions of the fuel cell system, marking the time series data in the historical monitoring data collected by the hydrogen concentration sensor and the pressure sensor as negative samples; Expanding the historical detection data according to the generative model, and selecting the expanded historical detection data as the training set to train the hydrogen leakage detection neural network model.

7. The hydrogen leakage diagnosis method for a fuel cell system based on hydrogen concentration and pressure according to claim 1, characterized in that, The concentration time series expression in the time series data is: Among them, J represents the number of scales for the decomposition of the concentration time series, k represents the position at a specific j scale, C j,k represents the approximation coefficient of the low-frequency component, D j,k represents the detail coefficient of the high-frequency component, φ j,k (t) represents the scaling function in the low-frequency part of the signal, represents the wavelet function in the high-frequency part of the signal.

8. A hydrogen leakage diagnosis system for a fuel cell system based on hydrogen concentration and pressure, characterized in that, The hydrogen leakage diagnosis system (1) of the fuel cell system includes a data acquisition module (11), a data processing module (12), and a leakage detection module (13), where The data acquisition module (11) is configured to obtain the hydrogen pressure data and hydrogen concentration data of the fuel cell system; The data processing module (12) is configured to perform data smoothing processing on the hydrogen pressure data and the hydrogen concentration data based on discrete wavelet transform to obtain time series data, and input the time series data into a preset LSTM-AE neural network model to obtain a time series feature vector and sensor network graph data corresponding to the time series data; The leakage detection module (13) is configured to perform data extraction and analysis operations on the time series feature vector and the sensor network graph data based on a hydrogen leakage detection neural network model to obtain a hydrogen leakage detection result.

9. An electronic device, characterized in that, It includes a processor (21), a memory (25), a user interface (23) and a network interface (24). The memory (25) is used to store instructions. The user interface (23) and the network interface (24) are used to communicate with other devices. The processor (21) is used to execute the instructions stored in the memory (25) so that the electronic device (2) executes the method according to any one of claims 1-7.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, the steps of the method according to any one of claims 1-7 are implemented.

Citation Information

Patent Citations

  • Method and device for detecting hydrogen leakage of fuel cell and computer readable storage medium

    CN118107392A