Cosine convolution multichannel group decoding method and system for electroencephalogram classification
Through the cosine convolution multi-channel group decoding method, the time-frequency characteristics of the electroencephalogram signal are extracted and the multi-channel group structure is used, which solves the problems of large amount of calculation and insufficient information fusion in the traditional method, and realizes high-performance electroencephalogram signal classification .
Patent Information
- Application Number
- CN202411731004.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-29
- Publication Date
- 2024-12-27
- Estimated Expiration
- 2044-11-29
AI Technical Summary
In the classification of motor imagination EEG signals, traditional convolutional calculations are large and difficult to capture nonlinear features, and spatial relationships are not fully utilized during multi-channel EEG data processing, resulting in insufficient information fusion and affecting classification performance.
The cosine convolution multi-channel group decoding method is adopted to extract time-frequency features through cosine convolution, and the multi-channel group structure is used to convolve in the channel dimension, making full use of spatial correlation, and splicing time-frequency-space features to improve classification performance.
Effectively extract the time and frequency domain dynamic characteristics of EEG signals, reduce calculation costs, improve classification accuracy and model generalization capabilities, and is suitable for real-time applications and embedded devices.
Smart Images

Figure CN119202807A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of artificial intelligence technology, and in particular to a cosine convolution multi-channel group decoding method and system for electroencephalogram classification. Background Art
[0002] The statements in this section merely provide background information related to the present disclosure and do not necessarily constitute prior art.
[0003] Brain-Computer Interface (BCI) technology is an important way to directly connect the brain and external devices. It converts human thinking activities into signals for controlling external devices or communicating with the outside world by analyzing the collected brain signals, thereby realizing human-computer interaction. Compared with other brain signals, EEG signals are widely used in the field of brain-computer interfaces due to their advantages such as non-invasiveness, portability, high time resolution, low cost, and suitability for real-time applications.
[0004] Motor Imagery (MI) electroencephalograph (EEG), as a common spontaneous EEG signal, refers to the brain information obtained by people by imagining their own limb movements without actual movement. It focuses on subjective initiative, may repair or rebuild damaged motor conduction pathways, and awaken some dormant neuronal synapses, and has great practical value in the field of active movement rehabilitation.
[0005] At present, deep learning methods are widely used in motor imagery brain-computer interfaces, but the traditional ordinary convolution has a large amount of calculation, and the standard linear kernel function used has certain limitations in capturing the nonlinear characteristics of brain signals, and it is difficult to fully capture the dynamic change characteristics of periodic EEG signals. In addition, when processing multi-channel EEG data, existing methods often do not fully utilize the spatial relationship between different EEG channels, resulting in insufficient information fusion between EEG channels and information loss. Summary of the invention
[0006] In order to solve the above problems, the present invention proposes a cosine convolution multi-channel group decoding method and system for EEG classification, in which the first convolution layer is set to cosine convolution to better extract the time-frequency features of EEG signals, and multiple branches are used at the position of the second convolution layer to extract the spatial features of signals of different channel groups. Finally, the extracted time-frequency and spatial features of different channel groups are spliced, ultimately achieving high-performance motor imagery EEG signal classification.
[0007] According to some embodiments, the present disclosure adopts the following technical solutions: The cosine convolution multi-channel group decoding method for EEG classification includes: Obtaining different categories of motor imagery EEG signals to be classified and preprocessing them; The preprocessed motor imagery EEG signals are input into an EEG signal classification model, and the classification results of motor imagery EEG signals of different categories are output; Among them, after the motor imagery EEG signal is input into the EEG signal classification model, it first enters the cosine convolution time-frequency feature extraction module, and decomposes and reconstructs different frequency components by using cosine convolution kernels of different frequencies to obtain multi-scale time-frequency features; the multi-scale time-frequency features are then input into the multi-channel group spatial feature extraction module, and the multi-scale time-frequency features are grouped into channels according to the number of channel groups. Each channel subgroup data is convolved in the channel dimension using an independent separable convolution branch network to obtain the time-frequency and space-time features of the EEG signal of each channel subgroup, and the time-frequency and space-time features of the EEG signal of each channel subgroup are spliced into a fused feature vector, and the probability of the motor imagery EEG signal corresponding to each category of motor imagery is output through the fully connected layer.
[0008] According to some embodiments, the present disclosure adopts the following technical solutions: Cosine convolution multi-channel group decoding system for EEG classification, including: A data acquisition module is used to acquire and pre-process the motor imagery EEG signals of different categories to be classified; A classification module is used to input the preprocessed motor imagery EEG signal into the EEG signal classification model and output classification results of motor imagery EEG signals of different categories; Among them, after the motor imagery EEG signal is input into the EEG signal classification model, it first enters the cosine convolution time-frequency feature extraction module, and decomposes and reconstructs different frequency components by using cosine convolution kernels of different frequencies to obtain multi-scale time-frequency features; the multi-scale time-frequency features are then input into the multi-channel group spatial feature extraction module, and the multi-scale time-frequency features are grouped into channels according to the number of channel groups. Each channel subgroup data is convolved in the channel dimension using an independent separable convolution branch network to obtain the time-frequency and space-time features of the EEG signal of each channel subgroup, and the time-frequency and space-time features of the EEG signal of each channel subgroup are spliced and fused into a feature vector, and the probability of the motor imagery EEG signal corresponding to each category of motor imagery is output through the fully connected layer.
[0009] According to some embodiments, the present disclosure adopts the following technical solutions: A computer program product comprises a computer program, wherein when the computer program is executed by a processor, the cosine convolution multi-channel group decoding method for EEG classification is implemented.
[0010] According to some embodiments, the present disclosure adopts the following technical solutions: A non-transitory computer-readable storage medium is used to store computer instructions. When the computer instructions are executed by a processor, the cosine convolution multi-channel group decoding method for electroencephalogram classification is implemented.
[0011] According to some embodiments, the present disclosure adopts the following technical solutions: An electronic device comprises: a processor, a memory and a computer program; wherein the processor is connected to the memory, the computer program is stored in the memory, and when the electronic device is running, the processor executes the computer program stored in the memory so that the electronic device executes the cosine convolution multi-channel group decoding method for electroencephalogram classification.
[0012] Compared with the prior art, the present invention has the following beneficial effects: The cosine convolution multi-channel group decoding method for EEG classification disclosed in the present invention decomposes and reconstructs different frequency components by using cosine convolution kernels of different frequencies in the cosine convolution time-frequency feature extraction module to obtain multi-scale time-frequency features. It replaces the traditional convolution kernel with the cosine convolution kernel, can better capture the periodic characteristics of EEG signals, effectively extract the dynamic characteristics of the time domain and frequency domain of the EEG signals, and improve the decoding accuracy; and the cosine convolution significantly reduces the amount of calculation compared with the traditional convolution, reduces the calculation cost while maintaining high performance, making it suitable for real-time applications and embedded device implementations.
[0013] The disclosed cosine convolution multi-channel group decoding method for EEG classification inputs the multi-scale time-frequency features into the multi-channel group spatial feature extraction module, groups the multi-scale time-frequency features into channels according to the number of channel groups, and uses an independent separable convolution branch network to convolve each channel subgroup data in the channel dimension to obtain the time-frequency-space features of the EEG signal of each channel subgroup. The branch structure of the multi-channel group is used to make full use of the spatial correlation between the channels, which overcomes the problem of insufficient spatial information fusion in multi-channel signal processing in the existing methods and improves the generalization ability and robustness of the model. This method can effectively extract frequency domain and cross-channel features in EEG signals, improve classification performance and reduce computational costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] The accompanying drawings constituting a part of the present disclosure are used to provide a further understanding of the present disclosure. The illustrative embodiments of the present disclosure and their descriptions are used to explain the present disclosure and do not constitute an improper limitation on the present disclosure.
[0015] Figure 1 is a structural block diagram of a cosine convolution multi-channel group according to an embodiment of the present disclosure; Figure 2 This is a structural framework diagram of a classification model based on a cosine convolution multi-channel group according to an embodiment of the present disclosure; Figure 3 The present invention is a flowchart of a cosine convolution multi-channel group decoding method for motor imagery EEG classification according to an embodiment of the present invention. DETAILED DESCRIPTION
[0016] The present disclosure is further described below in conjunction with the accompanying drawings and embodiments.
[0017] It should be noted that the following detailed descriptions are all illustrative and are intended to provide further explanation of the present disclosure. Unless otherwise specified, all technical and scientific terms used herein have the same meanings as those commonly understood by those skilled in the art to which the present disclosure belongs.
[0018] It should be noted that the terms used herein are only for describing specific embodiments and are not intended to limit the exemplary embodiments according to the present disclosure. As used herein, unless the context clearly indicates otherwise, the singular form is also intended to include the plural form. In addition, it should be understood that when the terms "comprising" and / or "including" are used in this specification, it indicates the presence of features, steps, operations, devices, components and / or combinations thereof.
[0019] Example 1 In one embodiment of the present disclosure, a cosine convolution multi-channel group decoding method for EEG classification is provided, comprising the following steps: Step 1: Obtain different categories of motor imagery EEG signals to be classified and pre-process them; Step 2: Input the preprocessed motor imagery EEG signal into the EEG signal classification model, and output the classification results of different categories of motor imagery EEG signals; Among them, after the motor imagery EEG signal is input into the EEG signal classification model, it first enters the cosine convolution time-frequency feature extraction module, and decomposes and reconstructs different frequency components by using cosine convolution kernels of different frequencies to obtain multi-scale time-frequency features; the multi-scale time-frequency features are then input into the multi-channel group spatial feature extraction module, and the multi-scale time-frequency features are grouped into channels according to the number of channel groups. Each channel subgroup data is convolved in the channel dimension using an independent separable convolution branch network to obtain the time-frequency and space-time features of the EEG signal of each channel subgroup, and the time-frequency and space-time features of the EEG signal of each channel subgroup are spliced into a fused feature vector, and the probability of the motor imagery EEG signal corresponding to each category of motor imagery is output through the fully connected layer.
[0020] As an embodiment, the specific implementation process of the cosine convolution multi-channel group decoding method for EEG classification disclosed in the present invention is as follows: Step 1: Obtain different categories of motor imagery EEG signals to be classified and preprocess them; Specifically, in order to verify the effectiveness of the present disclosure, this embodiment uses an existing public EEG dataset, the 2008 Fourth International Brain-Computer Interface Competition Left and Right Hand Movement Imagination EEG Signal Dataset BCI Competition IVdataset IIa, as a reference dataset to compare the classification results. This dataset collects the EEG signals generated when the experimenter imagines the four movements of the left hand, right hand, toes and tongue. categories of EEG signals, sampling frequency Fs = 250Hz, each sample is selected from 4s of EEG data from EEG channels, that is, the length of the EEG signal of each sample is , each category collects times, a total of 288 samples are taken as training set and 288 samples are taken as test set.
[0021] Step 2: Build an EEG signal classification model and train it; Specifically, the EEG signal classification model includes a cosine convolution time-frequency feature extraction module, a multi-channel group spatial feature extraction module, a feature fusion module and a fully connected layer.
[0022] Among them, the cosine convolution time-frequency feature extraction module includes a convolution layer with a cosine convolution kernel and a batch normalization layer. The cosine convolution time-frequency feature extraction module uses multiple cosine convolution kernels of different frequencies to replace the traditional convolution kernel to filter the EEG signal, thereby extracting the multi-scale time-frequency features of the EEG signal. The input of the cosine convolution time-frequency feature extraction module is the collected EEG signal , the input parameter required for cosine convolution is the number of cosine convolution kernels And the length of the cosine convolution kernel , the calculation formula of the cosine convolution kernel is as follows:
[0023] in, is a zero-centered, length A symmetric array, that is, {-4,-3,-2,-1,0,1,2,3,4}, Indicates j The amplitude of a trainable cosine convolution kernel is initialized as a random quantity that obeys a Gaussian distribution with a mean of 0 and a standard deviation of 1. By updating and iterating it during the training process, the signal components of different frequency bands can be amplified or suppressed, thereby better adapting to the periodic characteristics of EEG signals. Represents the frequency parameter, through which the division of different frequency bands is realized. Initialization is as follows:
[0024] in Represents the starting frequency of the set EEG data, Represents the cutoff frequency of the EEG data. Indicates the number of cosine convolution filter kernels.
[0025] Among them, the cosine convolution is given by and To determine the cutoff frequency band and frequency parameters of the decoded EEG signal It is fixed after initialization and is not updated with training. The fixed value can determine the extraction frequency band of the corresponding convolution kernel. In this embodiment, the extraction frequency bands of the corresponding convolution kernel are [0 Hz, 5 Hz], [5 Hz, 10 Hz], [10 Hz, 15 Hz], [15 Hz, 20 Hz], [20 Hz, 25 Hz], [25 Hz, 30 Hz], [30 Hz, 35 Hz], and [35 Hz, 40 Hz].
[0026] Put the cosine convolution kernel into the two-dimensional convolution to obtain the multi-scale time-frequency features of the cosine convolution output :
[0027] in, represents the cosine convolution kernel, * represents the convolution operation, Represents the input data, Indicates j The amplitude of the trainable cosine convolution kernel, Represents the frequency parameter.
[0028] Cosine convolution uses different frequency parameters to filter EEG signals of different frequency bands and obtain multi-scale time-frequency features. This feature can better capture the frequency information contained in the signal and improve the classification effect. Then the output of cosine convolution is batch normalized to obtain data , making the data distribution more stable, reducing the risk of gradient vanishing and gradient explosion, and enhancing the robustness of the model.
[0029] Batch normalization is a regularization technique that aims to accelerate the training process of neural networks and improve the stability of the model. It normalizes the input features of each small batch of data to a distribution with a mean of 0 and a standard deviation of 1, and introduces learnable parameters to scale and translate them to preserve the expressive power of the model. The improvement of the present disclosure is that the cosine convolution is improved by the frequency parameter The extraction of time-frequency features of different frequency bands of the same signal is realized. It is a fixed parameter set according to a certain rule and cannot be trained.
[0030] Furthermore, a multi-channel group spatial feature extraction module is constructed. The multi-channel group spatial feature extraction module includes a channel grouping operation, and each group includes a depth-wise separable convolutional layer.
[0031] The input of the multi-channel group spatial feature extraction module is the multi-scale time-frequency features of the EEG signal output by the cosine convolution time-frequency feature extraction module. , the multi-channel group spatial feature extraction module is to group and divide the input multi-channel EEG signals according to certain channel correlations, and the number and channel positions of the EEG signals contained in each group are different. The input multi-scale time-frequency features are divided into 10 channel subgroups according to the total number of channels, according to the specific step size and the starting position, and the signals in each channel subgroup have strong spatial correlation. The EEG signal of each subgroup also corresponds to a branch of the network. There is a deep separable convolution in each branch to extract the spatial characteristics of the EEG signal of the subgroup; channel grouping is for EEG channels, and the grouping is obtained by sampling the EEG channels at intervals according to a certain rule, which can enhance the model's ability to extract spatial features of EEG signals; the present disclosure sorts all channels of EEG signals from 0, and the channel grouping is generated using the following rules: 1. The first four channel groups use 0 as the starting position, and generate channel indexes with step sizes of 1, 2, 3, and 4 respectively. The four channel groups are selected cyclically according to the channel positions, and the channel indexes in each group are separated by 1, 2, 3, and 4 positions respectively.
[0032] When the step size is 1, the channel group starting at 0 contains The index of When the step size is 2, the channel group starting at 0 contains The index of When the step size is 3, the channel group starting at 0 contains The index of When the step size is 4, the channel group starting at 0 contains The index of .
[0033] 2. The last three channel groups use 1 as the starting position and generate channel indexes with step sizes of 2, 3, and 4 respectively. The three channel groups are selected cyclically according to the channel positions, and the channel indexes in each group are separated by 2, 3, and 4 positions respectively.
[0034] When the step size is 2, the channel group starting at 1 contains The index of When the step size is 3, the channel group starting at 1 contains The index of When the step size is 4, the channel group starting at 1 contains The index of .
[0035] 3. The last two channel groups use 2 as the starting position and generate channel indexes with step sizes of 3 and 4 respectively. The two channel groups are selected cyclically according to the channel positions, and the channel indexes in each group are separated by 3 and 4 positions respectively.
[0036] When the step size is 3, the channel group starting at 2 contains The index of When the step size is 4, the channel group starting at 2 contains The index of .
[0037] 4. The last channel group takes 3 as the starting position and generates channel index with a step size of 4. The channel group is selected in a cyclic jump according to the channel position, and the channel index in each group is separated by 4 positions.
[0038] When the step size is 4, the channel group starting at 2 contains The index of .
[0039] For each channel subgroup data after channel grouping ( In this branch, an independent depth-separable convolutional branch network is used to perform convolution in the channel dimension to extract the spatial features of the EEG signal in this subgroup. Represents the number of convolution kernels in each branch of the multi-channel group spatial feature extraction module.
[0040] Among them, the depth-wise separable convolution further optimizes the convolution process by first performing a separate convolution operation (depth-wise convolution) on each input channel, and then performing point-by-point convolution to mix channel information.
[0041] Furthermore, a feature fusion and classification module is constructed, wherein the input data of the feature fusion and classification module is the time-frequency-space features of multiple groups of EEG signals output by the multi-channel group spatial feature extraction module. , the input features are concatenated as follows in the dimension of the original EEG channel to obtain data :
[0042] in, represents the output of a channel group of the multi-channel group spatial feature extraction module, T represents the length of the EEG signal, Represents the number of convolution kernels in each branch of the multi-channel group spatial feature extraction module.
[0043] The ELU activation function is applied to the fused feature map to introduce nonlinear characteristics. After further convolution, batch normalization and average pooling operations, the size of the output feature map is gradually reduced. Finally, the feature map is converted into a one-dimensional feature vector through a flattening layer, and then connected to the fully connected layer. The activation function Softmax is used to output the probability of each category of motor imagery corresponding to the EEG data.
[0044] Among them, average pooling is used for dimensionality reduction operations and feature extraction in deep learning models. It reduces the spatial dimensions (height and width) of the input feature map by calculating the average value of elements in the local receptive field, thereby reducing the amount of calculation and parameters while retaining the global information of the input features.
[0045] ELU is a nonlinear activation function used in hidden layers to solve the gradient vanishing problem and improve the model's ability to express negative features. Softmax is an activation function used in the output layer of multi-classification tasks. It converts the output value into a probability distribution to help the model determine the classification result.
[0046] Furthermore, the output classification result is converted into a corresponding control command to control the external device.
[0047] In order to illustrate the effectiveness of the present disclosure in decoding motor imagery EEG signals, the classification accuracy is used as an evaluation indicator for the obtained category labels:
[0048] Where TP is the number of true positives, TN is the number of true negatives, FP is the number of false positives, and FN is the number of false negatives.
[0049] By comparing the present invention with the EEGNet, a lightweight network dedicated to EEG decoding, and the ablation results of each module, it was found that under the same experimental conditions, the present invention had higher accuracy and average accuracy in motor imagery EEG classification of multiple subjects than the results in other groups, indicating that the cosine convolution module and the multi-channel group module have a synergistic and complementary effect. The combination of the two enhances the model's ability to extract frequency domain features and spatial features, verifies the effectiveness of the present invention in decoding EEG signals, and also lays a certain foundation for obtaining category labels by decoding EEG signals and then converting them into control commands to accurately control external devices.
[0050] Table 1 Comparison of results within the group of this disclosure
[0051] The results in Table 1 show that the decoding method based on cosine convolution multi-channel group improves the accuracy by about 3% compared with the traditional EEGNet, which shows the effectiveness of the present invention in improving the performance of the model, and shows that the combination of cosine convolution and multi-channel group enhances the ability of the traditional model to extract the time-frequency-space features of EEG signals. The present disclosure overcomes the problem of insufficient spatial information fusion in the existing methods when processing multi-channel signals, improves the generalization ability and robustness of the model; can effectively extract frequency domain and cross-channel features in EEG signals, improve classification performance, and reduce computational costs.
[0052] Example 2 In one embodiment of the present disclosure, a cosine convolution multi-channel group decoding system for EEG classification is provided, comprising: A data acquisition module is used to acquire and pre-process the motor imagery EEG signals of different categories to be classified; A classification module is used to input the preprocessed motor imagery EEG signal into the EEG signal classification model and output classification results of motor imagery EEG signals of different categories; Among them, after the motor imagery EEG signal is input into the EEG signal classification model, it first enters the cosine convolution time-frequency feature extraction module, and decomposes and reconstructs different frequency components by using cosine convolution kernels of different frequencies to obtain multi-scale time-frequency features; the multi-scale time-frequency features are then input into the multi-channel group spatial feature extraction module, and the multi-scale time-frequency features are grouped into channels according to the number of channel groups. Each channel subgroup data is convolved in the channel dimension using an independent separable convolution branch network to obtain the time-frequency and space-time features of the EEG signal of each channel subgroup, and the time-frequency and space-time features of the EEG signal of each channel subgroup are spliced into a fused feature vector, and the probability of the motor imagery EEG signal corresponding to each category of motor imagery is output through the fully connected layer.
[0053] As an embodiment, the data acquisition module includes a data acquisition device and an A / D converter. The various modules of the classification model are embedded in a cosine convolution time domain filtering operation unit, a convolution spatial domain filtering operation unit, and a fully connected layer operation unit in a high-performance computer to perform signal processing and classification, obtain classification labels of samples, and convert them into control instructions for external devices.
[0054] Example 3 In one embodiment of the present disclosure, a computer program product is provided, including a computer program. When the computer program is executed by a processor, the cosine convolution multi-channel group decoding method for EEG classification is implemented.
[0055] Example 4 In one embodiment of the present disclosure, a non-transitory computer-readable storage medium is provided, wherein the non-transitory computer-readable storage medium is used to store computer instructions. When the computer instructions are executed by a processor, the cosine convolution multi-channel group decoding method for EEG classification is implemented.
[0056] Example 5 In one embodiment of the present disclosure, an electronic device is provided, including: a processor, a memory, and a computer program; wherein the processor is connected to the memory, the computer program is stored in the memory, and when the electronic device is running, the processor executes the computer program stored in the memory, so that the electronic device executes the cosine convolution multi-channel group decoding method for EEG classification.
[0057] The present disclosure is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present disclosure. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of the processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0058] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0059] Although the above describes the specific implementation methods of the present disclosure in conjunction with the accompanying drawings, it is not intended to limit the scope of protection of the present disclosure. Technical personnel in the relevant field should understand that on the basis of the technical solution of the present disclosure, various modifications or variations that can be made by those skilled in the art without creative work are still within the scope of protection of the present disclosure.
Claims
1. A cosine convolution multi-channel group decoding method for EEG classification, characterized in that: include: Obtaining different categories of motor imagery EEG signals to be classified and preprocessing them; The preprocessed motor imagery EEG signals are input into an EEG signal classification model, and the classification results of motor imagery EEG signals of different categories are output; Among them, after the motor imagery EEG signal is input into the EEG signal classification model, it first enters the cosine convolution time-frequency feature extraction module, and decomposes and reconstructs different frequency components by using cosine convolution kernels of different frequencies to obtain multi-scale time-frequency features; the multi-scale time-frequency features are then input into the multi-channel group spatial feature extraction module, and the multi-scale time-frequency features are grouped into channels according to the number of channel groups. Each channel subgroup data is convolved in the channel dimension using an independent separable convolution branch network to obtain the time-frequency and space-time features of the EEG signal of each channel subgroup, and the time-frequency and space-time features of the EEG signal of each channel subgroup are spliced into a fused feature vector, and the probability of the motor imagery EEG signal corresponding to each category of motor imagery is output through the fully connected layer.
2. The cosine convolution multi-channel group decoding method for EEG classification according to claim 1, characterized in that: Obtain different categories of motor imagery EEG signals to be classified, and preprocess them including: using an EEG amplifier and an A / D converter to collect motor imagery EEG signals, the collected motor imagery EEG signals include There are different categories, the sampling frequency is set, each category is collected M times, and the total number of motor imagery EEG signals collected is , the collected motor imagery EEG signals are subjected to denoising filtering and segmented preprocessing.
3. The cosine convolution multi-channel group decoding method for EEG classification according to claim 1, characterized in that: The EEG signal classification model includes a cosine convolution time-frequency feature extraction module, a multi-channel group spatial feature extraction module, a feature fusion module, and a fully connected layer. The cosine convolution time-frequency feature extraction module uses a cosine convolution kernel instead of a traditional convolution kernel. The input parameters required for cosine convolution are the number of cosine convolution kernels and the length of the cosine convolution kernel. The calculation formula of the cosine convolution kernel is as follows: in, is a zero-centered, length A symmetric array of Represents the amplitude of the jth trainable cosine convolution kernel; represents the frequency parameter, Indicates the number of cosine convolution filter kernels.
4. The cosine convolution multi-channel group decoding method for EEG classification according to claim 1, characterized in that: By using cosine convolution kernels of different frequencies to decompose and reconstruct different frequency components, multi-scale frequency domain features are obtained. The cosine convolution kernel is placed in a two-dimensional convolution, and the cosine convolution output is obtained as follows: in, represents the cosine convolution kernel, * represents the convolution operation, Represents the input data, Indicates j The amplitude of the trainable cosine convolution kernel, Represents the frequency parameter.
5. The cosine convolution multi-channel group decoding method for EEG classification according to claim 1, characterized in that: The input of the multi-channel group spatial feature extraction module is the multi-scale time-frequency features of the motor imagery EEG signal. The input multi-scale time-frequency features are divided into multiple channel subgroups according to the set step size and starting position according to the grouping rules, so that the signals in each channel subgroup have strong spatial correlation, and the sorting of all channels of the EEG signal starts from 0.
6. The cosine convolution multi-channel group decoding method for EEG classification according to claim 1, characterized in that: The output multiple groups of time-frequency-space features are concatenated with the input features in the original channel dimension to obtain a fused feature map. The fused feature map is further convolved and pooled, and the size of the output feature map is gradually reduced. Finally, the feature map is converted into a one-dimensional fused feature vector through a flattening layer, and then connected to the fully connected layer. The activation function is used to output the probability of each category of motor imagination corresponding to the EEG data.
7. A cosine convolution multi-channel group decoding system for EEG classification, characterized in that: include: A data acquisition module is used to acquire and pre-process the motor imagery EEG signals of different categories to be classified; A classification module is used to input the preprocessed motor imagery EEG signal into the EEG signal classification model and output classification results of motor imagery EEG signals of different categories; Among them, after the motor imagery EEG signal is input into the EEG signal classification model, it first enters the cosine convolution time-frequency feature extraction module, and decomposes and reconstructs different frequency components by using cosine convolution kernels of different frequencies to obtain multi-scale time-frequency features; the multi-scale time-frequency features are then input into the multi-channel group spatial feature extraction module, and the multi-scale time-frequency features are grouped into channels according to the number of channel groups. Each channel subgroup data is convolved in the channel dimension using an independent separable convolution branch network to obtain the time-frequency and space-time features of the EEG signal of each channel subgroup, and the time-frequency and space-time features of the EEG signal of each channel subgroup are spliced into a fused feature vector, and the probability of the motor imagery EEG signal corresponding to each category of motor imagery is output through the fully connected layer.
8. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the cosine convolution multi-channel group decoding method for EEG classification according to any one of claims 1 to 6 is implemented.
9. A non-transitory computer-readable storage medium, characterized in that: The non-transitory computer-readable storage medium is used to store computer instructions. When the computer instructions are executed by the processor, the cosine convolution multi-channel group decoding method for EEG classification as described in any one of claims 1 to 6 is implemented.
10. An electronic device, characterized in that: include: A processor, a memory and a computer program; wherein the processor is connected to the memory, the computer program is stored in the memory, and when the electronic device is running, the processor executes the computer program stored in the memory so that the electronic device executes the cosine convolution multi-channel group decoding method for EEG classification as described in any one of claims 1-6.
Citation Information
Patent Citations
Motor imagery recognition method and system based on multi-scale convolution and Transform
CN117113269A
Motor imagery electroencephalogram signal classification method based on multi-scale convolution and self-attention
CN118349906A
Electroencephalogram anomaly detection and positioning method and system based on packet cosine convolutional network
CN118873153A
Classification of brain activity signals
WO2023148471A1
Capsule network-based motor imagery electroencephalography signal recognition method
WO2024051455A1
Cited By
Multi-level electroencephalogram signal analysis method, device and equipment based on space-time coding
CN119720110A
Decoding model construction method and decoding method for motor imagery brain-computer interface signals
CN120045995A
Multi-channel electroencephalogram signal feature extraction and classification method and device for brain-computer intelligent earphone
CN120067824A
Method and equipment for extracting and classifying multi-channel EEG signals from brain-computer intelligent headsets
CN120067824B
