Time-frequency aligned EEG signal analysis methods, devices, equipment and media

By combining time-frequency alignment and feature extraction networks, the problem of uncorrected frequency differences in cross-domain applications of EEG signals is solved, achieving higher classification accuracy and stability, and improving the model's cross-domain adaptability.

CN121176923BActive Publication Date: 2026-01-30GUANGZHOU UNIVERSITY
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511735325.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-11-25
Publication Date
2026-01-30
Estimated Expiration
2045-11-25

AI Technical Summary

Technical Problem

Existing EEG signal analysis methods have failed to effectively correct for frequency-level differences in cross-domain applications, resulting in limited model generalization ability, especially a significant decrease in classification accuracy between different subjects or different experimental sessions.

Method used

A time-frequency aligned EEG signal analysis method is adopted. Wavelet transform, global covariance matrix decomposition, and whitening matrix calibration are used to process the time and frequency components of the EEG signal respectively. The whitening matrix is ​​generated to calibrate the coefficient matrix, and the time-frequency aligned multi-channel EEG signal is reconstructed. The cross-domain generalization ability of the model is improved by combining feature extraction network and domain adversarial neural network.

Benefits of technology

It effectively reduced the distributional differences between EEG data from different sources, improved the model's performance on new user or new session data, enhanced the accuracy and stability of decoding, prevented negative transfer, and achieved stronger cross-domain generalization ability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121176923B_ABST
    Figure CN121176923B_ABST
Patent Text Reader

Abstract

A time-frequency aligned EEG signal analysis method, apparatus, device, and medium are disclosed, aiming to consider and reduce the temporal and frequency distribution differences of EEG signals, thereby more effectively improving the model's generalization ability across different subjects or experimental sessions. The method involves time-frequency decomposition of the EEG signal, calculating global statistics in each frequency band, and performing whitening transformation to calibrate the signal. Finally, the multi-channel EEG signal is reconstructed to obtain a time- and frequency-aligned multi-channel EEG signal. This invention's time-frequency alignment process comprehensively reduces the distribution differences between EEG data from different sources in both time and frequency dimensions. Compared to methods that only align the time domain, it more effectively improves the model's performance on new user or new session data, thus more effectively enhancing the model's generalization ability across different subjects or experimental sessions.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of electroencephalogram (EEG) signal analysis technology, and in particular to a time-frequency aligned EEG signal analysis method, device, equipment and medium. Background Technology

[0002] Brain-computer interface (BCI) technology allows people to control external devices using electroencephalogram (EEG) signals. Motor imagery is an important paradigm in this field, where users imagine the movement of body parts without actually performing the action. The EEG device records the corresponding EEG signals, and algorithms then decode the imagined movement type.

[0003] EEG signals are easily affected by individual differences and recording conditions, causing a significant drop in classification accuracy when a model trained on one subject's data is directly applied to data from another subject or different trials of the same subject. Existing transfer learning methods primarily focus on adjusting the signal distribution over time, neglecting the differences in signal distribution across different frequency components, resulting in insufficient alignment. Current cross-domain methods mostly focus on alignment only in the time domain. When EEG signals from different domains differ not only in waveform but also in frequency intensity and dominant frequency distribution, these methods cannot effectively correct for these frequency-level differences, limiting the improvement in model generalization ability. For example, methods based on covariance matrix alignment represent the spatial characteristics of the data by calculating the covariance matrix between multiple channels of the EEG signal, and then aligning the covariance matrices of the source and target domains to a common reference point through mathematical transformations to reduce distribution differences. However, this method mainly performs overall alignment in the time domain and does not delve into the frequency component level for individual processing. Summary of the Invention

[0004] To address the aforementioned problems, this invention provides a time-frequency aligned electroencephalogram (EEG) signal analysis method, apparatus, device, and medium.

[0005] To achieve the above objectives, the technical solution adopted by the present invention is as follows:

[0006] On one hand, the present invention provides a time-frequency aligned EEG signal analysis method, comprising:

[0007] Input the raw, multichannel EEG signals related to motor imagery to be analyzed;

[0008] The original multi-channel EEG signal is subjected to time-frequency alignment processing to obtain a time-frequency aligned multi-channel EEG signal. The time-frequency alignment processing includes the following steps:

[0009] Based on the selected wavelet basis and decomposition level, discrete wavelet transform is performed on each sample and each channel of the original multichannel EEG signal to obtain decomposition coefficients, where the input space of the multichannel EEG signal is defined as... ,in For the sample size, For the number of brainwave channels, This represents the number of sampling points in the time series.

[0010] For each decomposition level, extract the decomposition coefficients of all channels and construct a coefficient matrix;

[0011] Calculate the corresponding global covariance matrix based on the coefficient matrix of the decomposition level;

[0012] Eigenvalue decomposition is performed on the global covariance matrix of the decomposition level to generate a whitening matrix;

[0013] For each sample and decomposition level, the coefficient matrix is ​​calibrated using a whitening matrix, and the corresponding decomposition coefficients in the calibrated coefficient matrix are updated.

[0014] The calibrated decomposition coefficients are subjected to inverse discrete wavelet transform to reconstruct the signal, resulting in a time-frequency aligned multichannel EEG signal.

[0015] The time-frequency aligned multichannel EEG signal is input into a trained motor imagery category prediction model to obtain the category of motor imagery.

[0016] On the other hand, a time-frequency aligned electroencephalogram (EEG) signal analysis device is provided, comprising:

[0017] The input module is used to input the raw multichannel EEG signals related to motor imagery that are to be analyzed.

[0018] The time-frequency processing module is used to perform time-frequency alignment processing on the raw multi-channel EEG signals to obtain time-frequency aligned multi-channel EEG signals. The time-frequency alignment processing includes the following steps:

[0019] Based on the selected wavelet basis and decomposition level, discrete wavelet transform is performed on each sample and each channel of the original multichannel EEG signal to obtain decomposition coefficients, where the input space of the multichannel EEG signal is defined as... ,in For the sample size, For the number of brainwave channels, This represents the number of sampling points in the time series.

[0020] For each decomposition level, extract the decomposition coefficients of all channels and construct a coefficient matrix;

[0021] Calculate the corresponding global covariance matrix based on the coefficient matrix of the decomposition level;

[0022] Eigenvalue decomposition is performed on the global covariance matrix of the decomposition level to generate a whitening matrix;

[0023] For each sample and decomposition level, the coefficient matrix is ​​calibrated using a whitening matrix, and the corresponding decomposition coefficients in the calibrated coefficient matrix are updated.

[0024] The calibrated decomposition coefficients are subjected to inverse discrete wavelet transform to reconstruct the signal, resulting in a time-frequency aligned multichannel EEG signal.

[0025] The prediction module inputs the time-frequency aligned multi-channel EEG signals into a trained motor imagery category prediction model to obtain the category of motor imagery.

[0026] On the other hand, the present invention provides a computer device including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the above-described time-frequency aligned electroencephalogram signal analysis method.

[0027] On the other hand, the present invention provides a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the steps of the above-described time-frequency aligned electroencephalogram (EEG) signal analysis method.

[0028] On the other hand, the present invention provides a computer program product stored on a computer-readable storage medium and including computer instructions that, when executed by a processor, cause a computer device to implement the steps of the time-frequency aligned electroencephalogram (EEG) signal analysis method described above.

[0029] Compared with the prior art, the technical effects of the present invention are as follows:

[0030] To address this, this invention proposes a time-frequency aligned EEG signal analysis method. This method aims to consider and reduce the temporal and frequency distribution differences of EEG signals, thereby more effectively improving the model's generalization ability across different subjects or experimental sessions. By performing time-frequency decomposition on the EEG signals, global statistics are calculated in each frequency band, and whitening transformation is applied to calibrate the signals. Finally, the multi-channel EEG signals are reconstructed to obtain time- and frequency-aligned multi-channel EEG signals. Through the time-frequency alignment processing proposed in this invention, the distribution differences between EEG data from different sources can be reduced more comprehensively in both time and frequency dimensions. Compared to methods that only align the time domain, this method can more effectively improve the model's performance on new user or new session data, thus more effectively improving the model's generalization ability across different subjects or experimental sessions.

[0031] Finally, while addressing the above difficulties, a feature extraction network is established that effectively captures long-term EEG patterns without being overly complex or prone to overfitting, in order to improve the accuracy and stability of decoding. Attached Figure Description

[0032] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the structures shown in these drawings without creative effort.

[0033] Figure 1 This is a flowchart of a time-frequency aligned EEG signal analysis method in one embodiment;

[0034] Figure 2 This is a flowchart of the time-frequency alignment process in one embodiment;

[0035] Figure 3 This is a schematic diagram of the feature extraction network structure in one embodiment;

[0036] Figure 4 This is a training block diagram of a motion imagination category prediction model in one embodiment. Detailed Implementation

[0037] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present invention.

[0038] Reference Figure 1 One embodiment provides a time-frequency aligned EEG signal analysis method, comprising:

[0039] Input the raw, multichannel EEG signals related to motor imagery to be analyzed;

[0040] The original multi-channel EEG signal was time-frequency aligned to obtain the time-frequency aligned multi-channel EEG signal.

[0041] The time-frequency aligned multichannel EEG signal is input into a trained motor imagery category prediction model to obtain the category of motor imagery.

[0042] Among them, reference Figure 2 and Figure 3 The time-frequency alignment process described in the above embodiments includes the following steps:

[0043] Based on the selected wavelet basis and the number of decomposition layers, discrete wavelet transform is performed on each sample and each channel of the original multichannel EEG signal to obtain the decomposition coefficients.

[0044] For each decomposition level, extract the decomposition coefficients of all channels and construct a coefficient matrix;

[0045] Calculate the corresponding global covariance matrix based on the coefficient matrix of the decomposition level;

[0046] Eigenvalue decomposition is performed on the global covariance matrix of the decomposition level to generate a whitening matrix;

[0047] For each sample and decomposition level, the coefficient matrix is ​​calibrated using a whitening matrix, and the corresponding decomposition coefficients in the calibrated coefficient matrix are updated.

[0048] The calibrated decomposition coefficients are subjected to inverse discrete wavelet transform to reconstruct the signal, resulting in a time-frequency aligned multichannel EEG signal.

[0049] In one embodiment, the input space of the multi-channel EEG signal is defined as ,in For the sample size, For the number of brainwave channels, The specific process of time-frequency alignment processing of multi-channel EEG signals, given the number of time-series sampling points, is as follows:

[0050] Based on the selected wavelet basis and decomposition layer number For each sample and each channel Perform Discrete Wavelet Transform (DWT) to decompose multichannel EEG signals into decomposition coefficients at different decomposition levels. Includes approximation coefficients and detail coefficient The formula for Discrete Wavelet Transform (DWT) is as follows:

[0051]

[0052] For each decomposition level Extracting the first The decomposition coefficients of all channels at each frequency level are arranged into a coefficient matrix. ;

[0053]

[0054] in , The number of decomposition layers, For the first The length of the decomposition coefficients at the decomposition level, the th The coefficient matrix of each decomposition level .

[0055] For the Each decomposition level, global covariance matrix as follows:

[0056]

[0057] in This is a regularization parameter used to ensure that the matrix is ​​invertible. for Identity matrix.

[0058] right Perform eigenvalue decomposition:

[0059]

[0060] in The eigenvector matrix, It is an eigenvalue vector;

[0061] Generate whitening matrix:

[0062]

[0063] To ensure numerical stability, the whitening matrix is... The eigenvalues ​​that are less than 0 or infinite are set to 0 to obtain the final whitening matrix.

[0064] For each sample and each decomposition level, a whitening matrix is ​​used. For the coefficient matrix After calibration, the calibrated coefficient matrix is ​​as follows:

[0065]

[0066] This updates the corresponding decomposition coefficients in the calibrated coefficient matrix;

[0067] After calibration, all The global covariance matrix of the samples is:

[0068]

[0069] For the calibrated decomposition coefficients The signal is reconstructed using inverse discrete wavelet transform, and the reconstructed signal is truncated to its original length. The time-frequency aligned multi-channel EEG signals were obtained. .

[0070] The time-frequency alignment processing proposed in the above embodiments can more comprehensively reduce the distribution differences between EEG data from different sources in both time and frequency dimensions. Compared with methods that only align the time domain, it can more effectively improve the model's performance on new user or new session data, thereby more effectively improving the model's generalization ability across different subjects or different experimental sessions. The motor imagery category prediction model includes a feature extraction network and a task label classifier. The feature extraction network extracts features from the time-frequency aligned multi-channel EEG signals, and the task label classifier predicts the category of motor imagery based on the extracted features. The settings of the feature extraction network and the task label classifier can be implemented based on existing technical solutions in the field. The feature extraction network is a convolutional neural network-based model; the task label classifier is a neural network containing fully connected layers and a softmax output layer.

[0071] In one embodiment, reference is made to Figure 4 A training method for a motion imagery category prediction model is proposed, including:

[0072] The raw multi-channel EEG signals used for training are acquired. A portion of the multi-channel EEG signals come from the source domain, and the corresponding motor imagery category labels of the multi-channel EEG signals from the source domain are known. The remaining multi-channel EEG signals come from the target domain, and the motor imagery category labels of the multi-channel EEG signals from the target domain are unknown.

[0073] The multi-channel EEG signals from the source domain and the target domain are subjected to time-frequency alignment processing to obtain the corresponding time-frequency aligned multi-channel EEG signals.

[0074] A motor imagery category prediction model is constructed, comprising a feature extractor and an attention-enhanced domain adversarial neural network. The feature extractor extracts EEG signal features from time-frequency aligned multi-channel EEG signals. The attention-enhanced domain adversarial neural network includes a task label classifier, a domain discriminator, and a dynamic domain attention module. The dynamic domain attention module generates attention weights based on EEG signal features and calculates an attention matrix based on a self-attention mechanism. The attention matrix is ​​used to weight the EEG signal features to obtain stable attention features rich in domain-invariant information. The task label classifier receives the attention features and outputs the probability distribution of their belonging to each motor imagery category label. The domain discriminator receives the attention features and outputs the probability of their belonging to the target domain and the source domain.

[0075] The time-frequency aligned multichannel EEG signals from the source and target domains are input into the motor imagery category prediction model. The time-frequency aligned multichannel EEG signals from the source domain are used to train the task label classifier. The task classification loss is calculated based on the probability distribution of each motor imagery category label output by the task label classifier. The time-frequency aligned multichannel EEG signals from the source and target domains are used to train the domain discriminator. The domain discriminator's output probability of the domain label belonging to the target and source domains is used to calculate the domain discriminator loss. The total loss function is constructed with the goal of minimizing the task classification loss and maximizing the domain discriminator loss. The model parameters of the feature extractor, task label classifier, domain discriminator, and dynamic domain attention module are updated. The process is iterated until convergence, resulting in the trained motor imagery category prediction model.

[0076] The above embodiments perform time-frequency alignment processing on the multi-channel EEG signals from the source domain and the target domain, respectively. The time-frequency alignment processing method has been described in detail in the foregoing embodiments and will not be repeated here.

[0077] Applying the motor imagery category prediction model provided in the above embodiments to a time-frequency aligned EEG signal analysis method, the scheme mainly includes four modules: a time-frequency alignment processing module, a feature extractor, a task label classifier, and a domain discriminator. First, the time-frequency alignment processing module performs time-frequency alignment processing on the multi-channel EEG signals to calibrate the phase information in different frequency bands of the multi-channel EEG signals, thereby reducing deviations caused by individual differences and recording conditions. The time-frequency aligned multi-channel EEG signals are then mapped into feature vectors by the feature extractor. The model parameters of the feature extractor are determined by... The representation is as follows: After the feature extractor performs initial feature extraction through the time-frequency spatial convolution module, the bidirectional attention temporal network further processes the initial features to capture long-range temporal dependencies. The output of the feature extractor is simultaneously input into the task label classifier and the domain discriminator, where the task classification loss and the domain discriminator loss are jointly optimized through domain attention and adversarial training, thereby achieving domain-invariant feature learning.

[0078] One embodiment proposes a feature extractor, wherein the specific process of feature extraction includes:

[0079] The time-frequency aligned multi-channel EEG signal is input into the spatiotemporal convolution module of the feature extractor, and temporal convolution, spatial convolution and separable convolution are performed sequentially to extract preliminary spatiotemporal features.

[0080] The initial spatiotemporal features are input into a bidirectional attention temporal network, and then processed by the attention mechanism and the bidirectional temporal convolutional network in the bidirectional attention temporal network to weight and enhance the feature channels, and capture the temporal dependencies from the forward and backward directions respectively.

[0081] The positive and negative features output by the bidirectional temporal convolutional network are weighted and fused to generate EEG signal features with temporal context information.

[0082] Specifically, the spatiotemporal convolution module TFA It includes temporal convolutional layers, spatial convolutional layers, and separable convolutional layers:

[0083] Time-frequency aligned multichannel EEG signals Input spatiotemporal convolution module TFA To meet the model input requirements, an additional feature channel dimension F needs to be added. Therefore, the time-frequency aligned multichannel EEG signal input to the spatiotemporal convolution module is represented as follows: ;

[0084] The temporal convolution is performed using a set of sizes. The filter aligns the time-frequency input multichannel EEG signal with the time dimension. Perform convolution operations to capture waveform features in EEG signals and output... A time feature map;

[0085] The spatial convolution, for the temporal feature map output by the temporal convolution, employs... The size is The filter performs depthwise convolution, filtering along the channel dimension. This operation can be represented as... Firstly, through right Convolution is performed in the time dimension, and then a space dimension of size is applied. The convolution kernel (where (Number of channels), enabling independent spatial feature extraction for each temporal feature map, thereby learning the spatial coupling relationship features between different channels, and outputting... Spatial feature map ,in C represents the depth expansion factor, and C represents the number of brainwave channels.

[0086] The separable convolution is used to fuse the multi-channel EEG signals extracted through the temporal convolutional layer. EEG The characteristics of local patterns or dynamic changes of a signal in the time dimension Features extracted through spatial convolution in depthwise separable convolution that reflect the interrelationships or spatial distribution patterns between different EEG channels C Thus, preliminary spatiotemporal characteristics were obtained.

[0087] The aforementioned waveform features and spatial relationship features are first extracted using temporal convolution to obtain local temporal information, and then spatial depthwise convolution is used to capture the spatial correlation between channels, ultimately yielding preliminary spatiotemporal features. And output, This represents the time length after pooling. Pooling layers are used during separable convolution to reduce data volume, and batch normalization is used... Activation function and To stabilize and optimize training.

[0088] A bidirectional attention temporal network was introduced into the feature extractor. It can capture long-range temporal dependencies using a bidirectional TCN structure and focus on important features through an attention mechanism. At the same time, the structure is relatively simple, avoiding the risk of overfitting, thereby extracting features with stronger discriminative power and solving the problems of long-range dependencies and overfitting.

[0089] Specifically, in bidirectional attentional temporal networks, the attention mechanism introduced can be the SE attention mechanism.

[0090] The SE attention mechanism is implemented by the SE attention module, and specifically includes the following steps:

[0091] Preliminary spatiotemporal characteristics of the input SE attention module Channel statistics vectors are generated through global average pooling (GAP) operation. , Specifically, it includes:

[0092] Preliminary spatiotemporal characteristics of the input SE attention module For each feature channel in the dataset, calculate the first... The average value of each feature channel at all time points. ;

[0093]

[0094] This represents the initial spatiotemporal features of the input SE attention module. The first in The first feature channel, the first t The value at each time point; Indicates the first The average value of each feature channel at all time points;

[0095] The average values ​​of each feature channel are combined to form a length of F 2-vector channel statistics vector , .

[0096] The global average pooling operation is performed in the time dimension. T c The average calculation is performed to compress the entire time series of each channel into a single numerical statistic. .

[0097] Based on channel statistical information vector Through a two-layer fully connected The network is transformed to generate the channel scaling factor. , :

[0098]

[0099] in and These are the weights of the fully connected layer. This is the reduction rate, which can be set to 16. yes Activation function yes function.

[0100] Based on channel scaling factor The initial spatiotemporal features are modulated using element-wise multiplication to obtain the modulated feature sequence. :

[0101]

[0102] This indicates element-wise multiplication.

[0103] Through the aforementioned attention mechanism, the interdependencies between channels are explicitly modeled, the importance of each channel feature is adaptively calibrated, the weights of important feature channels are automatically learned and increased, and secondary channels are suppressed.

[0104] feature sequence Input bidirectional temporal convolutional network The Including forward temporal convolutional networks and inverse temporal convolutional networks Process the forward and reverse sequences separately, and output the forward features. and reverse features Finally, positive features and reverse features Weighted fusion is performed to form a feature representation that includes both past and future contextual information, i.e., EEG signal features with temporal contextual information. :

[0105]

[0106] in and These are learnable parameters. yes The function ensures that the weights are normalized to the range [0,1].

[0107] Bidirectional temporal convolutional networks will convert feature sequences The data is fed into a Temporal Convolutional Network (TCN) that processes data from front to back and from back to front, respectively. The TCN utilizes a technique called "dilated convolution" to capture long-term historical information even with a limited number of layers. Each TCN branch consists of multiple residual blocks, each containing a depthwise separable dilated causal convolution, batch normalization, an ELU activation, and a random deactivation with a dropout rate of 0.3. The depthwise separable dilated causal convolution ensures that the model relies only on past information, preserving temporal causality, while by increasing the dilation factor, the TCN expands its receptive field size (RFS) to capture long-term dependent features.

[0108]

[0109] in, It is the kernel size of depthwise separable dilatant causal convolution. L This refers to the number of stacked TCN layers. In one embodiment, these parameters are set to... =7 and L =2, thus obtaining an RFS of 37.

[0110] It is understandable that the introduced attention mechanism is not limited to the SE attention mechanism; other types of attention mechanisms, such as efficient channel attention, can also be considered. or convolutional block attention module In certain scenarios requiring causality, bidirectional temporal convolutional networks can be simplified to unidirectional ones. (Using only front-to-back temporal convolutional networks).

[0111] The introduced domain discriminator can be trained together with the feature extractor and task label classifier of the backbone network. The feature extractor attempts to extract domain-invariant features that the domain discriminator cannot distinguish between the data source (source domain or target domain), hoping that these features will be universal. This framework assumes that in the joint space... There exist two related but distinct distributions: the source distribution and the target distribution, denoted as . The target distribution is denoted as In this case, the data This represents data from the target domain. Specifically, the source domain includes labeled data samples from training subjects. ,follow In contrast, the target domain consists of data samples from test subjects. Composition, subject to Domination. During model training, labeled source domain samples are utilized. and unlabeled target domain samples The primary objective is to accurately infer the target domain samples during the evaluation phase. tags However, this "adversarial" approach can sometimes damage useful information. Domain adversarial learning forces all features to become domain-invariant, which may mistakenly eliminate features that, while differing across domains, are actually important for the classification task, resulting in "negative transfer." Negative transfer occurs when existing adversarial learning methods, in forcing data features across different domains to become similar, may smooth out features that were originally helpful for classification but differ across domains, thus worsening the model's performance on new data. Patterns related to motor imagery in EEG signals often persist for a period of time. Traditional convolutional neural networks struggle to capture such long-term dependencies, meaning they lack sufficient long-range dependency modeling. Like... These types of models, which can capture long dependencies, are prone to overfitting the training data when the amount of data is usually small, due to their complex structure and too many parameters, which affects the actual application effect.

[0112] Furthermore, this invention improves the domain adversarial learning process, enabling it to more intelligently select features to be aligned, thereby preventing negative transfer. The motor imagery category prediction model includes a feature extractor and an attention-enhanced domain adversarial neural network. The feature extractor is used to extract EEG signal features from the time-frequency aligned multi-channel EEG signals. The attention-enhanced domain adversarial neural network (... DANN It includes a task label classifier, a domain discriminator, and a dynamic domain attention module. The feature extractor (i.e., the feature extraction network), task label classifier, domain discriminator, and dynamic domain attention module together form a cross-domain adversarial processing network.

[0113] Attention-enhanced domain adversarial neural networks ( DANN Through an adversarial training mechanism, the task classification loss and domain adversarial loss are jointly optimized. The ultimate goal is to enable the feature extractor to produce feature representations that are both highly discriminative to the motion imagery task and indistinguishable from the data source domain (subjects or conversations), thereby outputting accurate and highly generalizable motion imagery category prediction results.

[0114] The attention-enhanced domain adversarial neural network includes a task label classifier. Domain discriminator And dynamic domain attention module.

[0115] Feature extractor Output EEG signal features with temporal context information Input into an attention-enhanced domain adversarial neural network ( DANN The dynamic domain attention module, in which the processing steps include:

[0116] Attention weights are generated using a two-layer fully connected network. :

[0117]

[0118] in and For the weights of a two-layer fully connected network, and r is the reduction rate used to decrease computational complexity. , The input is EEG signal features with temporal context information;

[0119] Based on the self-attention mechanism, the attention matrix between features is calculated. for:

[0120]

[0121] in , Represents matrix multiplication. Indicates the scaling factor. It is a normalized exponential function, scaling factor It reduces the numerical instability of large-dimensional features.

[0122] The attention matrix is ​​used to weight the features. This process aims to enhance discriminative features that are important for task classification and are shared between the source and target domains, while suppressing domain-specific information that may lead to negative transfer.

[0123]

[0124] Meanwhile, to improve stability, residual connections and layer normalization are introduced to generate stable attention features rich in domain-invariant information. This is used by subsequent task label classifiers and domain discriminators, where layer normalization... Standardize the feature vectors along the channel dimension:

[0125]

[0126] The task label classifier includes a fully connected layer and The activation function is used to receive attention features and output their probability distributions belonging to each motion image category label.

[0127] During the training of the task label classifier, attention features corresponding to the multi-channel EEG signals after time-frequency alignment from the source domain are input into the task label classifier. The task label classifier outputs the probability distribution of samples belonging to each motion image category, and calculates the task classification loss based on this distribution.

[0128]

[0129] in For the first i A true motor imagery category label derived from multi-channel EEG signals after time-frequency alignment from the source domain. Right now For task label classifier The output of the first i Predicted motor imagery category labels from multichannel EEG signals aligned to the source domain time-frequency. For task label classifier Model parameters, For feature extractor Model parameters, Feature extractor From the i Signal features extracted from multichannel EEG signals after time-frequency alignment of the source domain.

[0130] The domain discriminator is a fully connected layer followed by a sigmoid activation function, acting as a classifier to determine whether data originates from the source or target domain. It is a binary classifier used to determine whether the input attention features come from the source or target domain. During training, attention features from time-frequency aligned multi-channel EEG signals from both the source and target domains are used to train the discriminator. Attention features Input to domain discriminator Domain discriminator Attempt to determine whether the feature originates from the source domain or the target domain, and output a domain label probability. Calculate the domain adversarial loss based on this probability. :

[0131]

[0132] in For the first i The true domain labels of the time-frequency aligned multichannel EEG signals. Domain discriminator Model parameters.

[0133] Gradient inversion layer Gradient reversal is performed on the domain discrimination loss, gradient reversal layer During the forward propagation process, it is an identity transformer, a gradient reversal layer. The input features are passed to the subsequent domain discriminator unchanged. Using a gradient inversion layer Forward propagation positive output, domain discriminator The update is performed with the goal of minimizing the domain classification loss, thereby continuously improving its ability to distinguish between the source domain and the target domain.

[0134] Joint optimization and parameter update aim to minimize the task classification loss while maximizing the domain discrimination loss, and construct the total loss function. :

[0135]

[0136] in These are the model parameters for the feature extractor, the task label classifier, and the domain discriminator, respectively. , The first i The task classification loss and domain discrimination loss are corresponding to the multi-channel EEG signals. Let the total number of original multi-channel EEG signals used for training be . The first to the second The first is a multichannel EEG signal from the source domain, the second... The first to the second The multi-channel EEG signals are multi-channel EEG signals from the target domain. For dynamic weights.

[0137] In actual training, the model parameters of the feature extractor, the task label classifier, and the domain discriminator are updated alternately. The task classification loss and domain discrimination loss are jointly optimized, and the model parameters of the feature extractor, task label classifier, dynamic domain attention module and domain discriminator are updated. The process is iterated until convergence, and the current model parameters of the feature extraction network, task label classifier, dynamic domain attention module and domain discriminator are retained to complete the adversarial training.

[0138] The Dynamic Domain Attention (DDA) module is crucial for preventing negative transfer. Before the EEG signal features are fed into the domain discriminator, they pass through the DDA module, a small neural network. The input EEG signal features are learned through two fully connected layers to generate an attention weight vector. This attention weight vector identifies which features are cross-domain shared and useful for classification (and should be retained), and which are domain-specific or interfering (and should be suppressed). A multiplier multiplies the attention weight vector with the input EEG signal features to obtain a weighted feature, which is then fed into the domain discriminator. The method for generating the attention weight vector is not limited to learning through two fully connected layers; it can also be implemented based on other existing self-attention mechanisms in the field. Those skilled in the art can make a reasonable choice based on the specific circumstances.

[0139] The overall training objective of adversarial training is to minimize the task classification error of the task label classifier while simultaneously preventing the domain discriminator from distinguishing which domain a feature originates from (achieved through a gradient reversal layer). Dynamic weights λ control the intensity of the domain adversarial process. The introduction of a dynamic domain attention module makes this adversarial process more intelligent and selective. The addition of a dynamic domain attention (DDA) module to adversarial training intelligently distinguishes and prioritizes discriminative features shared across domains, preserving useful domain-specific information and effectively preventing negative transfer (solving the negative transfer problem). The adversarial training process uses the Adam optimizer and employs a cosine annealing strategy to adjust the learning rate.

[0140] In summary, this invention, through the synergistic effect of these technologies, has been fully validated on the internationally recognized standard brain-computer interface datasets BCI Competition IV 2a (4-class classification) and 2b (2-class classification), covering three experimental scenarios: within the same session, between different sessions, and between different subjects. It achieved excellent and stable cross-domain classification performance on these publicly available standard datasets, verifying its effectiveness and practicality. Some hyperparameters of the spatiotemporal convolutional block in the feature extractor (such as the number of filters in the first layer F1 and the multiplier D) can be adjusted according to different datasets (e.g., for the standard brain-computer interface dataset BCI Competition IV 2a, F1=24, D=3; for the standard brain-computer interface dataset BCI Competition IV 2b, F1=8, D=2).

[0141] The overall performance is evaluated using classification accuracy and the Kappa coefficient, which can be calculated as follows:

[0142]

[0143] in, The observed consistency rate, This represents the expected probability of consistency.

[0144] To demonstrate the effectiveness of this invention, the proposed method model is compared with existing methods to illustrate the effectiveness and superiority of this invention. The various existing methods used are described in Table 1.

[0145] Table 1

[0146]

[0147] Referring to Table 2, on the internationally recognized brain-computer interface standard dataset BCI Competition IV 2a (which includes four types of motor imagery tasks: left hand, right hand, foot, and tongue), the DATNet model proposed in this invention achieved the best average classification accuracy (ACC) and Kappa coefficient in all three evaluation scenarios, fully demonstrating its excellent cross-domain generalization ability.

[0148] Table 2

[0149]

[0150] In Table 2: This indicates that DATNet's accuracy or Kappa coefficient is significantly higher than the comparison method, and the statistical p-value is less than 0.05. This indicates that DATNet's accuracy or Kappa coefficient is significantly higher than the comparison method, and the statistical p-value is less than 0.01. Bold text indicates that the method achieved the best accuracy (ACC) or Kappa coefficient in the corresponding scenario.

[0151] As shown in Table 2, the DATNet model proposed in this invention has the highest ACC (89.27%) and Kappa (0.86) among all methods in the Session-dependent scenario of the 2a dataset, so it is shown in bold.

[0152] Session-dependent evaluation: In this scenario, the model was trained using data from a single session with the same subject and tested within the same session. DATNet achieved an accuracy of 89.27% ​​± 7.08% and a Kappa score of 0.86 ± 0.09, significantly outperforming all comparison methods (p < 0.01). This demonstrates that DATNet possesses extremely high decoding accuracy in typical use cases. Comparison methods included classic CNN architectures such as DeepConvNet (76.20%), ShallowConvNet (75.93%), and EEGNet (75.08%), as well as recent state-of-the-art models like ATCNet (84.49%). DATNet's performance advantage stems from the effective fusion of its time-frequency alignment preprocessing and the BiATCN feature extraction module.

[0153] Session-independent evaluation: In this scenario, training is performed using one session dataset and testing on another different session dataset, simulating user interaction with the BCI system on different days. DATNet maintains its leading position with an accuracy of 86.61% ± 6.31% and a Kappa value of 0.82 ± 0.08, significantly outperforming all comparison methods except ATCNet (p < 0.01). In this more challenging scenario, ATCNet (83.26%) performs second best, while models such as EEGConformer (58.10%) show significant performance decline, highlighting DATNet's robustness to temporal non-stationarity.

[0154] Subject-independent evaluation: This scenario employs leave-one-out-of-target (LOSO-HO) cross-validation, meaning the model is trained on data from all other subjects except the target subject and tested only on the target subject's data. This is the gold standard for measuring a model's cross-user generalization ability. DATNet still performs best, with an accuracy of 75.42% ± 8.68% and a Kappa value of 0.67 ± 0.12. Its accuracy is significantly higher than EEGNet (68.06%, p < 0.05) and significantly better than all other methods (p < 0.01). In this most challenging scenario, most models experience severe performance degradation, but DATNet, with its DANN domain adversarial mechanism and time-frequency alignment module, effectively mitigates the domain shift problem caused by individual differences.

[0155] On the BCI Competition IV 2b dataset (which includes two types of motion visualization tasks: left hand vs. right hand), DATNet also demonstrates strong competitiveness:

[0156] Session dependency evaluation: DATNet achieved an accuracy of 87.38% ± 7.27% and a Kappa score of 0.75 ± 0.15, comparable to EEGNex (87.09%), both representing state-of-the-art performance. EEGNex, a pure convolutional network, extracts features through depthwise separable convolutions and dilated convolutions, performing exceptionally well in this scenario and serving as a strong competitor to DATNet.

[0157] Session-independent evaluation: DATNet achieved the highest accuracy of 90.02% ± 7.52% and a KPA value of 0.80 ± 0.15, significantly outperforming EEGConformer (78.93%, p < 0.01). EEGConformer combines CNN and Transformer, but its global attention mechanism may not effectively focus on key discriminative information when handling inter-session variations, resulting in performance lagging behind DATNet.

[0158] Independent assessment by participants showed that DATNet achieved an accuracy of 86.97% ± 9.05% and a KPa value of 0.74 ± 0.18, comparable to EEGNet (86.82%), both reaching optimal performance in this scenario. EEGNet, as a lightweight and compact network, demonstrated good robustness and efficiency in scenarios with small sample sizes and cross-user scenarios due to its efficient depthwise separable convolutional design, complementing DATNet.

[0159] In summary, comparing the balance between classification accuracy, parameters, and MAC of all models, the proposed motor imagery category prediction model, DATNet, not only achieved the highest accuracy (86.61% and 90.02%) on the internationally recognized brain-computer interface standard datasets BCI Competition IV2a and 2b in session-independent evaluations, but also achieved an effective balance between EEG decoding performance and model complexity.

[0160] Referring to Table 2, on the internationally recognized brain-computer interface standard dataset BCI Competition IV 2a (4-class classification), the proposed motor imagery category prediction model DATNet achieved the best average accuracy and KPA value in all three assessment scenarios. Specifically, for session-dependent assessments, DATNet achieved an accuracy of 89.27% ​​and a KPA value of 0.86, significantly outperforming all compared methods. For session-independent assessments, DATNet maintained its leading position (ACC: 86.61%, KPA: 0.82), significantly outperforming all compared methods except ATCNet. In the more challenging subject-independent assessments, DATNet also performed best (ACC: 75.42%, KPA: 0.67), with an accuracy significantly higher than EEGNet (p<0.05) and significantly outperforming all other methods.

[0161] On the internationally recognized standard brain-computer interface dataset BCI Competition IV 2b (2-class classification), the motor imagery category prediction model DATNet also demonstrated strong competitiveness. For session-dependent assessments, DATNet (ACC: 87.38%, Kappa value: 0.75) and EEGNex (ACC: 87.09%, Kappa value: 0.74) performed similarly, both showing excellent results. However, for session-independent assessments, DATNet achieved the highest accuracy of 90.02% and the highest Kappa value of 0.80, demonstrating its advantage in handling inter-session variability and significantly outperforming EEGConformer. In subject-independent analyses, DATNet (ACC: 86.97%, Kappa value: 0.74) and EEGNet (ACC: 86.82%, Kappa value: 0.74) performed comparablely, both achieving optimal performance in this scenario.

[0162] The balance between classification accuracy, parameters, and MAC was compared among all models. The proposed motor imagery category prediction model, DATNet, not only achieved the highest accuracy (86.61% and 90.02%) on the internationally recognized brain-computer interface standard datasets BCI Competition IV 2a and 2b in session-independent evaluations, but also achieved an effective balance between EEG decoding performance and model complexity.

[0163] The time-frequency alignment method proposed in this invention transforms the average covariance matrix into an identity matrix through time-frequency alignment. This is essentially a standardization operation, forcing data from different sources (subjects) to maintain consistency in second-order statistics. After the time-frequency alignment process, the covariance matrices of all subjects show significantly enhanced consistency in both structure and numerical scale, tending towards a more standardized form. This consistency reduces inter-domain differences, making the data distribution more similar. This facilitates the transfer of models trained in one domain to another and improves the model's generalization ability. This is precisely the goal pursued by transfer learning. After time-frequency alignment, the data distribution of different subjects tends to be consistent, indicating that subject-specific characteristics have been effectively weakened. According to the correlation analysis of the average covariance matrix among subjects, the correlation coefficients among subjects in the aligned data mostly increase compared to the original data. The alignment technique successfully reduces the variability among subjects and enhances the consistency of data representation among subjects.

[0164] On the other hand, one embodiment provides a time-frequency aligned electroencephalogram (EEG) signal analysis device, comprising:

[0165] The input module is used to input the raw multichannel EEG signals related to motor imagery that are to be analyzed.

[0166] The time-frequency processing module is used to perform time-frequency alignment processing on the raw multi-channel EEG signals to obtain time-frequency aligned multi-channel EEG signals. The time-frequency alignment processing includes the following steps:

[0167] Based on the selected wavelet basis and decomposition level, discrete wavelet transform is performed on each sample and each channel of the original multichannel EEG signal to obtain decomposition coefficients, where the input space of the multichannel EEG signal is defined as... ,in For the sample size, For the number of brainwave channels, This represents the number of sampling points in the time series.

[0168] For each decomposition level, extract the decomposition coefficients of all channels and construct a coefficient matrix;

[0169] Calculate the corresponding global covariance matrix based on the coefficient matrix of the decomposition level;

[0170] Eigenvalue decomposition is performed on the global covariance matrix of the decomposition level to generate a whitening matrix;

[0171] For each sample and decomposition level, the coefficient matrix is ​​calibrated using a whitening matrix, and the corresponding decomposition coefficients in the calibrated coefficient matrix are updated.

[0172] The calibrated decomposition coefficients are subjected to inverse discrete wavelet transform to reconstruct the signal, resulting in a time-frequency aligned multichannel EEG signal.

[0173] The prediction module inputs the time-frequency aligned multi-channel EEG signals into a trained motor imagery category prediction model to obtain the category of motor imagery.

[0174] On the other hand, the present invention provides a computer device including a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the steps of the time-frequency aligned electroencephalogram (EEG) signal analysis method provided in any of the above embodiments. The computer device may be a server. The computer device includes a processor, a memory, a network interface, and a database connected via a system bus. The processor of the computer device provides computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and computer program in the non-volatile storage medium. The database of the computer device stores sample data. The network interface of the computer device is used for communication with external terminals via a network connection.

[0175] On the other hand, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the time-frequency aligned EEG signal analysis method provided in any of the above embodiments.

[0176] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0177] Matters not covered in this invention are common knowledge.

[0178] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0179] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of the invention. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these modifications and improvements all fall within the protection scope of this application.

[0180] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

Claims

1. A method for electroencephalogram signal analysis with time-frequency alignment, characterized in that, The method comprises the following steps: inputting a raw multi-channel electroencephalogram signal related to motor imagery to be analyzed; performing time-frequency alignment processing on the raw multi-channel electroencephalogram signal to obtain a multi-channel electroencephalogram signal after time-frequency alignment, wherein the time-frequency alignment processing comprises the following steps: Based on the selected wavelet basis and the decomposition level, a discrete wavelet transform is performed on each sample and each channel of the original multi-channel electroencephalogram signal to obtain decomposition coefficients, wherein the input space of the multi-channel electroencephalogram signal is defined as wherein is the number of samples, is the number of electroencephalogram channels, is the number of time series sampling points; extracting decomposition coefficients of all channels for each decomposition level and constructing a coefficient matrix; calculating a corresponding global covariance matrix based on the coefficient matrix of the decomposition level; performing eigenvalue decomposition on the global covariance matrix of the decomposition level to generate a whitening matrix; for each sample and decomposition level, using the whitening matrix to calibrate the coefficient matrix and updating the corresponding decomposition coefficients in the calibrated coefficient matrix; performing inverse discrete wavelet transform on the calibrated decomposition coefficients to reconstruct a signal and obtain a multi-channel electroencephalogram signal after time-frequency alignment; inputting the multi-channel electroencephalogram signal after time-frequency alignment into a trained motor imagery category prediction model to obtain the category of motor imagery.

2. The time-frequency aligned electroencephalogram signal analysis method according to claim 1, characterized in that, The method comprises the following steps: For the first decomposition level, its global covariance matrix is as follows: wherein is a regularization parameter for ensuring the matrix is invertible, is an identity matrix, , is the number of decomposition levels, the coefficient matrix of the th decomposition level , is the length of the decomposition coefficient of the th decomposition level.

3. The time-frequency aligned electroencephalogram signal analysis method according to claim 2, characterized in that, performing eigenvalue decomposition on the global covariance matrix of the decomposition level to generate a whitening matrix, comprising: right Perform eigenvalue decomposition: wherein is a matrix of eigenvectors, is a vector of eigenvalues, generating a whitening matrix : To ensure the stability of the values, the whitening matrix with eigenvalues smaller than zero or infinity is set to zero, resulting in the final whitening matrix.

4. The time-frequency aligned electroencephalography signal analysis method according to claim 1 or 2 or 3, characterized in that, The training method of the motor imagery category prediction model comprises the following steps: inputting raw multi-channel electroencephalogram signals for training, wherein part of the multi-channel electroencephalogram signals are from a source domain, and the multi-channel electroencephalogram signals from the source domain are known to have corresponding motor imagery category labels; the remaining multi-channel electroencephalogram signals are from a target domain, and the motor imagery category labels of the multi-channel electroencephalogram signals from the target domain are unknown; performing time-frequency alignment processing on the multi-channel electroencephalogram signals from the source domain and the target domain respectively to obtain corresponding multi-channel electroencephalogram signals after time-frequency alignment; constructing a motor imagery category prediction model, wherein the motor imagery category prediction model comprises a feature extractor, an attention-enhanced domain adversarial neural network; the feature extractor is used to extract electroencephalogram signal features of the multi-channel electroencephalogram signals after time-frequency alignment; the attention-enhanced domain adversarial neural network comprises a task label classifier, a domain discriminator and a dynamic domain attention module; the dynamic domain attention module generates attention weights according to the electroencephalogram signal features, calculates an attention matrix based on a self-attention mechanism, and uses the attention matrix to weight the electroencephalogram signal features to obtain attention features that are stable and rich in domain-invariant information; the task label classifier is used to receive the attention features and output a probability distribution of belonging to each motor imagery category label; the domain discriminator is used to receive the attention features and output a domain label probability of belonging to the target domain or the source domain. The time-frequency aligned multi-channel electroencephalogram signals from the source domain and the target domain are input into the motor imagery category prediction model, wherein the time-frequency aligned multi-channel electroencephalogram signals from the source domain are used to train the task label classifier, the probability distribution of each motor imagery category label output by the task label classifier is calculated, and the task classification loss is calculated accordingly; the time-frequency aligned multi-channel electroencephalogram signals from the source domain and the target domain are used to train the domain discriminator, the domain label probability of the target domain and the source domain output by the domain discriminator is calculated, and the domain discrimination loss is calculated accordingly; the model parameters of the feature extractor, the task label classifier, the domain discriminator and the dynamic domain attention module are updated to minimize the task classification loss and maximize the domain discrimination loss, and the trained motor imagery category prediction model is obtained through continuous iteration until convergence.

5. The time-frequency aligned electroencephalogram signal analysis method according to claim 4, characterized in that, In the feature extractor: The time-frequency aligned multi-channel electroencephalogram signals are sequentially subjected to time convolution, spatial convolution and separable convolution to extract preliminary spatio-temporal features; The preliminary spatio-temporal features are input into the bidirectional attention time sequence network, sequentially subjected to the attention mechanism and the bidirectional time sequence convolution network in the bidirectional attention time sequence network, weighted and enhanced for the feature channels, and the time dependence is captured from the forward and reverse directions respectively; The forward features and the reverse features output by the bidirectional time sequence convolution network are weighted and fused to generate electroencephalogram signal features with time sequence context information.

6. The time-frequency aligned electroencephalography signal analysis method of claim 4, wherein, In the dynamic domain attention module, the processing process includes: Using a two-layer fully connected network to generate attention weights : wherein and are weights of the two-layer fully connected network, is the input electroencephalogram signal feature with temporal context information; Based on the self-attention mechanism, an attention matrix is calculated is: wherein , denotes matrix multiplication, denotes a scaling factor, is a normalized exponential function, The features are weighted using the attention matrix: Residual connections and layer normalization are introduced, where layer normalization normalizes the feature vectors along the channel dimension to generate attention features that are stable and rich in domain-invariant information : wherein represents a layer normalization.

7. The time-frequency aligned electroencephalography signal analysis method of claim 4, wherein, The total loss function is constructed to minimize the task classification loss and maximize the domain discrimination loss, as follows: wherein are model parameters of the feature extractor, model parameters of the task label classifier, model parameters of the domain discriminator, respectively; , are the task classification loss and the domain discrimination loss corresponding to the first i , wherein the first to the th are multi-channel electroencephalogram signals from the source domain, the th to the th multi-channel electroencephalogram signals are multi-channel electroencephalogram signals from the target domain, is a dynamic weight.​ 8. Apparatus for analysis of electroencephalographic signals aligned in time and frequency, characterized by It comprises: An input module for inputting original multi-channel electroencephalogram signals related to motor imagery to be analyzed; A time-frequency processing module for time-frequency alignment processing of the original multi-channel electroencephalogram signals to obtain time-frequency aligned multi-channel electroencephalogram signals, wherein the time-frequency alignment processing includes the following steps: Based on the selected wavelet basis and the decomposition level, a discrete wavelet transform is performed on each sample and each channel of the original multi-channel electroencephalogram signal to obtain decomposition coefficients, wherein the input space of the multi-channel electroencephalogram signal is defined as wherein is the number of samples, is the number of electroencephalogram channels, is the number of time series sampling points; For each decomposition level, extract the decomposition coefficients of all channels and construct a coefficient matrix; Calculate the corresponding global covariance matrix based on the coefficient matrix of the decomposition level; Perform eigenvalue decomposition on the global covariance matrix of the decomposition level to generate a whitening matrix; For each sample and decomposition level, use the whitening matrix to calibrate the coefficient matrix and update the corresponding decomposition coefficients in the calibrated coefficient matrix; Perform inverse discrete wavelet transform on the calibrated decomposition coefficients to reconstruct the signal and obtain the time-frequency aligned multi-channel electroencephalogram signals; A prediction module for inputting the time-frequency aligned multi-channel electroencephalogram signals into the trained motor imagery category prediction model to obtain the category of motor imagery.

9. Computer equipment comprising a memory and a processor, the memory storing a computer program, characterized in that, The processor executes the computer program to implement the steps of the time-frequency aligned electroencephalogram signal analysis method of claim 1.

10. A computer readable storage medium having stored thereon a computer program, characterized in that, The computer program is executed by the processor to implement the steps of the time-frequency aligned electroencephalogram signal analysis method of claim 1.

Citation Information

Patent Citations

  • Motor imagery electroencephalogram decoding method based on spatial domain feature time-frequency transformation

    CN114533086A

  • Cross-subject electroencephalogram signal alignment method based on time-frequency analysis and related equipment

    CN118044826A