A multi-source domain adaptive feature analysis method and system based on sample mixing
Through the multi-source domain adaptive feature analysis method based on sample mixing, a mixed sample set is constructed and domain invariant features are extracted, which solves the problems of label confusion and distribution differences in cross-subject and cross-session EEG signal analysis, and improves the accuracy of analysis. rate and generalization performance.
Patent Information
- Application Number
- CN202410950933.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-16
- Publication Date
- 2024-10-25
- Estimated Expiration
- 2044-07-16
AI Technical Summary
Existing EEG signal analysis methods have problems with label confusion and limited model generalization capabilities in cross-subject and cross-session feature analysis, and multi-source domain adaptive methods ignore distribution differences between different source domains, affecting Analyze the effects.
The multi-source domain adaptive feature analysis method based on sample mixing is adopted to construct a mixed sample set by obtaining the EEG signal features of the target domain and multiple source domains, using the public network to extract domain-invariant features, and performing classification prediction through the branch network. Finally, the prediction results of the source domain and the target domain are averaged to achieve alignment of the data conditional distribution.
It improves the accuracy and generalization performance of cross-domain EEG signal recognition, can effectively handle the differences in EEG patterns of different individuals and different time periods, and realizes cross-subject and cross-session feature analysis, with high recognition accuracy and strong generalization. ization ability.
Smart Images

Figure CN118503684B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of electroencephalogram signal analysis, and in particular to a multi-source domain adaptive feature analysis method and system based on sample mixing. Background Art
[0002] When using traditional machine learning-based methods to analyze EEG signal features, it is often necessary to collect and accurately label a large number of signals. However, this method has some problems and challenges in practical applications. First, accurate labeling of signals requires a lot of manpower, time and resources, and the accuracy of labeling depends largely on the professional knowledge and experience of the labeler. Second, due to individual differences and the complexity of the signal acquisition environment, the collected signals may have great variability, which will affect the performance and stability of the model. In recent years, with the development of deep learning, domain adaptation technology (DA) has achieved good results in processing cross-subject signal analysis. DA technology can use labeled data from the source domain to enhance the analysis ability of the unlabeled target domain, thereby significantly improving the learning performance of the target domain. However, although the existing DA method can align the marginal distribution of different subjects, it does not consider the label information of the corresponding task. When aligning the distribution between the subject data, the label may be confused, resulting in the analysis effect of the signal being affected. In addition, most domain adaptation studies focus on the overall adaptation between the target domain and multiple source domains, ignoring the potential differences in distribution between different source domains, resulting in limited model generalization ability. In addition, the premise of merging multiple source domains into one domain and performing domain adaptation (DA) processing is that the marginal distributions of the domains are mainly different, while the conditional distributions remain the same. However, this premise does not always hold true in practice. 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 multi-source domain adaptation feature analysis method and system based on sample mixing are provided. The present invention aims to guide the alignment of the conditional distribution of source domain and target domain data in the domain adaptation process of the multi-source domain adaptation model, realize different feature analysis and alignment across subjects and sessions, and improve the accuracy and generalization performance of cross-domain EEG signal recognition.
[0004] In order to solve the above technical problems, the technical solution adopted by the present invention is:
[0005] A multi-source domain adaptation feature analysis method based on sample mixing includes the following steps:
[0006] S1, obtains the features of EEG signals of the target domain and multiple source domains respectively;
[0007] S2: Mix the features of each source domain with the features of the target domain to construct a mixed sample setH ;
[0008] S3, a mixed sample set of each source domain H Utilize the common network of all source domains to extract domain-invariant features;
[0009] S4, using the branch network corresponding to the source domain to perform classification prediction on the domain-invariant features to obtain a prediction result of the source domain;
[0010] S5, taking the average of the prediction results of all source domains as the prediction result of the target domain;
[0011] In step S2, the features of the source domain and the target domain are mixed to construct a mixed sample set H Including: calculating the similarity between the features of each source domain and all the features of the target domain respectively, and constructing a mixed sample set by linearly combining the features of each source domain with its most similar target domain features according to the following formula H :
[0012] ,
[0013] in, represents a mixed sample, The first samples, is the feature in the source domain, for The most similar target domain features, is the mixing parameter, is the number of source domain samples;
[0014] The public network in step S3 consists of three fully connected layers.
[0015] Optionally, the acquisition of the features of the EEG signal in step S1 includes:
[0016] S1.1, denoising the EEG signals containing multiple channels induced by a single emotion induction experiment;
[0017] S1.2, dividing the denoised EEG signal into windows of fixed size and time;
[0018] S1.3, perform fast Fourier transform on the EEG signal in units of windows to obtain the EEG frequency domain features of different channels, and extract the differential entropy features of the five frequency bands of δ, θ, α, β and γ as the features of the EEG signal.
[0019] Optionally, the noise reduction in step S1.1 includes:
[0020] S1.1.1, downsampling the EEG signal;
[0021] S1.1.2, baseline correction is performed on the downsampled EEG signal by removing the channel mean;
[0022] S1.1.3, use a bandpass filter to remove noise interference from the baseline-corrected EEG signal to obtain the denoised EEG signal.
[0023] Optionally, the branch network in step S4 includes two fully connected layers, the first fully connected layer is used to extract features from domain-invariant features and perform dimensionality reduction, and the second fully connected layer is used to further reduce the feature dimension to the corresponding emotion category as the prediction result of the source domain.
[0024] Optionally, before step S4, the method further includes constructing a mixed sample set by using the features of the source domain, the features of the target domain, and the mixture H The steps of training and optimizing the network parameters of the branch network are performed using samples, and the loss function used for training and optimizing the network parameters of the branch network is the maximum mean error loss , classification loss , mixed loss And the conditional entropy loss The weighted summation result, where the maximum mean error loss The calculation function expression is:
[0025] ,
[0026] In the above formula, is the number of feature samples in the source domain, The source domain feature samples, For public networks The extracted domain-invariant features, is the number of feature samples in the target domain, The target domain feature samples, For public networks Extracted domain-invariant features;
[0027] The mixing loss The calculation function expression is:
[0028] ,
[0029] In the above formula, N is the total number of feature samples, Represents a mixed sample set H For each sample taken from For the branch network to mix the sample set H The prediction results of the samples in .
[0030] Optionally, the conditional entropy loss The calculation function expression is:
[0031] ,
[0032] In the above formula, is the number of feature samples in the target domain, From the target domain For each sample taken from It is the prediction result of the branch network for the target domain feature sample.
[0033] Optionally, the classification loss The calculation function expression is:
[0034] ,
[0035] In the above formula, N is the total number of feature samples, Indicates that from the source domain For each sample taken from and are the prediction results and true labels of the branch network for the source domain feature samples, For cross entropy loss calculation, its calculation function expression is:
[0036] ,
[0037] in, is the true label, For the prediction results.
[0038] In addition, the present invention also provides a multi-source domain adaptive feature analysis system based on sample mixing, comprising a microprocessor and a memory connected to each other, wherein the microprocessor is programmed or configured to execute the multi-source domain adaptive feature analysis method based on sample mixing.
[0039] 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 multi-source domain adaptive feature analysis method based on sample mixing through a processor.
[0040] 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 multi-source domain adaptive feature analysis method based on sample mixing through a processor.
[0041] Compared with the prior art, the present invention has the following advantages: the method of the present invention comprises respectively obtaining the features of the EEG signals of the target domain and multiple source domains; mixing the features of each source domain with the features of the target domain to construct a mixed sample set H; Set the mixed samples of each source domain H The public network of all source domains is used to extract domain-invariant features; the domain-invariant features are classified and predicted using the branch network corresponding to the source domain to obtain the prediction result of the source domain; the prediction results of all source domains are averaged as the prediction result of the target domain. The present invention can utilize the fact that samples with high similarity between different samples are more likely to have similar feature patterns, and construct a mixed sample set by mixing the most similar samples. In the process of domain adaptation of the multi-source domain adaptation model, the alignment of the conditional distribution of source domain and target domain data is guided, and different feature analysis across subjects and sessions can be realized, with the advantages of high recognition accuracy and strong generalization performance. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] Figure 1 Schematic diagram of the basic flow of the method of the embodiment of the present invention.
[0043] Figure 2 Schematic diagram of EEG signal feature extraction and mixed sample set construction in an embodiment of the present invention.
[0044] Figure 3 Schematic diagram of the network structure of the deep learning model in an embodiment of the present invention.
[0045] Figure 4 Schematic diagram of a branch network of a deep learning model in an embodiment of the present invention.
[0046] Figure 5 Schematic diagram of the construction and training process of the deep learning model in an embodiment of the present invention.
[0047] Figure 6 : is the confusion matrix of emotion recognition across subjects and across sessions in an embodiment of the present invention. DETAILED DESCRIPTION
[0048] like Figure 1 As shown, the multi-source domain adaptation feature analysis method based on sample mixing in this embodiment includes the following steps:
[0049] S1, obtains the features of EEG signals of the target domain and multiple source domains respectively;
[0050] S2: Mix the features of each source domain with the features of the target domain to construct a mixed sample set H ;
[0051] S3, a mixed sample set of each source domain H Utilize the common network of all source domains to extract domain-invariant features;
[0052] S4, using the branch network corresponding to the source domain to perform classification prediction on the domain-invariant features to obtain a prediction result of the source domain;
[0053] S5, take the average of all the prediction results of the source domain as the prediction result of the target domain.
[0054] When the subject performs a specific task, the cerebral cortex is stimulated by the outside world and generates evoked electrical activity associated with it. This embodiment uses a multi-source domain adaptive EEG feature analysis method based on sample mixing to select EEG signals, an objective physical signal, to achieve emotion recognition. This can alleviate the subjective influence of interference tasks brought by traditional evaluation methods such as self-questionnaires, and effectively improve the accuracy and generalization of emotion recognition. The EEG signal in step S1 of this embodiment refers to the EEG signal containing multiple channels induced by the subject completing a single emotion induction experiment. Figure 2 As shown, the acquisition of the features of the EEG signal in step S1 of this embodiment includes:
[0055] S1.1, denoising the EEG signals containing multiple channels induced by a single emotion induction experiment;
[0056] S1.2, dividing the denoised EEG signal into windows of fixed size and time;
[0057] S1.3, fast Fourier transform of EEG signals is performed in units of windows ( Figure 2 The EEG frequency domain features of different channels are obtained by using the FFT (represented as FFT in Figure 2), and the differential entropy features of the five frequency bands of δ (1-3Hz), θ (4-7Hz), α (8-13Hz), β (13-30Hz) and γ (31-50Hz) are extracted as the features of the EEG signal. It should be noted that the calculation method of the differential entropy feature is an existing well-known method. For details, please refer to the literature: Duan R, Zhu J, Lu B. Differential entropy feature for EEG-based emotion classification. 6th International IEEE / EMBS Conference on Neural Engineering (NER) , San Diego, CA, USA. 2013.6695876. In step S1.3 of this embodiment, the differential entropy features of five frequency bands, namely δ (1-3 Hz), θ (4-7 Hz), α (8-13 Hz), β (13-30 Hz) and γ (31-50 Hz), are extracted from the EEG frequency domain features of different channels as the features of the EEG signal. The reason for this is that the dominant activity of EEG waves in the frequency domain is based on the frequency band. α centered, but also extends to lower δ, θ frequency band and higher β、 Gamma band.
[0058] The noise reduction in step S1.1 may adopt a feasible noise reduction method as needed. For example, as an optional implementation, the noise reduction in step S1.1 of this embodiment includes:
[0059] S1.1.1, downsampling the EEG signal;
[0060] S1.1.2, baseline correction is performed on the downsampled EEG signal by removing the channel mean, that is, the downsampled EEG signal is processed by subtracting the mean;
[0061] S1.1.3, using a bandpass filter to remove noise interference from the baseline-corrected EEG signal to obtain a de-noised EEG signal. As an optional implementation, in this embodiment, a 0.5-50 Hz bandpass filter is used to remove noise interference from the baseline-corrected EEG signal.
[0062] like Figure 2 As shown, in step S2 of this embodiment, the features of the source domain and the target domain are mixed to construct a mixed sample set H The method comprises: according to the similarity between each source domain sample and all samples in the target domain, each source domain sample is mixed with its most similar target domain sample to obtain a mixed sample set corresponding to each source domain, and the number of samples in the mixed sample set is consistent with the corresponding source domain. Specifically, given the source domain and target domain samples, cosine similarity is used as a measure of the similarity between the source domain sample and the target domain sample, and the source domain sample is linearly combined with the most similar samples in the target domain according to the channel. Specifically, in step S2 of this embodiment, the features of the source domain and the target domain are mixed to construct a mixed sample set. H Including: calculating the similarity between the features of each source domain and all the features of the target domain respectively, and constructing a mixed sample set by linearly combining the features of each source domain with its most similar target domain features according to the following formula H :
[0063] ,
[0064] in, represents a mixed sample, The first samples, is the feature in the source domain, for The most similar target domain features, is the mixing parameter, is the number of source domain samples. The mixing parameter can be selected according to actual needs. For example, in this embodiment, the mixing parameter is 0.8. Obviously, since the mixed sample set is composed of the source domain samples and the target domain samples according to the highest similarity, it can be considered that the source domain samples and the samples obtained by mixing them have a high probability of belonging to the same emotion category, so the source domain label is used as the pseudo label of the mixed sample set.
[0065] Input the data into the public network to extract common domain-invariant features. This includes inputting samples from the source domain, target, and corresponding mixed sample sets into a parameter-sharing public network to extract low-level domain-invariant features; inputting the domain-invariant features extracted by the public network into different branch networks corresponding to the source domain to extract domain-specific features, and outputting the EEG analysis results of the branch network in combination with specific analysis tasks. The analysis results of multiple branch networks are averaged to obtain the final EEG analysis results. Considering that the EEG signal dimension of the input algorithm model is high, such as Figure 3 As shown, the public network in step S3 of this embodiment is composed of three fully connected layers, which are used to effectively reduce the dimension of the input features through the three fully connected layers while retaining the domain invariant features as much as possible. Figure 4 As shown, the branch network in step S4 of this embodiment includes two fully connected layers (FC), the first fully connected layer is used to extract features from domain invariant features and perform dimensionality reduction, and the second fully connected layer is used to further reduce the feature dimension to the corresponding emotion category as the prediction result of the source domain. It should be noted that this embodiment only involves the application of the fully connected layer and does not involve related improvements, so the specific implementation details are not described in detail here.
[0066] This embodiment also includes the step of training a deep learning model composed of a branch network and a public network: simultaneously recording the EEG signals of the subjects when they perform emotion induction tasks and the emotion labels defined according to the task paradigm; preprocessing the EEG signals, extracting the frequency domain features of the EEG signals, and calculating the differential entropy features of different frequency bands. The EEG differential entropy features are used as the input of the deep learning model, and the labels corresponding to the EEG signal samples are used as the output of the algorithm model to construct training sample and test sample data sets, and the network parameters of the deep learning model are trained and optimized to obtain a trained deep learning model. It should be noted that the selection method of the training sample data set is different in cross-subject emotion recognition and cross-session emotion recognition. In the cross-subject EEG analysis experiment, one of the subjects needs to be selected from all the subjects as the target domain, and the remaining subjects are selected as the source domain. The training set includes unlabeled data in the target domain and labeled data in the source domain; in the cross-session EEG analysis experiment, the samples of one session of a single subject are used as the target domain, and the remaining sessions are used as the source domain. The training set is labeled data in the source domain and unlabeled data in the target domain. Specifically, Figure 4 and Figure 5As shown, before step S4, this embodiment also includes using the features of the source domain, the features of the target domain, and the mixed construction of the mixed sample set H The steps of training and optimizing the network parameters of the branch network are performed by using samples, and the loss function used for training and optimizing the network parameters of the branch network is the Maximum Mean Discrepancy (MMD) loss. , classification loss , mixed loss And the conditional entropy loss The weighted summation result, where the maximum mean error loss The calculation function expression is:
[0067] ,
[0068] In the above formula, is the number of feature samples in the source domain, The source domain feature samples, For public networks The extracted domain-invariant features, is the number of feature samples in the target domain, The target domain feature samples, For public networks Extracted domain-invariant features;
[0069] The classification loss The calculation function expression is:
[0070] ,
[0071] In the above formula, N is the total number of feature samples, Indicates that from the source domain For each sample taken from and are the prediction results and true labels of the branch network for the source domain feature samples, For cross entropy loss calculation, its calculation function expression is:
[0072] ,
[0073] in, is the true label, To predict the results;
[0074] The mixing loss The calculation function expression is:
[0075] ,
[0076] In the above formula, N is the total number of feature samples, Represents a mixed sample set H For each sample taken from For the branch network to mix the sample set H The prediction results of the samples in ;
[0077] The conditional entropy loss The calculation function expression is:
[0078] ,
[0079] In the above formula, is the number of feature samples in the target domain, From the target domain For each sample taken from It is the prediction result of the branch network for the target domain feature sample.
[0080] In order to verify the multi-source domain adaptive EEG feature analysis method based on sample mixing in this embodiment, the public SEED emotion dataset is used in this embodiment to perform cross-subject and cross-session emotion recognition analysis. The SEED dataset places 64 electrodes in the standard 10-20 positions, records the EEG signals of 15 testers during the emotion induction experiment, and the sampling frequency is set to 1000Hz. The emotion induction experiment process of the SEED dataset is as follows: the experimental screen of each trial plays a clipped video material of about 4 minutes, there will be a 15-second prompt before each playback, and there will be 45 seconds of self-evaluation and 15 seconds of rest after the playback. Each experiment contains 15 trials, and a total of 15 different video stimulus materials are played, and every 5 materials correspond to an emotion category. Each subject conducted a total of 3 experiments (one week apart), each experiment contained 15 trials, a total of 45 times, for the recognition of three categories of positive, neutral, and negative emotions. Experimental results of emotion recognition across subjects: In this embodiment, each subject in each session (the same experiment conducted by all subjects is regarded as one session) is used as the target domain in turn, and the remaining 14 subjects are used as the source domain. The average accuracy of the three sessions is used as the recognition result to perform emotion recognition across subjects. The results are shown in Table 1.
[0081] Table 1 Emotion recognition results across subjects (%)
[0082]
[0083] As shown in Table 1, the average recognition accuracy of the method in this embodiment for each subject in the SEED dataset is above 80%, with a minimum of 80.37% and a maximum of 99.94%. The recognition accuracy of 8 out of 15 subjects is higher than 90%, which fully proves that the method in this embodiment has better generalization ability in the cross-subject emotion recognition task.
[0084] For the cross-session emotion recognition experiment, in this embodiment, one of the three sessions of each subject is used as the target domain, and the data of the other two sessions are used as the source domain, until each session is used as a target domain, and cross-session emotion recognition is performed. The results are shown in Table 2.
[0085] Table 2 Cross-session emotion recognition results (%)
[0086]
[0087] As shown in Table 2, in the cross-session experiment where both the source domain and the target domain are from the same subject data, the average accuracy of the three sessions of the method in this embodiment is above 90%, and the accuracy of most sessions is above 80%. When the first and third sessions are used as the target domain, the accuracy of the algorithm is significantly higher than when the first session is used, reaching 95.181% and 93.214% respectively, which shows that the method in this embodiment has good performance in cross-session emotion recognition.
[0088] In order to further study the degree of confusion between samples of different categories, the confusion matrix of the three levels is plotted as follows Figure 6 As shown, (a) is the confusion matrix across subjects, and (b) is the confusion matrix across sessions. Figure 6 It can be found that in the cross-subject experiment, this example method is prone to misidentify positively labeled samples as neutral emotions. When identifying different emotions, it is easy to identify neutral samples as positive emotions in the cross-session experiment. In general, this example method is prone to confuse neutral and negative emotion samples, and the error rate of these two categories is higher, while the error rate is relatively low when identifying negative emotion samples.
[0089] In order to further verify the performance of the deep learning model of the method in this embodiment on cross-subject and cross-session tasks, it is compared with the currently advanced existing methods for comparison. The existing methods for comparison include: DCORAL, see the literature: Sun B, Saenko K. Deep CORAL: Correlation Alignment for DeepDomain Adaptation. 14th European Conference on Computer Vision (ECCV).Amsterdam, NETHERLANDS, 2016:443-450.MS-MDA Translation Guide:Chen H, Jin M, Li Z, etal. MS-MDA: Multisource Marginal Distribution Adaptation for Cross-subjectand Cross-session EEG Emotion Recognition. Frontiers in Brain Science . . . . 2021.15 TANN PHYSIOLOGY:Li Y, Fu B, Li F, et al. A novel transferability attentionneural network model for EEG emotion recognition. Neurocomputing . . . . 2021, 447(2).GMSS Proceedings:Li Y, Chen J, Li F, et al. GMSS: Graph-Based Multi-TaskSelf-Supervised Learning for EEG Emotion Recognition. IEEE Transactions on Affective Computing , 2023, 14:2512-2525.MS-ADA Translation System:She Q, Zhang C, FangF, et al. Multisource Associate Domain Adaptation for Cross-Subject andCross-Session EEG Emotion Recognition. IEEE Transactions on Instrumentation and Measurement , 2023, 72. MFA-LR Dissertation:JIMÉNEZ-GUARNEROS M, FUENTES-PINEDAG. Learning a robust unified domain adaptation framework for cross-subjectEEG-based emotion recognition. Biomedical Signal Processing and Control , 2023.86: 105138. JIMENEZ-GUARNEROS M, FUENTES-PINEDA G. Domain-Adversarial Training of Neural Networks. Journal of Machine Learning Research.2016, 17. These existing methods proposed different network architectures and strategies for cognitive load identification as comparisons, and were all verified on the SEED emotion dataset. The results are shown in Tables 3 and 4.
[0090] Table 3 Comparison of cross-subject task results of the method in this embodiment and other existing methods
[0091]
[0092] Table 4 Comparison of cross-session task results of the method in this embodiment with other existing methods
[0093]
[0094] As shown in Table 3 and Table 4, the method of this embodiment is superior to other existing methods in terms of accuracy index. The comparison results prove the effectiveness of the method of this embodiment in cross-subject and cross-session tasks.
[0095] In order to evaluate the contribution of the loss function in the method of this embodiment, this embodiment designs an ablation experiment, and studies the emotion classification results of ablating conditional entropy loss, mixed loss, and simultaneous ablation as shown in Table 5.
[0096] Table 5 Ablation study based on cross-subject and cross-session emotion recognition
[0097]
[0098] See Table 5, the model proposed by the method of this embodiment is model No. 4. The ablation experiment analysis in this embodiment is as follows: 1) Ablation of conditional entropy loss during training. The results show that pushing the decision boundary away from the high-density area in the target domain helps to improve the performance of the model, but the decrease in accuracy is relatively small, about 1%. In addition, even without conditional entropy loss, the results of this method are better than most of the comparison methods in the previous article. 2) After the mixed loss is ablated, the accuracy of the model drops significantly, with a decrease of 2.89% and 2.57% in the SEED dataset. This decrease may be due to the fact that the model does not consider the conditional distribution between the alignment domains, which reflects the necessity and effectiveness of using mixed samples for conditional alignment. 3) When the conditional entropy loss and the mixed loss are removed, the model is forced to focus only on classification and MMD loss, and the performance is significantly reduced compared with the complete model. In this embodiment, the frequency domain features of the EEG signal are extracted and a mixed sample set is constructed based on the sample similarity metric, which effectively combines the label information of the source domain sample with the data information of the target domain sample, and reduces the conditional distribution difference between the source domain and the target domain by optimizing the loss function, so as to achieve a more accurate recognition effect.
[0099] In summary, the multi-source domain adaptation feature analysis method based on sample mixing in this embodiment includes collecting multi-channel signals of corresponding analysis tasks; preprocessing signals, extracting signal features, and mixing samples to obtain a mixed sample set using a similarity measure between samples; based on a common-branch network, learning domain-invariant features in the common network, and learning domain-specific features of the corresponding source domains in the branch network corresponding to the number of source domains; training a multi-source domain adaptation model for feature analysis; and obtaining a multi-source domain adaptation feature analysis system. The method of this embodiment aims to solve the problem that EEG patterns of different individuals or the same individual at different times are quite different and difficult to analyze, and explores the potential characteristics of label convergence between highly similar samples. This embodiment uses the fact that samples with high similarity between source domain subjects and target domain subjects may have the same feature patterns. By mixing the most similar samples, the constructed mixed sample set can effectively combine the corresponding source domain and target domain sample information, reduce the conditional distribution difference between the target domain and the source domain during the domain adaptation process, and realize multi-source domain adaptation across subjects and across sessions. Different feature analysis can be achieved, and the indirect method of mixing is used to guide the alignment of conditional distributions between domains, which is manifested in the construction of the obtained mixed sample set; a multi-source domain adaptation network based on a public branch network is built and trained; the obtained multi-source domain adaptation emotion recognition system has achieved better performance in cross-subject and cross-session emotion recognition experiments, and has the advantages of high evaluation accuracy and strong generalization performance.
[0100] In addition, this embodiment also provides a multi-source domain adaptive feature analysis system based on sample mixing, including a microprocessor and a memory connected to each other, and the microprocessor is programmed or configured to execute the multi-source domain adaptive feature analysis method based on sample mixing.
[0101] 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 multi-source domain adaptive feature analysis method based on sample mixing through a processor.
[0102] In addition, this embodiment also provides a computer program product, including a computer program or instructions, which are programmed or configured to execute the multi-source domain adaptation feature analysis method based on sample mixing through a processor.
[0103] 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 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0104] 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 multi-source domain adaptation feature analysis method based on sample mixing, characterized in that: The steps include: S1, obtains the features of EEG signals of the target domain and multiple source domains respectively; S2: Mix the features of each source domain with the features of the target domain to construct a mixed sample set H ; S3, a mixed sample set of each source domain H Utilize the common network of all source domains to extract domain-invariant features; S4, using the branch network corresponding to the source domain to perform classification prediction on the domain-invariant features to obtain a prediction result of the source domain; S5, taking the average of the prediction results of all source domains as the prediction result of the target domain; In step S2, the features of the source domain and the target domain are mixed to construct a mixed sample set H Including: calculating the similarity between the features of each source domain and all the features of the target domain respectively, and constructing a mixed sample set by linearly combining the features of each source domain with its most similar target domain features according to the following formula H : , in, represents a mixed sample, The first samples, is the feature in the source domain, for The most similar target domain features, is the mixing parameter, is the number of source domain samples; The public network in step S3 consists of three fully connected layers.
2. The multi-source domain adaptation feature analysis method based on sample mixing according to claim 1 is characterized in that: The acquisition of the features of the EEG signal in step S1 includes: S1.1, denoising the EEG signals containing multiple channels induced by a single emotion induction experiment; S1.2, dividing the denoised EEG signal into windows of fixed size and time; S1.3, perform fast Fourier transform on the EEG signal in units of windows to obtain the EEG frequency domain features of different channels, and extract the differential entropy features of the five frequency bands of δ, θ, α, β and γ as the features of the EEG signal.
3. The multi-source domain adaptation feature analysis method based on sample mixing according to claim 2 is characterized in that: The noise reduction in step S1.1 includes: S1.1.1, downsampling the EEG signal; S1.1.2, baseline correction is performed on the downsampled EEG signal by removing the channel mean; S1.1.3, use a bandpass filter to remove noise interference from the baseline-corrected EEG signal to obtain the denoised EEG signal.
4. The multi-source domain adaptation feature analysis method based on sample mixing according to claim 1 is characterized in that: The branch network in step S4 includes two fully connected layers. The first fully connected layer is used to extract features from domain-invariant features and perform dimensionality reduction. The second fully connected layer is used to further reduce the feature dimension to the corresponding emotion category as the prediction result of the source domain.
5. The multi-source domain adaptation feature analysis method based on sample mixing according to claim 4 is characterized in that: Step S4 also includes constructing a mixed sample set by using the features of the source domain, the features of the target domain, and the mixture H The steps of training and optimizing the network parameters of the branch network are performed using samples, and the loss function used for training and optimizing the network parameters of the branch network is the maximum mean error loss , classification loss , mixed loss And the conditional entropy loss The weighted summation result, where the maximum mean error loss The calculation function expression is: , In the above formula, is the number of feature samples in the source domain, The source domain feature samples, For public networks The extracted domain-invariant features, is the number of feature samples in the target domain, The target domain feature samples, For public networks Extracted domain-invariant features; The mixing loss The calculation function expression is: , In the above formula, N is the total number of feature samples, Represents a mixed sample set H For each sample taken from For the branch network to mix the sample set H The prediction results of the samples in is the true label, For cross entropy loss calculation, its calculation function expression is: , in, is the true label, For the prediction results.
6. The multi-source domain adaptation feature analysis method based on sample mixing according to claim 5 is characterized in that: The conditional entropy loss The calculation function expression is: , In the above formula, is the number of feature samples in the target domain, From the target domain For each sample taken from It is the prediction result of the branch network for the target domain feature sample.
7. The multi-source domain adaptation feature analysis method based on sample mixing according to claim 5 is characterized in that: The classification loss The calculation function expression is: , In the above formula, N is the total number of feature samples, Indicates that from the source domain For each sample taken from and are the prediction results and true labels of the branch network for the source domain feature samples, For cross entropy loss calculation, its calculation function expression is: , in, is the true label, For the prediction results.
8. A multi-source domain adaptive feature analysis system based on sample mixing, comprising a microprocessor and a memory connected to each other, characterized in that: The microprocessor is programmed or configured to execute the multi-source domain adaptive feature analysis method based on sample mixing as described in any one of claims 1 to 7.
9. 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 multi-source domain adaptive feature analysis method based on sample mixing according to any one of claims 1 to 7 through a processor.
10. 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 multi-source domain adaptive feature analysis method based on sample mixing according to any one of claims 1 to 7 through a processor.
Citation Information
Patent Citations
Federal multi-source domain adaptation method and system based on shadow model
CN113989595A
Domain self-adaptive intelligent emotion recognition method and device based on electroencephalogram signals
CN115444419A
Cross-subject electroencephalogram emotion recognition method and system based on multi-branch sample selection
CN117150397A
Method for optimizing individual emotion recognition model
CN117290730A
Motor imagery electroencephalogram classification method based on self-attention improved domain adaptation network
CN117332300A
