A method and system for learning EEG signal representation based on brain region characteristics

By dividing the EEG signal electrodes into multiple regions and using a single-channel encoder for encoding and fusion feature extraction, the problems of data set availability and spatiotemporal redundancy in EEG signal processing are solved, and the accuracy of EEG signal classification is improved. and feature robustness and generalization.

CN118467934BActive Publication Date: 2024-09-27NAT UNIV OF DEFENSE TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410931449.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-12
Publication Date
2024-09-27
Estimated Expiration
2044-07-12

AI Technical Summary

Technical Problem

Existing EEG signal processing technology faces problems such as limited availability of data sets, inconsistent experimental protocols, and spatiotemporal redundancy, which limits the development and application of emotion recognition technology.

Method used

Using an EEG signal representation learning method based on brain region characteristics, by dividing the EEG signal electrodes into multiple areas, using a single-channel encoder to encode and perform fusion feature extraction, combined with convolutional neural networks and recurrent neural networks, using attention The mechanism handles the differences between channels, reduces spatial redundancy, and improves the robustness and generalization of features.

Benefits of technology

It improves the accuracy of EEG signal classification prediction and the robust generalization of features, and can extract universal features in joint training of multiple data sets, breaking the limitations of data set paradigms.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118467934B
    Figure CN118467934B
Patent Text Reader

Abstract

The present invention discloses a method and system for learning EEG signal representation based on brain regional characteristics. The method of the present invention comprises dividing EEG signal electrodes into regions and obtaining single-channel EEG signal data of each region; encoding the single-channel EEG signal data of each region using a single-channel encoder to obtain regionalized EEG representation; fusing the regionalized EEG representation of each region to obtain fusion features; and classifying based on the fusion features to obtain classification prediction results, wherein the training single-channel encoder is obtained by completing training based on two groups of single-channel EEG signal data based on comparative learning. The present invention aims to learn and distinguish regionalized EEG representations of signals in different brain regions based on the high differences between different brain regions to improve the robustness and generalization of features and the accuracy of EEG signal classification prediction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of electroencephalogram (EEG) signal processing, and in particular relates to an EEG signal representation learning method and system based on brain region characteristics. Background Art

[0002] In recent years, electroencephalogram (EEG)-based feature extraction and classification techniques have shown promising results. However, the field also faces some challenges, such as limited dataset availability, inconsistency in experimental protocols, and inherent spatiotemporal redundancy in EEG data. These challenges limit the development and application of emotion recognition technology. First, the availability of datasets is limited, which may be due to the high cost of acquiring EEG data or the limited amount of data. The lack of datasets with sufficient diversity and scale may affect the generalization ability and performance of the model. Second, different laboratories may use different experimental designs, stimulus materials, and data acquisition procedures, which makes it difficult to jointly train data between different studies. In addition, EEG data itself has spatiotemporal redundancy, that is, there may be high correlation between adjacent time points and spatial channels, which may lead to overfitting and reduce the generalization ability of the model. Therefore, overcoming these challenges and further improving the performance of EEG-based feature extraction and classification have become key technical issues that need to be solved urgently. Summary of the invention

[0003] Technical problem to be solved by the present invention: In view of the above-mentioned problems in the prior art, a method and system for learning EEG signal representation based on brain region characteristics are provided. The present invention aims to learn and distinguish regionalized EEG representations of signals in different brain regions based on the high differences between different brain regions so as to improve the robustness and generalization of features and enhance the accuracy of EEG signal classification prediction.

[0004] In order to solve the above technical problems, the technical solution adopted by the present invention is:

[0005] A method for learning electroencephalogram (EEG) signal representation based on brain region characteristics, comprising the following steps:

[0006] S1, dividing the EEG signal electrodes into M regions, respectively acquiring single-channel EEG signal data of each region, and each region contains single-channel EEG signal data of two channels;

[0007] S2, encoding the single-channel EEG signal data of each region using a single-channel encoder to obtain a regionalized EEG representation;

[0008] S3, fusing the regionalized EEG representations of each region to obtain fused features;

[0009] S4, classification is performed based on the fusion features to obtain the classification prediction results.

[0010] Optionally, the single-channel EEG signal data of each region acquired in step S1 is the single-channel EEG signal data of each region induced by the subject completing a single cognitive task.

[0011] Optionally, the acquisition of single-channel EEG signal data of each region in step S1 includes:

[0012] S1.1, denoising single-channel EEG signal data;

[0013] S1.2, divide the denoised single-channel EEG signal data into windows of fixed size and time.

[0014] Optionally, the denoising of the single-channel EEG signal data in step S1.1 includes:

[0015] S101, downsampling single-channel EEG signal data;

[0016] S102, performing baseline correction on the downsampled single-channel EEG signal data by subtracting the channel mean;

[0017] S103, using a bandpass filter to remove noise interference from the single-channel EEG signal data after baseline correction.

[0018] Optionally, the single-channel encoder in step S2 includes two encoding branches of a convolutional neural network and a recurrent neural network, and the encoding branch of the convolutional neural network for encoding single-channel EEG signal data includes: firstly extracting features of the single-channel EEG signal data respectively through multi-scale one-dimensional convolution, and then splicing the features extracted by the multi-scale one-dimensional convolution and inputting them into a cascade of multiple residual modules through a fully connected layer FC, wherein the residual module is composed of a one-dimensional convolution layer, a batch normalization layer and a RELU activation function layer, and the features output by the last residual module are further passed through a fully connected layer FC to obtain a regionalized EEG representation of the encoding branch; The encoding branch of the recurrent neural network for encoding single-channel EEG signal data includes: first, extracting features of the single-channel EEG signal data through multi-scale gating units respectively, then splicing the features extracted by the multi-scale gating units through cat and inputting the cascaded multiple residual modules through a fully connected layer FC, wherein the residual module is composed of a gating unit layer, a batch normalization layer and a RELU activation function layer, and the features output by the last residual module are further passed through a fully connected layer FC to obtain the regionalized EEG representation of the encoding branch; finally, the regionalized EEG representations of the two encoding branches are connected to obtain the regionalized EEG representation finally output by the single-channel encoder.

[0019] Optionally, in step S3, fusing the single-channel regionalized EEG representations to obtain fused features means connecting the single-channel regionalized EEG representations and then performing attention fusion through a convolutional attention channel fusion module to obtain fused features, wherein the attention fusion comprises sequentially performing temporal convolution, spatial convolution, channel attention, average pooling and flattening, wherein the temporal convolution refers to convolution in the time dimension, the spatial convolution refers to convolution in the channel dimension, and the channel attention refers to processing based on an attention mechanism between channels.

[0020] Optionally, before step S2, the step of training a single-channel encoder is also included:

[0021] S201, select two EEG signal electrodes for each of the M divided regions, thereby dividing the regions into two groups of EEG signal electrodes A and B; collect single-channel EEG signal data of each region through 2N subjects, wherein N subjects collect single-channel EEG signal data of each region through the first group of EEG signal electrodes A , the other N subjects collected single-channel EEG signal data of each area through the second group of EEG signal electrodes B ;

[0022] S202, collect single-channel EEG signal data of each area of ​​N subjects through the first group of EEG signal electrodes A. The first group of regionalized EEG representations of each subject were obtained by encoding using a single-channel encoder. , the other N subjects collected single-channel EEG signal data of each area through the second group of EEG signal electrodes B The second group of regionalized EEG representations of each subject were obtained by encoding using a single-channel encoder. ;

[0023] S203, based on the group mapper shown in the following formula:

[0024] ,

[0025] In the above formula, is the output of the group mapper, Representation group mapper based on regionalized EEG representation of input The output obtained is, is the maximum pooling, ~ Group The regionalized EEG representation of each subject in is the number of brain regions, and the first group of regionalized EEG representations of each subject are The first set of horizontal region feature representations for each subject is obtained through the group mapper , the second group of regionalized EEG representation The second set of horizontal region feature representations for each subject is obtained through the group mapper , and then combined with the first set of horizontal regional features of each subject to represent and the second set of horizontal region feature representation The contrast loss is calculated according to the following formula :

[0026] ,

[0027] In the above formula, express The cosine similarity of is the first set of horizontal regional feature representations for the i-th subject, is the second set of horizontal region feature representation for the jth subject, is the temperature coefficient, the temperature coefficient value range is between 0-1. hour ,otherwise , express The cosine similarity of is the first set of horizontal region feature representation for the jth subject;

[0028] S204, using contrast loss As the loss function, adjust the network parameters of the corresponding single-channel encoder through back-propagation training; determine whether the number of training times is equal to the preset threshold, if not equal to the preset threshold, jump to step S201 to continue training, otherwise determine that the single-channel encoder training is completed, end and exit.

[0029] In addition, the present invention also provides an EEG signal representation learning system based on brain region characteristics, comprising a microprocessor and a memory connected to each other, wherein the microprocessor is programmed or configured to execute the EEG signal representation learning method based on brain region characteristics.

[0030] In addition, the present invention also provides a computer-readable storage medium, which stores a computer program or instruction, and the computer program or instruction is programmed or configured to execute the EEG signal representation learning method based on brain area characteristics through a processor.

[0031] In addition, the present invention also provides a computer program product, including a computer program or instructions, which are programmed or configured to execute the EEG signal representation learning method based on brain region characteristics through a processor.

[0032] Compared with the prior art, the present invention has the following advantages:

[0033] 1. The present invention makes full use of the similarity of EEG signals within regions and the difference between regions. By pulling the representation within a region closer and pulling the representation between regions farther apart, the learned representation can remove the spatial redundancy of EEG signals and improve the robustness and generalization of features.

[0034] 2. By extracting group-level features, the present invention extracts brain region-specific features from multiple subjects that are more generalizable and can improve the performance of cross-subject classification tasks.

[0035] 3. The method of the present invention is not only applicable to the feature extraction of a single data set, but can also be used for joint training of multiple data sets. Feature extraction of single-channel data can break the constraints of different data set paradigms. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] Figure 1 Schematic diagram of the basic flow of the method of the embodiment of the present invention.

[0037] Figure 2 Schematic diagram of the structure of the EEG signal prediction model in an embodiment of the present invention.

[0038] Figure 3 Schematic diagram of the structure of a single-channel encoder in an embodiment of the present invention.

[0039] Figure 4 Schematic diagram of the training process of a single-channel encoder in an embodiment of the present invention.

[0040] Figure 5 Schematic diagram of grouping single-channel EEG signal data in an embodiment of the present invention.

[0041] Figure 6 Schematic diagram of the principle of the loss function for training a single-channel encoder in an embodiment of the present invention.

[0042] Figure 7 This is the confusion matrix for evaluating mixed subject emotion classification in the SEED dataset in an embodiment of the present invention.

[0043] Figure 8 The confusion matrix for mixed subject emotion classification evaluated on the DEAP dataset in an embodiment of the present invention. DETAILED DESCRIPTION

[0044] The EEG signal representation learning method based on brain region characteristics of the present invention is based on the following fact: within a brain region, EEG signals are very similar, while they show high differences between different brain regions. The method aims to obtain a representation that can distinguish signals from different brain regions. By bringing the representations of channels within the same brain region closer together and pushing the representations of channels from different brain regions further apart, region-specific key features can be extracted. The present invention can be used for feature extraction and classification tasks of various EEG paradigm data, and can achieve joint training of multiple data sets. The extracted features have the advantages of strong robustness and strong generalization. Specifically, Figure 1 and Figure 2 As shown, the EEG signal representation learning method based on brain region characteristics in this embodiment includes the following steps:

[0045] S1, dividing the EEG signal electrodes into M regions, respectively acquiring single-channel EEG signal data of each region, and each region contains single-channel EEG signal data of two channels;

[0046] S2, encoding the single-channel EEG signal data of each region using a single-channel encoder to obtain a regionalized EEG representation;

[0047] S3, fusing the regionalized EEG representations of each region to obtain fused features;

[0048] S4, classification is performed based on the fusion features to obtain the classification prediction results.

[0049] In step S1, the EEG signal electrodes are divided into regions. The multi-channel data can be divided into different regions according to the prior knowledge of brain functional division and specific paradigm as needed. For example, as an optional implementation, in this embodiment, the electrode positions of the multi-channel data are basically divided according to the main areas of the brain - frontal lobe, parietal lobe, occipital lobe and temporal lobe. Then, according to the core role of the frontal lobe in controlling high-level functions, the frontal lobe is further subdivided into two symmetrical left and right areas, thereby obtaining a total of M=5 areas. Each area contains two channels of single-channel EEG signal data for constructing sample pairs. The single-channel EEG signal data of two channels in the same area is a positive sample pair, and the single-channel EEG signal data of two channels in different areas is a negative sample pair. See Figure 2 In this embodiment, the single-channel EEG signal data X of M regions are pred (Dimensions are C × l ) are respectively input into the single-channel encoder for encoding, thereby obtaining M regionalized EEG representations area_1 to area_M, and then the M regionalized EEG representations area_1 to area_M are concatenated (cat) to obtain H pred (Dimensions are C × e) Then use the convolution attention channel fusion to get the feature H fused , and finally the feature H fused The classification prediction result is obtained by mapping through the fully connected layer. In this embodiment, the classification prediction result is specifically an emotion label.

[0050] When collecting EEG signals of subjects under specific tasks, due to the volume conduction effect, the EEG signals in the same area will be very similar. The single-channel EEG signal data of each area obtained in step S1 of this embodiment is the single-channel EEG signal data of each area induced by the subject completing a single cognitive task. The subsequent comparative learning strategy based on the single-channel EEG signal data of each area induced by the subject completing a single cognitive task can reduce the spatial redundancy of multi-channel EEG signals, improve the robustness of features, and effectively improve the classification performance of EEG signals in downstream tasks.

[0051] In step S1 of this embodiment, the acquisition of single-channel EEG signal data of each region includes:

[0052] S1.1, denoising single-channel EEG signal data;

[0053] S1.2, the denoised single-channel EEG signal data is processed according to a fixed size time (size is ) to perform figure splitting.

[0054] In step S1.1 of this embodiment, the denoising of the single-channel EEG signal data includes:

[0055] S101, downsampling single-channel EEG signal data;

[0056] S102, performing baseline correction on the downsampled single-channel EEG signal data by subtracting the channel mean;

[0057] S103, using a bandpass filter to remove noise interference from the single-channel EEG signal data after baseline correction; generally speaking, a bandpass filter with a cutoff frequency of 0.5-50 Hz can be selected according to the frequency band of the noise in the EEG signal.

[0058] See also Figure 3 In this embodiment, the single-channel encoder in step S2 includes two encoding branches of a convolutional neural network and a recurrent neural network. The encoding branch of the convolutional neural network for encoding single-channel EEG signal data includes: firstly extracting features of the single-channel EEG signal data by multi-scale one-dimensional convolution Conv1D, Figure 3 In the example, K is the convolution kernel size of the one-dimensional convolution Conv1D. In this embodiment, three scales of one-dimensional convolution Conv1D are specifically included, and the convolution kernel size K is 0.5f s , 0.25fs and 0.125f s , f s is the sampling frequency of the EEG signal; the features extracted by multi-scale one-dimensional convolution are concatenated and cat-ed, and then input into a cascade of multiple residual modules through a fully connected layer FC. The residual module consists of a one-dimensional convolution layer (the convolution kernel size K is 0.25f s ), a batch normalization layer (BN) and a RELU activation function layer, and the features output by the last residual module are passed through a fully connected layer FC to obtain the regionalized EEG representation of the encoding branch; the encoding branch of the recurrent neural network for encoding single-channel EEG signal data includes: firstly extracting features of the single-channel EEG signal data respectively through a multi-scale gating unit GRU, Figure 3 In the figure, H is the hidden layer length of the gated unit GRU; this embodiment specifically includes three scales of gated units GRU, and their H values ​​are 256, 128 and 64 respectively; the features extracted by the multi-scale gated units are then spliced ​​and cat-ed and input into multiple cascaded residual modules through a fully connected layer FC, and the residual module is composed of a gated unit layer (H value is 128), a batch normalization layer (BN) and a RELU activation function layer, and the features output by the last residual module are passed through a fully connected layer FC to obtain the regionalized EEG representation of the encoding branch; finally, the regionalized EEG representations of the two encoding branches are connected to obtain the regionalized EEG representation finally output by the single-channel encoder. Through one-dimensional convolution and gated units, the time-dependent characteristics of single-channel EEG signal data can be effectively extracted. The features extracted by the two branches are connected in a splicing manner to obtain the regional feature representation of each subject, and the representation length obtained by the encoder is .

[0059] like Figure 2 As shown, in step S3 of this embodiment, fusing the single-channel regionalized EEG representations to obtain the fused features means connecting the single-channel regionalized EEG representations and then performing attention fusion through the convolution attention channel fusion module to obtain the fused features, and the attention fusion includes sequentially performing time convolution, spatial convolution, channel attention, average pooling and flattening, wherein the time convolution refers to convolution on the time dimension, spatial convolution refers to convolution on the channel dimension, channel attention refers to processing based on the attention mechanism between channels, and the above-mentioned time convolution, spatial convolution, channel attention, average pooling and flattening are well-known methods, so their detailed implementation details are not described in detail here.

[0060] like Figure 4As shown, before step S2 in this embodiment, the step of training a single-channel encoder is also included, including collecting the number of single-channel EEG signals of multiple subjects under the same stimulation and preprocessing them, dividing the data into two groups according to the subjects for constructing sample pairs, encoding the two groups of data into regionalized EEG representations using a single-channel encoder, and performing group mapping and loss function calculation on the regionalized EEG representation to optimize the network parameters encoded by the single-channel encoder until the training is completed. Specifically, the step of training a single-channel encoder in this embodiment includes:

[0061] S201, select two EEG signal electrodes for each of the M divided regions, thereby dividing the regions into two groups of EEG signal electrodes A and B; collect single-channel EEG signal data of each region through 2N subjects, wherein N subjects collect single-channel EEG signal data of each region through the first group of EEG signal electrodes A , the other N subjects collected single-channel EEG signal data of each area through the second group of EEG signal electrodes B ; Among them, the EEG signal refers to the EEG signal containing multiple channels induced by the subject completing a single cognitive task. The data of multiple subjects in the channel are from the same stimulus segment to achieve stimulus alignment; the features extracted from the two branches are connected in a splicing manner to obtain the regional feature representation of each subject, and the spliced ​​features are passed through the group mapper to obtain the group-level regional feature representation; Figure 5 Medium, G1~G M represents M regions, each of which contains single-channel EEG signal data of 2N subjects. For example, taking region G1 as an example, G 1_A represents the original single-channel EEG signal data collected by the first group of EEG signal electrodes A, G 1_B represents the original single-channel EEG signal data collected by the first group of EEG signal electrodes B, and so on;

[0062] S202, such as Figure 6 As shown, N subjects are tested by collecting single-channel EEG signal data of each area through the first group of EEG signal electrodes A. The first group of regionalized EEG representations of each subject were obtained by encoding using a single-channel encoder. , the other N subjects collected single-channel EEG signal data of each area through the second group of EEG signal electrodes B The second group of regionalized EEG representations of each subject were obtained by encoding using a single-channel encoder. ;

[0063] S203, based on the group mapper shown in the following formula:

[0064] ,

[0065] In the above formula, is the output of the group mapper, Representation group mapper based on regionalized EEG representation of input The output obtained is, is the maximum pooling, ~ Group The regionalized EEG representation of each subject in is the number of brain regions, and the first group of regionalized EEG representations of each subject are The first set of horizontal region feature representations for each subject is obtained through the group mapper , the second group of regionalized EEG representation The second set of horizontal region feature representations for each subject is obtained through the group mapper , and then combined with the first set of horizontal regional features of each subject to represent and the second set of horizontal region feature representation The contrast loss is calculated according to the following formula :

[0066] ,

[0067] In the above formula, express The cosine similarity of is the first set of horizontal regional feature representations for the i-th subject, is the second set of horizontal region feature representation for the jth subject, is the temperature coefficient, the temperature coefficient value range is between 0-1. hour ,otherwise , express The cosine similarity of is the first set of horizontal region feature representations of the jth subject; in this embodiment, the cosine similarity of the two representations is used as the probability output, and the loss function uses the temperature-scaled cross entropy function, which can achieve comparative learning of different regions; Figure 6 In the example, the dimension of the data input to the single-channel encoder is , and the dimension of the data output by a single-channel encoder is , the data dimension of the result obtained by the group mapper is ;

[0068] S204, using contrast loss As the loss function, adjust the network parameters of the corresponding single-channel encoder through back-propagation training; determine whether the number of training times is equal to the preset threshold, if not equal to the preset threshold, jump to step S201 to continue training, otherwise determine that the single-channel encoder training is completed, end and exit.

[0069] In order to verify the EEG signal representation learning method based on brain region specificity in this embodiment, the public DEAP and SEED datasets are used in this embodiment for intra-subject and mixed-subject testing respectively. The DEAP dataset includes 32-channel EEG signals and 8-channel peripheral physiological signals recorded by 32 subjects while watching 40 one-minute music videos. Each experimental data includes 3 seconds of resting state and 60 seconds of stimulation state. The SEED dataset records in detail the EEG signals of 15 participants when they were exposed to three types of emotional stimuli (positive, neutral and negative). The EEG signals are recorded at a high sampling rate of 1000Hz through 62 electrodes, and the stimulation comes from 15 different videos they watched.

[0070] In this embodiment, we conduct mixed-subject experiments on the DEAP dataset and compare our method with the current supervised and self-supervised SOTA methods. The current supervised and self-supervised SOTA methods include: 4D-CRNN, ARCNN, LGGNet, GANSER, SGMC, BiHDM, ResNet18-1D-kernel. The final experimental results on the DEAP dataset are shown in Table 1, and the experimental results on the SEED dataset are shown in Table 2. In Tables 1 and 2, Proposed (Fully-supervised) indicates the result of the network model in the method of this embodiment without pre-training, and Proposed (Fine-tuned) indicates the result of the network model in the method of this embodiment after pre-training and fine-tuning.

[0071] Table 1 DEAP mixed subjects classification results

[0072]

[0073] Table 2 SEED mixed subjects emotion classification results

[0074]

[0075] As shown in Table 1 and Table 2, compared with the above existing SOTA methods, the network model in the method of this embodiment achieves a higher accuracy than them, which shows that the overall architecture of the method of this embodiment is effective and better.

[0076] In order to study the impact of the number of subjects in a group on the pre-training process, the group size affects the quantitative degree of the performance of the contrastive learning representation algorithm. The experimental results on the DEAP dataset in this embodiment are shown in Table 3, and the experimental results on the SEED dataset are shown in Table 4, where Epoch pre represents pre-trained algebra, acc pre Represents the pre-training accuracy.

[0077] Table 3 Pre-training results of different group sizes in DEAP

[0078]

[0079] Table 4 Pre-training results of different group sizes in SEED

[0080]

[0081] Tables 3 and 4 show that an increase in the number of subjects in each group leads to faster convergence of the pre-training process and higher pre-training accuracy. This association suggests that extracting features from more participants enhances the generalization ability of the model. This result is consistent with the intuition that as the number of subjects in a group increases, the commonality of brain region features between subjects becomes more significant. A larger number of subjects in a group enables the model to extract more generalizable group-level stimulus-related features, which helps to mitigate the impact of random interference, fatigue, and individual differences on the model. In addition, the richer representations obtained from larger groups help to enhance the robustness and generalization ability of the learned features. However, it should be pointed out that although higher accuracy is obtained in the pre-training stage, it does not necessarily guarantee improved performance in downstream recognition tasks. Too small a number of subjects in a group leads to low pre-training accuracy and hinders the acquisition of meaningful regionalized representations. On the other hand, too large a value may cause the model to overemphasize the integration of group-level stimulus-related features, potentially causing the channel encoder to neglect learning features related to downstream task classification. Therefore, in the implementation of this method, it is crucial to choose an appropriate value according to the dataset. This choice should aim to capture diverse and comprehensive group-level features while also focusing on the individual nuances necessary for accurate emotion recognition. The optimal value of the group size should enable the model to learn representations that generalize effectively to all participants while retaining the necessary task-related features.

[0082] In this embodiment, in order to study the impact of three brain region divisions on the results and determine the best division method, we configured the sampler to combine different brain region divisions. In the DEAP dataset, the optimal number of group subjects, pre-training generations, and the corresponding pre-training accuracy are shown in Table 5. In the SEED dataset, the optimal number of group subjects, pre-training generations, and the corresponding pre-training accuracy are shown in Table 6. In Tables 5 and 6, General, Frontal, and Hemisphere are three existing well-known brain region classification methods.

[0083] Table 5 Pre-training results of different brain area division methods in DEAP

[0084]

[0085] Table 6 Pre-training results of different brain area division methods in SEED

[0086]

[0087] Tables 5 and 6 show that the General brain region classification method has the smallest group size and required pre-training generations in the DEAP dataset. The Hemisphere brain region classification method requires more group subjects and more pre-training generations. Intuitively, as the number of brain region divisions increases, the number of pre-training combinations increases significantly, so more training generations are required to converge. At the same time, the electrodes are divided into more regions, and the similarity between each region increases, which also reduces the accuracy of pre-training and requires learning more general features from the data of more subjects. In the SEED dataset, the General brain region classification method achieved the highest accuracy in the final classification, probably because the SEED dataset has more electrodes and can be divided into more parts. Due to the small number of subjects in the SEED dataset, there are only 15 subjects in total, and the maximum number of group subjects is 7, which may not have reached the optimal size for extracting group features. Figure 7 The confusion matrix for mixed subject emotion classification evaluated in the SEED dataset in this embodiment is: Figure 8 The confusion matrix for mixed subject emotion classification evaluated on the DEAP dataset in this embodiment. Figure 7 and Figure 8 It shows that the method of this embodiment performs better in each category of each data set.

[0088] In summary, the EEG signal representation learning method based on brain region characteristics in this embodiment is a deep learning pre-training method that uses a contrastive learning framework to represent single-channel EEG data, including data sampling grouping, channel encoder encoding, calculation of contrast loss and back propagation. The EEG signal representation learning method based on brain region characteristics in this embodiment is based on the fact that EEG signals are very similar within a brain region, but show high differences between different brain regions. The method aims to obtain a representation that can distinguish signals from different brain regions. The EEG signal representation learning method based on brain region characteristics in this embodiment can extract region-specific key features by bringing the representations of channels within the same brain region closer and pushing the representations of channels from different brain regions farther away. The EEG representation learning method based on brain region characteristics in this embodiment addresses the problems of spatial redundancy, strong individual specificity, and difficulty in fusion training of multiple data sets in EEG signals. By using the idea of ​​contrastive learning, the distance between representations within the brain region is shortened and the distance between brain regions is increased. This embodiment is used in the specific task of emotion recognition and achieves better performance in both within-subject and across-subject emotion recognition experiments, with the advantages of high evaluation accuracy, good robustness, and strong generalization performance.

[0089] In addition, this embodiment also provides an EEG signal representation learning system based on brain region characteristics, including a microprocessor and a memory connected to each other, and the microprocessor is programmed or configured to execute the EEG signal representation learning method based on brain region characteristics.

[0090] In addition, this embodiment also provides a computer-readable storage medium, which stores a computer program or instruction, and the computer program or instruction is programmed or configured to execute the EEG signal representation learning method based on brain area characteristics through a processor.

[0091] In addition, this embodiment also provides a computer program product, including a computer program or instructions, which are programmed or configured to execute the EEG signal representation learning method based on brain region characteristics through a processor.

[0092] Those skilled in the art should understand that the embodiments of the present application can be provided as methods, systems, or computer program products. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application can take the form of a computer program product implemented on one or more computer-readable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code. The present application 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 application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes 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 produce 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 process Figure 1 A process or multiple processes and / or boxes Figure 1 These computer program instructions can also be stored in a computer-readable memory that can guide a computer or other programmable data processing device to work in a specific way, so that the instructions stored in the computer-readable memory produce a product including an instruction device, which implements the functions specified in the process. Figure 1 A process or multiple processes and / or boxes Figure 1 These computer program instructions can also be loaded onto a computer or other programmable data processing device, so that a series of operation steps are executed on the computer or other programmable device to produce a computer-implemented process, so that the instructions executed on the computer or other programmable device provide for implementing the process in the process. Figure 1A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0093] The above is only a preferred embodiment of the present invention, and the protection scope of the present invention is not limited to the above embodiments. All technical solutions under the concept of the present invention belong to the protection scope of the present invention. It should be pointed out that for ordinary technicians in this technical field, some improvements and modifications without departing from the principle of the present invention should also be regarded as the protection scope of the present invention.

Claims

1. A method for learning EEG signal representation based on brain region characteristics, characterized in that: The steps include: S1, divide the EEG signal electrodes into M regions, obtain single-channel EEG signal data of each region respectively, and each region contains two channels of single-channel EEG signal data for constructing sample pairs, the two channels of single-channel EEG signal data of the same region are positive sample pairs, and the two channels of single-channel EEG signal data of different regions are negative sample pairs; S2, encoding the single-channel EEG signal data of each region using a single-channel encoder to obtain a regionalized EEG representation; S3, fusing the regionalized EEG representations of each region to obtain fused features; S4, classify based on the fusion features to obtain the classification prediction results; The single-channel encoder in step S2 includes two encoding branches of a convolutional neural network and a recurrent neural network. The encoding branch of the convolutional neural network for encoding single-channel EEG signal data includes: firstly extracting features of the single-channel EEG signal data respectively through multi-scale one-dimensional convolution, and then splicing the features extracted by the multi-scale one-dimensional convolution and inputting them into a cascade of multiple residual modules through a fully connected layer FC, wherein the residual module is composed of a one-dimensional convolution layer, a batch normalization layer and a RELU activation function layer, and the features output by the last residual module are further passed through a fully connected layer FC to obtain a regionalized EEG representation of the encoding branch; the recurrent The encoding branch of the neural network for encoding single-channel EEG signal data includes: first, extracting features of the single-channel EEG signal data respectively through multi-scale gating units, then splicing the features extracted by the multi-scale gating units through cat and inputting the cascaded multiple residual modules through a fully connected layer FC, wherein the residual module is composed of a gating unit layer, a batch normalization layer and a RELU activation function layer, and the features output by the last residual module are further passed through a fully connected layer FC to obtain the regionalized EEG representation of the encoding branch; finally, the regionalized EEG representations of the two encoding branches are connected to obtain the regionalized EEG representation finally output by the single-channel encoder.

2. The method for learning EEG signal representation based on brain region characteristics according to claim 1, characterized in that: The single-channel EEG signal data of each region obtained in step S1 is the single-channel EEG signal data of each region induced by the subject completing a single cognitive task.

3. The method for learning EEG signal representation based on brain region characteristics according to claim 1, characterized in that: The acquisition of single-channel EEG signal data of each region in step S1 includes: S1.1, denoising single-channel EEG signal data; S1.2, divide the denoised single-channel EEG signal data into windows of fixed size and time.

4. The method for learning EEG signal representation based on brain region characteristics according to claim 3, characterized in that: The denoising of the single-channel EEG signal data in step S1.1 includes: S101, downsampling single-channel EEG signal data; S102, performing baseline correction on the downsampled single-channel EEG signal data by subtracting the channel mean; S103, using a bandpass filter to remove noise interference from the single-channel EEG signal data after baseline correction.

5. The method for learning EEG signal representation based on brain region characteristics according to claim 1, characterized in that: In step S3, fusing the single-channel regionalized EEG representations to obtain fused features means connecting the single-channel regionalized EEG representations and then performing attention fusion through a convolutional attention channel fusion module to obtain fused features, wherein the attention fusion comprises sequentially performing temporal convolution, spatial convolution, channel attention, average pooling and flattening, wherein the temporal convolution refers to convolution in the time dimension, the spatial convolution refers to convolution in the channel dimension, and the channel attention refers to processing based on an attention mechanism between channels.

6. The method for learning EEG signal representation based on brain region characteristics according to claim 1, characterized in that: Before step S2, the step of training a single-channel encoder is also included: S201, select two EEG signal electrodes for each of the M divided regions, thereby dividing the regions into two groups of EEG signal electrodes A and B; collect single-channel EEG signal data of each region through 2N subjects, wherein N subjects collect single-channel EEG signal data of each region through the first group of EEG signal electrodes A , the other N subjects collected single-channel EEG signal data of each area through the second group of EEG signal electrodes B ; S202, collect single-channel EEG signal data of each area of ​​N subjects through the first group of EEG signal electrodes A. The first group of regionalized EEG representations of each subject were obtained by encoding using a single-channel encoder. , the other N subjects collected single-channel EEG signal data of each area through the second group of EEG signal electrodes B The second group of regionalized EEG representations of each subject were obtained by encoding using a single-channel encoder. ; S203, based on the group mapper shown in the following formula: , In the above formula, is the output of the group mapper, Representation group mapper based on regionalized EEG representation of input The output obtained is, is the maximum pooling, ~ Group The regionalized EEG representation of each subject in is the number of brain regions, and the first group of regionalized EEG representations of each subject are The first set of horizontal region feature representations for each subject is obtained through the group mapper , the second group of regionalized EEG representation The second set of horizontal region feature representations for each subject is obtained through the group mapper , and then combined with the first set of horizontal regional features of each subject to represent and the second set of horizontal region feature representation The contrast loss is calculated according to the following formula : , In the above formula, express The cosine similarity of is the first set of horizontal regional feature representations for the i-th subject, is the second set of horizontal region feature representation for the jth subject, is the temperature coefficient, the temperature coefficient value range is between 0-1. hour, ,otherwise , express The cosine similarity of is the first set of horizontal region feature representation for the jth subject; S204, using contrast loss As the loss function, adjust the network parameters of the corresponding single-channel encoder through back-propagation training; determine whether the number of training times is equal to the preset threshold, if not equal to the preset threshold, jump to step S201 to continue training, otherwise determine that the single-channel encoder training is completed, end and exit.

7. An electroencephalogram signal representation learning system based on brain region characteristics, comprising a microprocessor and a memory connected to each other, characterized in that: The microprocessor is programmed or configured to execute the EEG signal representation learning method based on brain region characteristics as described in any one of claims 1 to 6.

8. A computer-readable storage medium having a computer program or instruction stored therein, characterized in that: The computer program or instruction is programmed or configured to execute the EEG signal representation learning method based on brain region characteristics as claimed in any one of claims 1 to 6 through a processor.

9. A computer program product comprising a computer program or instructions, characterized in that The computer program or instruction is programmed or configured to execute the EEG signal representation learning method based on brain region characteristics as claimed in any one of claims 1 to 6 through a processor.