Electroencephalogram signal-based robust feature extraction and brain fatigue detection method and system
By constructing time-frequency space-based multi-scale fusion features based on EEG signals, feature screening and model input are performed, the problem of difficulty in extracting robust feature across individuals is solved, and the accuracy and quantitative evaluation ability of brain fatigue detection are improved.
Patent Information
- Application Number
- CN202510858722.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-25
- Publication Date
- 2025-07-25
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The difficulty in extracting robust feature across individuals and lack of quantitative evaluation methods in the prior art leads to low accuracy of brain fatigue detection.
A robust feature extraction method based on EEG signals is used to construct time-frequency and space-based multi-scale fusion features, perform feature screening, determine the robust feature set, and input the brain fatigue detection model to improve detection accuracy.
It improves the recognition accuracy of brain fatigue detection and provides an effective means for the quantitative evaluation of brain fatigue.
Smart Images

Figure CN120360569A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of brain fatigue detection, and particularly to a robust feature extraction and brain fatigue detection method and system based on electroencephalogram (EEG) signals. Background Art
[0002] Long-term high-intensity cognitive activities are likely to cause brain fatigue, which in turn seriously affects an individual's cognitive function and behavioral performance. Due to the lag in the subjective feeling of fatigue, serious consequences may be caused and even life safety may be threatened. Therefore, it is of great significance to establish a real-time evaluation system for fatigue state based on objective indicators.
[0003] However, in the prior art, there are problems of difficult cross-individual robust feature extraction and lack of quantitative evaluation means, thus reducing the accuracy of brain fatigue recognition in brain fatigue detection. Summary of the Invention
[0004] The present invention provides a robust feature extraction and brain fatigue detection method and system based on EEG signals to solve the defects of difficult cross-individual robust feature extraction and lack of quantitative evaluation means in the prior art.
[0005] The present invention provides a method for robust feature extraction and brain fatigue detection based on EEG signals, including the following steps: Obtain EEG signal data to be detected; Extract time-domain features, frequency-domain features and spatial-domain features from the EEG signal data, and perform feature fusion on the time-domain features and the frequency-domain features in the channels corresponding to the spatial-domain features to obtain multi-scale fusion features; Based on the feature contribution values of the multi-scale fusion features to the brain fatigue detection results, perform feature screening on the multi-scale fusion features for a preset number of times to obtain the preset number of candidate feature groups, and based on the selection times of a single feature in the preset number of candidate feature groups and the preset number, determine the target frequency of the single feature, and based on the target frequency, determine a robust feature set from the candidate feature groups; Input the robust feature set into a brain fatigue detection model to obtain the brain fatigue detection result output by the brain fatigue detection model.
[0006] According to the method for robust feature extraction and brain fatigue detection based on EEG signals provided by the present invention, the time-domain features include sample entropy, differential entropy, approximate entropy, fractal dimension and time-domain average absolute value of the EEG signal data; the frequency-domain features include band energy and band ratio of the EEG signal data; the band ratio quantifies the dynamic balance state of brain nerve activities by calculating the relative ratio of energy features in different frequency bands.
[0007] A robust feature extraction and brain fatigue detection method based on electroencephalogram (EEG) signals according to the present invention. The robust feature set includes the sub-band energy, total band energy, band energy ratio, sample entropy, and approximate entropy of the EEG signal data, and there is a symmetric distribution of left and right brain features in the robust feature set.
[0008] A robust feature extraction and brain fatigue detection method based on EEG signals according to the present invention. The EEG signal data is collected offline based on the action prompts corresponding to the brain fatigue induction experiment. The brain fatigue induction experiment includes a 2-back fatigue induction paradigm, which is used to require the subject to compare whether the current stimulus is the same as the stimulus two before the current stimulus.
[0009] A robust feature extraction and brain fatigue detection method based on EEG signals according to the present invention. The steps for obtaining the EEG signal data include: Obtain the original EEG signal data; Filter the original EEG signal data to obtain filtered EEG signal data; Downsample the filtered EEG signal data to obtain downsampled EEG signal data; Re-reference the downsampled EEG signal data to obtain the re-referenced EEG signal data; Perform independent component analysis on the re-referenced EEG signal data to obtain the EEG signal data.
[0010] A robust feature extraction and brain fatigue detection method based on EEG signals according to the present invention. The training steps of the brain fatigue detection model include: Obtain an initial brain fatigue detection model, sample EEG signal data, and the labeled brain fatigue classification results of the sample EEG signal data. The initial brain fatigue detection model includes a sample robust feature set extraction module, a regression model, and a classification model connected to the sample robust feature set extraction module. The labeled brain fatigue classification results include labeled brain fatigue classification and labeled brain fatigue scores. The labeled brain fatigue classification results are determined based on the Karolinska Sleepiness Scale score; Based on the sample robust feature set extraction module, extract the sample time-domain features, sample frequency-domain features, and sample spatial-domain features from the sample EEG signal data. In the channels corresponding to the sample spatial-domain features, perform feature fusion on the sample time-domain features and the sample frequency-domain features to obtain sample multi-scale fusion features, and based on the feature contribution values of the sample multi-scale fusion features to the brain fatigue detection results, perform feature screening on the sample multi-scale fusion features for a preset number of times to obtain the preset number of sample candidate feature groups, and based on the selection times of the sample single features in the preset number of sample candidate feature groups and the preset number, determine the sample target frequencies of the sample single features, and based on the sample target frequencies, determine the sample robust feature set from the sample candidate feature groups; Based on the classification model, perform brain fatigue classification on the sample robust feature set to obtain a predicted brain fatigue classification result; Based on the regression model, perform brain fatigue score prediction on the sample robust feature set to obtain a predicted brain fatigue score; Based on the predicted brain fatigue classification result and the labeled brain fatigue classification, and the predicted brain fatigue score and the labeled brain fatigue score, determine the target loss, and based on the target loss, perform parameter iteration on the initial brain fatigue detection model to obtain the brain fatigue detection model.
[0011] According to a method for robust feature extraction and brain fatigue detection based on EEG signals provided by the present invention, the regression model is a random forest model; The predicted brain fatigue score is obtained by performing arithmetic mean on the prediction results of all decision regression trees of the random forest model.
[0012] The present invention also provides a system for robust feature extraction and brain fatigue detection based on EEG signals, including the following units: An acquisition unit, configured to acquire EEG signal data to be detected; A fusion unit, configured to extract the time-domain features, frequency-domain features, and spatial-domain features from the EEG signal data, and perform feature fusion on the time-domain features and the frequency-domain features in the channels corresponding to the spatial-domain features to obtain multi-scale fusion features; A feature screening unit, configured to perform feature screening on the multi-scale fusion features for a preset number of times based on the feature contribution values of the multi-scale fusion features to the brain fatigue detection results to obtain the preset number of candidate feature groups, and based on the selection times of the single features in the preset number of candidate feature groups and the preset number, determine the target frequencies of the single features, and based on the target frequencies, determine the robust feature set from the candidate feature groups; A detection unit, configured to input the robust feature set into a brain fatigue detection model to obtain a brain fatigue detection result output by the brain fatigue detection model.
[0013] The present invention also provides an electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, the method for robust feature extraction and brain fatigue detection based on electroencephalogram signals as described in any one of the above is implemented.
[0014] The present invention also provides a non-transitory computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the method for robust feature extraction and brain fatigue detection based on electroencephalogram signals as described in any one of the above is implemented.
[0015] The present invention also provides a computer program product, including a computer program. When the computer program is executed by a processor, the method for robust feature extraction and brain fatigue detection based on electroencephalogram signals as described in any one of the above is implemented.
[0016] The method and system for robust feature extraction and brain fatigue detection based on electroencephalogram signals provided by the present invention construct a time-frequency-space multi-scale fusion feature based on electroencephalogram signals, and perform a preset number of feature screenings on the multi-scale fusion feature based on the feature contribution value of the brain fatigue detection result to the multi-scale fusion feature to obtain a candidate feature group. Moreover, based on the selection times of a single feature in the candidate feature group and the preset number of times, the target frequency of the single feature is determined, and a robust feature set is determined from the candidate feature group based on the target frequency; the screened robust feature set is input into a brain fatigue detection model to obtain a detection result, thereby improving the recognition accuracy of brain fatigue detection and providing an effective means for quantitative evaluation of brain fatigue. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0018] Figure 1 It is a flowchart of the method for robust feature extraction and brain fatigue detection based on electroencephalogram signals provided by the present invention.
[0019] Figure 2 It is a schematic diagram of the composition of the experimental equipment provided by the present invention.
[0020] Figure 3 It is a flowchart of the electroencephalogram signal data acquisition provided by the present invention.
[0021] Figure 4 It is the schematic diagram of the 2-back fatigue induction paradigm provided by the present invention.
[0022] Figure 5 It is the channel distribution diagram of the robust feature set provided by the present invention.
[0023] Figure 6 It is the structural schematic diagram of the robust feature extraction and brain fatigue detection system based on electroencephalogram (EEG) signals provided by the present invention.
[0024] Figure 7 It is the structural schematic diagram of the electronic device provided by the present invention. Detailed implementation manners
[0025] To make the objectives, technical solutions and advantages of the present invention clearer, the technical solutions in the present invention will be clearly and completely described below with reference to the accompanying drawings in the present invention. Apparently, the described embodiments are some but not all of the embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art without making creative efforts based on the embodiments in the present invention belong to the scope of protection of the present invention.
[0026] The terms "first", "second", etc. in the present invention are used to distinguish similar objects and are not used to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances so that the embodiments of the present application can be implemented in an order different from those illustrated or described herein, and the objects distinguished by "first", "second", etc. generally belong to the same category.
[0027] Figure 1 It is the flow schematic diagram of the robust feature extraction and brain fatigue detection method based on electroencephalogram (EEG) signals provided by the present invention. Figure 2 It is the schematic diagram of the composition of the experimental equipment provided by the present invention. As Figure 1 , Figure 2 shown, the method includes step 110, step 120, step 130 and step 140.
[0028] Step 110: Obtain the electroencephalogram (EEG) signal data to be detected.
[0029] Specifically, the experimental equipment in the embodiments of the present invention includes an electroencephalogram (EEG) device and a computer (fatigue induction platform). The fatigue induction platform induces brain fatigue through a continuous cognitive experiment. Among them, the electroencephalogram (EEG) device includes a 32-channel electroencephalogram cap and an EEG (Electroencephalogram) amplifier.
[0030] All subjects were required to wear an EEG cap to collect EEG data (electroencephalogram signal data) and sit in a standard sitting position in front of a computer monitor. Their hands were placed flat on the ctrl and alt keys of the computer keyboard. The monitor would run a fatigue induction platform to present digital visual stimuli based on the 2-back paradigm for inducing brain fatigue and evaluating the short-term memory and retrospective ability of the subjects. The subjects were required to stare at the target stimuli and mobilize their working memory to judge whether the ( > 2)th number was the same as the -2th number. A 32-channel EEG system was used to record the real-time EEG signals of the subjects during the task execution, so as to establish an objective index system and convert the abstract fatigue state into quantifiable features that can be calculated and modeled.
[0031] Figure 3 is a schematic diagram of the process for collecting EEG signal data provided by the present invention. As Figure 3 shown, in order to ensure that the EEG data analysis has sufficient statistical power, 40 healthy subjects were recruited. The average sleep time of all subjects the night before the experiment was 7.5 hours, ensuring that they were in a relatively normal physiological state at the start of the experiment. To ensure the quality of the collected EEG data, the Cz electrode on the top of the head was used as the reference electrode in the experiment, and EEG paste was used to maintain good contact between the electrode and the scalp, controlling the scalp impedance to be less than 5 kΩ to reduce signal interference and noise. The EEG device was set with a sampling frequency of 1000 Hz to meet the requirement for extracting high-frequency features of the time-domain signal. Brain fatigue induction experiments were conducted on them respectively, and the specific experimental process is as Figure 3 shown. The specific experimental process is as follows: Step 1: Before collecting EEG data, the subjects were required to fill in the KSS (Karolinska Sleepiness Scale) according to their current state.
[0032] Step 2: The subjects first needed to complete 1 minute of eyes-closed rest, while collecting resting-state EEG data and recording the mark points at the start and end of the rest.
[0033] Step 3: Adjust the state and start the first round of 2-back task experiment, which lasted for 10 minutes. Record the number of digital matches and omissions, as well as the mark points at the start and end of the task, and continuously collect task-state EEG data.
[0034] Step 4: Stop collecting EEG data. The subjects self-evaluated according to their current fatigue state, completed the KSS scale scoring, and the filling time was about 1 minute.
[0035] Step 5: Start a new round of 2-back task experiment, repeat Steps 3 and 4, and cycle 6 times until all 6 rounds of 2-back experiments are completed.
[0036] Step 6: After the 6-round 2-back task loop ends, close your eyes and rest quietly for 1 minute while collecting resting-state EEG data and recording the mark points at the start and end of the rest.
[0037] Step 7: Turn off and disassemble the experimental equipment, and the experiment ends.
[0038] Before the experiment, the 2-back task process and precautions were explained in detail to ensure that they fully understood the task requirements and operation rules. All subjects voluntarily participated in the experiment, maintained regular work and rest before the experiment, did not take sedative or excitatory drugs, and signed an informed consent form before the experiment. To control the stability of the experimental environment, the entire experiment was conducted in an independent and quiet space without interference from external factors. The subjects wore EEG caps to ensure normal reception of EEG signals. In summary, the EEG signal data was collected offline based on the action cues corresponding to the brain fatigue induction experiment, and the brain fatigue induction experiment included the 2-back fatigue induction paradigm.
[0039] Figure 4 is the schematic diagram of the 2-back fatigue induction paradigm provided by the present invention, as Figure 4 shown, the 2-back fatigue induction paradigm is used to require the subject to compare the current stimulus and whether the stimulus before the previous stimulus of the current stimulus is the same. The n-back task is a commonly used continuous cognitive fatigue induction method that requires participants to compare the current stimulus with the nth previous stimulus and make a response according to the result, and is used to evaluate the information processing ability in working memory, and is widely used in the fields of cognitive psychology and neuroscience. When n = 2, that is, the 2-back task, requires the subject to compare whether the current stimulus is the same as the stimulus at a position separated by one from it in front. In this task, the software interface randomly and disorderly plays numbers, and only one number is displayed each time, each number stays for 2 s, and there is an interval of 0.5 s between each two numbers. The subject needs to judge whether the two numbers are the same, simulating the memory processing process in daily life. If the numbers are the same, click the (Click) ctrl key, and if they are different, click the alt key. When the first two numbers in the number sequence are displayed, since there are not enough previous numbers for comparison, the subject does not need to make any behavioral responses. The task continues until all the numbers are played, and the total time-consuming is about 10 minutes.
[0040] Based on the above steps, the EEG signal data to be detected can be obtained. Here, the EEG signal data is the EEG signal data that needs to be detected for brain fatigue subsequently.
[0041] Here, the electroencephalogram (EEG) signal data to be detected is the EEG signal data after data preprocessing of the original EEG signal data. The data preprocessing includes electrode positioning, marking useless electrodes, filtering, downsampling, rereferencing, and independent component analysis, etc. The embodiments of the present invention do not make specific limitations on this.
[0042] Here, for the 32-lead electrode positions, electrode positioning is to complete electrode channel matching and calibration using the standard-10-5-cap385.elp file, specify the correct position for each electrode, and improve the spatial registration accuracy of multi-channel signals. Marking useless electrodes is in the 32-lead system. Leads 1-19 and 21-32 are EEG signals, and lead 20 is the electro-oculogram (EOG) electrode, that is, the "IO" channel. Mark it for subsequent artifact identification. After completing artifact processing, the signals of the "IO" channel will be removed to retain the pure EEG signal containing only brain electrical activities.
[0043] Here, the original EEG signal data after electrode positioning and marking useless electrodes can be filtered to obtain filtered EEG signal data. For example, the original EEG signal data can be respectively low-pass filtered at 40 Hz and high-pass filtered at 0.1 Hz through a FIR (Finite Impulse Response Filter) to enhance the quality of the EEG signal.
[0044] In order to reduce the complexity of the EEG signal data and improve the efficiency of subsequent analysis, the original EEG signal data with a sampling rate of 1000 Hz is downsampled to 200 Hz to obtain downsampled EEG signal data. Then, the downsampled EEG signal data is rereferenced using the average reference method, and the potential value of each electrode is corrected relative to the average potential of all electrodes, which helps to reduce the common-mode noise in the EEG signal and enhance the signal components related to brain activities.
[0045] Finally, independent component analysis is performed on the rereferenced EEG signal data to obtain EEG signal data, specifically as follows: To clean the EEG signal as thoroughly as possible, independent component analysis (ICA) is used for artifact removal to effectively separate artifact components. ICA originated from the "cocktail party problem". At a noisy cocktail party, there are people talking at the same time, and there are recording devices collecting speech sample data at the same time. How to recover from these The original speech of an individual became the starting point for the research of ICA algorithm. In response to this problem, ICA provides a solution: Assume that Observation signal , each is a dimensional vector, indicating the At the sampling point The original signal is: ,in The mixing process is expressed by matrix multiplication as:
[0046] is a The confusion matrix for each moment has:
[0047] Indicated in time The voice signal collected by the recording device , Indicates The voice signal sent by n people at the moment .
[0048] In the known observation signal and various signal sources Independent of each other, but each signal source and the confusion matrix When both are unknown, ICA aims to find a linear transformation matrix , from the original signal Classify each signal source in:
[0049] By analyzing the statistical characteristics of the observed signal, the transformed signal is made to have maximum independence and be as close to the original signal as possible. , thereby restoring the original signal.
[0050] Similar to the "cocktail party problem", the brain is a highly complex system, and different brain regions may be involved in different neural activities at the same time. First, the ICA algorithm is used to decompose the EEG data to obtain independent components. The "IO" channel is used to detect the electrooculographic artifacts, automatically identify the artifact components related to eye movements and remove them, effectively reducing the impact of artifacts on EEG data and ensuring the accuracy of subsequent analysis.
[0051] Step 120: Extract the time-domain features, frequency-domain features, and spatial-domain features from the EEG signal data. In the channels corresponding to the spatial-domain features, perform feature fusion on the time-domain features and the frequency-domain features to obtain multi-scale fusion features.
[0052] Specifically, after obtaining the EEG signal data, the time-domain features, frequency-domain features, and spatial-domain features in the EEG signal data can be extracted. Here, the time-domain features are used to reflect the statistical characteristics of the EEG signal data in the time dimension. The frequency-domain features are used to reflect the distribution of the EEG signal data in different frequency components. The spatial-domain features are used to reflect the distribution of the EEG signal data in different brain regions or electrode positions.
[0053] After obtaining the time-domain features, frequency-domain features, and spatial-domain features, feature fusion can be performed on the time-domain features and the frequency-domain features in the channels corresponding to the spatial-domain features to obtain multi-scale fusion features. Here, the fusion of the time-domain features, frequency-domain features, and spatial-domain features can be to splice the time-domain features, frequency-domain features, and spatial-domain features, or to weight and then splice the time-domain features, frequency-domain features, and spatial-domain features using an attention mechanism. The embodiments of the present invention do not make specific limitations on this.
[0054] Here, the embodiments of the present invention select 31 EEG electrode channels to collect EEG signals. The EEG electrode channels specifically include electrodes O1, O2, P3, P4, Pz, P7, P8, CP1, CP2, CP5, CP6, TP9, TP10, C3, C4, Cz, FC1, FC2, FC5, FC6, Fp1, Fp2, FT9, FT10, F3, F4, F7, F8, Fz, T7, and T8. These electrodes cover the main regions of the cerebral cortex, including the frontal lobe, temporal lobe, occipital lobe, parietal lobe, and central region, and can capture the neural activity characteristics reflected from different positions of the cerebral cortex. It can be understood that the signals extracted from these channels can be used to analyze spatial-domain features, such as inter-electrode correlation, spatial power distribution, principal component analysis, and independent component analysis, etc. Table 1 shows the corresponding relationship between each EEG acquisition electrode channel and each brain region.
[0055] Table 1. Corresponding Table of EEG Acquisition Electrode Channels and Brain Regions
[0056] Step 130: Based on the feature contribution values of the multi-scale fusion features to the brain fatigue detection result, perform feature screening on the multi-scale fusion features for a preset number of times to obtain the preset number of candidate feature groups, and based on the selection times of a single feature in the preset number of candidate feature groups and the preset number, determine the target frequency of the single feature, and based on the target frequency, determine a robust feature set from the candidate feature groups.
[0057] Specifically, considering the significant individual differences in electroencephalogram (EEG), the strategy of constructing complex models or multi-modal fusion to overcome individual differences forms an irreconcilable antagonistic relationship between improving accuracy and stability and reducing complexity, leading to the research falling into a double dilemma of "performance - efficiency". Therefore, the embodiments of the present invention use a robust feature screening mechanism to reduce the adverse effects of individual differences on the classification results from the feature source. Among them, the robust feature screening mechanism refers to a screening mechanism that, based on the feature contribution values of multi-scale fusion features to the brain fatigue detection results, performs feature screening on the multi-scale fusion features a preset number of times to obtain a preset number of candidate feature groups, and based on the selection times of a single feature in the preset number of candidate feature groups and the preset number, determines the target frequency of the single feature, and based on the target frequency, determines the robust feature set from the candidate feature groups.
[0058] Given the dual goals of screening out features that can accurately evaluate the fatigue state and exhibit robust common features among different subject groups, strict requirements are imposed on both the efficiency and accuracy of feature screening. An integrated Wrapper feature selection strategy is adopted to optimize the computational efficiency through the integration strategy while ensuring the analysis accuracy. As a Wrapper feature selection method based on random forest, the Boruta algorithm automatically identifies and selects the most important features for the prediction classification model. By introducing the concept of "shadow features", that is, generating pseudo-features by randomly shuffling the original features to reduce the misleading effects of random fluctuations and spurious correlations, the relative importance of the original features is evaluated. The SHAP (SHapley Additive exPlanations) value is the specific implementation of the Shapley value in game theory in model interpretation. By quantifying the marginal contribution of a feature in all possible feature combinations, that is, the incremental effect brought to the overall effect after a certain feature is added when a group of features has already participated in the calculation, it fairly distributes the contribution of each feature to the classification result and outputs the positive or negative contribution value of each feature. Its definition formula is as follows:
[0059] Among them, is the interpretation model, is the feature combination vector. If , it means the feature participates in the classification calculation of the model. If , it means the feature does not participate in the classification; represents the maximum size of the feature, is the baseline contribution value, represents the feature 's Shapley value.
[0060] Here, A Random Forest (RF) model can be used, or a Gradient Boosting Tree (GBT) can be used, etc. The embodiments of the present invention do not make specific limitations thereto.
[0061] It can be understood that, based on the feature contribution value of the multi-scale fusion features to the brain fatigue detection result, performing feature screening on the multi-scale fusion features for a preset number of times to obtain a preset number of candidate feature groups is to evaluate the importance of the multi-scale fusion features from the overall data distribution, which is beneficial to capturing the interaction effects between features, thereby reducing the selection fluctuations caused by the internal randomness of the interpretation model and enhancing the robustness of feature screening.
[0062] Further, to quantify the population universality of features, summarize the feature screening results (a preset number of candidate feature groups) of all subjects, and calculate the frequency of a single feature being selected in the preset number of candidate feature groups, that is, the proportion of the number of times a certain feature is selected. Correspondingly, based on the number of times a single feature is selected in the preset number of candidate feature groups and the preset number, determine the target frequency of the single feature, and based on the target frequency, determine the robust feature set from the candidate feature groups. The formula for the target frequency is as follows:
[0063] Here, determining the robust feature set from the candidate feature groups based on the target frequency is to screen out the single features with a target frequency greater than 50% from the candidate feature groups to obtain the robust feature set. It can be understood that only the features that stably show discriminative power in more than half of the subjects are retained, so as to screen out the key features with discriminative ability and robustness as the robust feature set. It can be understood that the robust feature set refers to a set of features that can still maintain stability and effectiveness in the face of various interferences, noises, data changes, or model errors.
[0064] It can be understood that this operation integrates the SHAP value (feature contribution value) into the Boruta framework, replacing the random forest feature importance mechanism relied on by the traditional Boruta algorithm, to achieve more robust feature screening. This algorithm effectively integrates the global screening ability of Boruta and the stable evaluation mechanism of SHAP, achieving a balance between computational efficiency and accuracy in the high-dimensional EEG feature space.
[0065] It is understandable that the calculation of the feature contribution value of the multi-scale fusion feature to the brain fatigue classification result takes into account the overall distribution of the data. It determines the importance of a feature to the model output by evaluating the average contribution of each feature in all possible feature subsets. This means that the feature contribution value does not depend solely on a single sample, but is based on the distribution of the entire dataset. Moreover, the feature contribution value of the multi-scale fusion feature to the brain fatigue classification result can capture the interaction effects between features. During the calculation process, the feature contribution value of the multi-scale fusion feature to the brain fatigue classification result considers the synergistic effects between features, rather than just the influence of individual features. This global perspective and consideration of interaction effects enable the feature contribution value to more comprehensively reflect the importance of features.
[0066] Step 140: Input the robust feature set into the brain fatigue detection model to obtain the brain fatigue detection result output by the brain fatigue detection model.
[0067] Specifically, after obtaining the robust feature set, the robust feature set can be input into the brain fatigue detection model to obtain the brain fatigue detection result output by the brain fatigue detection model.
[0068] Here, the brain fatigue detection model can be a random forest model, a gradient boosting tree, or a decision tree (DT), etc. The embodiments of the present invention do not make specific limitations in this regard.
[0069] Here, the brain fatigue detection result can be a brain fatigue classification result, a brain fatigue score, or both a brain fatigue classification result and a brain fatigue score. The embodiments of the present invention do not make specific limitations in this regard. The brain fatigue classification result includes a wakeful state, a mild fatigue state, and a severe fatigue state.
[0070] On the one hand, the method provided by the embodiments of the present invention performs feature screening on the multi-scale fusion feature a preset number of times based on the feature contribution value of the multi-scale fusion feature to the brain fatigue detection result, obtaining a preset number of candidate feature groups. Starting from the overall data distribution, it evaluates the importance of the multi-scale fusion feature, which is beneficial for capturing the interaction effects between features, thereby reducing the selection fluctuations caused by explaining the internal randomness of the model and enhancing the robustness of feature screening. And based on the selection times of a single feature in the preset number of candidate feature groups and the preset number, it determines the target frequency of the single feature, and based on the target frequency, determines the robust feature set from the candidate feature groups, further improving the robustness of feature screening from the universality of group features. On the other hand, it inputs the screened robust feature set into the brain fatigue detection model to obtain the brain fatigue detection result output by the brain fatigue detection model, thereby improving the recognition accuracy of brain fatigue detection and providing an effective means for the quantitative evaluation of brain fatigue.
[0071] Based on the above embodiments, the time-domain features include the sample entropy, differential entropy, approximate entropy, fractal dimension, and time-domain average absolute value of the electroencephalogram (EEG) signal data; The frequency-domain features include the band energy and band ratio of the EEG signal data; the band ratio quantifies the dynamic balance state of brain nerve activity by calculating the relative ratio of different band energy features.
[0072] Specifically, the time-domain features include the sample entropy, differential entropy, approximate entropy, fractal dimension, and time-domain average absolute value of the EEG signal data.
[0073] Sample entropy is a non-linear dynamics index that quantifies the complexity and regularity of a time series (such as an EEG signal). It is usually denoted by , where the dimension is , is the similarity tolerance threshold, and is the length. Let the original EEG signal data be , and reconstruct -dimensional vectors, denoted by :
[0074] Among them, is the selected spatial dimension vector, that is, the window length, indicating the continuous points starting from the rd point. Calculate the Euclidean distance between and any component of , and define the maximum distance between each component as the maximum contribution component distance , as shown in the following formula:
[0075] Among them, . Given the threshold and the embedding dimension , calculate the measure of the probability size representing the regularity of the representative sequence , indicating that under the given embedding dimension and the threshold , the probability that the similarity between each vector in the sequence and other vectors is less than , which measures the similarity of adjacent data points in the time series and reflects the complexity and regularity of the sequence, as shown in the formula:
[0076] Among them, , , is also called the template matching number. For all Calculating the average value:
[0077] Among them, represents the average value of all , that is represents the average similarity of data segments with length in the time series when the embedding dimension is .
[0078] When the embedding dimension is set to , similarly, is obtained. Thus, the sample entropy of the EEG signal data is:
[0079] Among them, represents the dimension, represents the similarity tolerance threshold, represents the length, represents the average similarity of data segments with length in the time series when the embedding dimension is , represents the average similarity of data segments with length in the time series when the embedding dimension is .
[0080] Given a set of EEG signal data: , with a total of data points ( and are pre-given parameters, is the embedding dimension, is the similarity tolerance). is expressed as and the distance between the two with the largest difference among the corresponding elements:
[0081] Given the similarity tolerance , for each value, the number of less than is counted, as well as the ratio of this number to the total number of distances, denoted as , that is:
[0082] Taking the logarithm of , and then calculating the average value of this logarithm for all values, denoted as:
[0083] Therefore, approximate entropy can be defined as:
[0084] Differential entropy calculates the entropy value of a signal based on the Probability Density Function (PDF), and reflects the overall uncertainty of the signal in the time domain through integral calculation:
[0085] Among them, represents the probability density function of continuous information, represents the interval of information values. For an EEG signal approximately following a Gaussian distribution with a specific length , its differential entropy is expressed as:
[0086] Then, the Petrosian fractal dimension is used for feature extraction. By binarizing the signal and counting the number of symbol conversions, the calculation of the fractal dimension is simplified. The mathematical expression of the fractal dimension is:
[0087] Among them, represents the fractal dimension, is the number of sampling points of the EEG signal, is the number of symbol changes of the signal.
[0088] The time-domain average absolute value intuitively presents the average intensity of the EEG signal. Let each sampling point in the EEG signal sequence (EEG signal data) be , where , the time-domain average absolute value is defined as:
[0089] Among them, represents the time-domain average absolute value, represents the length, represents each sampling point in the EEG signal data.
[0090] Band energy refers to the integral value of the power spectral density within a specific frequency range, revealing the changes of different frequency components in the EEG signal data, and further reflecting the correlation mechanism between brain cognition and physiological states. The extracted EEG bands include: Delta wave: The frequency range is mainly concentrated in 0.5 - 4 Hz, and this frequency band is associated with deep sleep, restorative rest, and certain pathological states (such as coma).
[0091] Wave: The frequency range is mainly concentrated between 4 and 8 Hz. It is related to light sleep, relaxation, meditation, and some states of inattention or anxiety.
[0092] Wave: The frequency range is mainly concentrated at 8 - 13 Hz. This frequency band usually appears in a wakeful and relaxed state, especially when eyes are closed or during meditation, and is closely related to the state of deep relaxation and rest.
[0093] Wave: The frequency range is mainly concentrated between 13 and 30 Hz. It is usually related to active thinking, concentration, anxiety, and high - intensity cognitive activities.
[0094] Wave: The frequency is mainly concentrated above 30 Hz, and is closely related to high - level cognitive functions such as information processing, attention concentration, and perceptual processing, and is usually prominent when the brain processes complex tasks.
[0095] The band - energy ratio quantifies the dynamic balance state of brain nerve activities by calculating the relative ratio of energy characteristics in different frequency bands. Eight relative ratio characteristics such as , , , , , , , and the total energy of the frequency band are obtained through calculation, and the dynamic regulation law of the brain state is systematically analyzed.
[0096] It can be understood that for the EEG signal data of each subject, sample entropy, differential entropy, approximate entropy, fractal dimension, time - domain average absolute value including time - domain characteristics and frequency - domain characteristics , , , , , , , , are extracted. A total of 19 types of time - frequency characteristics are successively fused with spatial domain characteristics, that is, 31 channels, to construct a feature set containing 589 dimensions (19 feature parameters ×31 channels) for each subject, and multi - dimensional collaborative analysis from time - domain - frequency - domain - spatial domain is carried out to capture more comprehensive and diverse EEG activity information, providing sufficient data support for subsequent evaluation.
[0097] After data preprocessing, the EEG data of 32 subjects were retained as valid data, and three-class labeling was completed according to the KSS scale for subsequent analysis.
[0098] After feature screening, a total of 38 features met the screening criteria and could be used as a robust feature set for fatigue evaluation. The robust feature set and its corresponding importance evaluation results are shown in Table 2.
[0099] Table 2. Feature screening results and their SHAP values
[0100] Figure 5 is the channel distribution map of the robust feature set provided by the present invention. As Figure 5 shown, the robust feature set includes the sub-band energy, total band energy, band energy ratio, sample entropy, and approximate entropy of EEG signal data. There is a symmetric distribution of left and right brain features in the robust feature set. Among them, the sub-band energy of EEG signal data refers to the energy distribution of EEG signals within a specific frequency band range. In the embodiment of the present invention, the sub-band energy refers to the frequency band and the sub-band energy of the frequency band. The band energy ratio refers to the ratio of the energy of a specific frequency band combination to the energy of another frequency band in EEG signal data. In the embodiment of the present invention, the energy ratio of EEG signal data refers to the ratio of the total energy of the frequency band and the frequency band to the energy of the frequency band. The total band energy refers to the total energy of EEG signal data within a specific frequency band range. The similarity test between features shows that the high-frequency features selected by the BorutaShap algorithm are both independent and form a multi-dimensional complementary pattern at the information representation level. Most of the channels where the features are located are symmetrically distributed. As Figure 5 shown, 19 channels can be divided into 8 groups of symmetric dual channels, namely Fp1 / Fp2, F3 / F4, F7 / F8, FC5 / FC6, T7 / T8, TP9 / TP10, P7 / P8, O1 / O2, indicating that the brain is more inclined to rely on the cooperation between the left and right hemispheres when processing the cognitive load caused by brain fatigue. Classifying the channels according to different brain regions, it can be found that the features are mainly concentrated in the frontal lobe, parietal lobe, and bilateral temporal lobe regions of the cerebral cortex.
[0101] The method provided by the embodiments of the present invention describes the characteristics of electroencephalogram (EEG) signals from different perspectives in terms of time-domain features and frequency-domain features. Time-domain features pay more attention to the dynamic changes and complexity of the signals, while frequency-domain features focus on the distribution of the signals over different frequency components. Combining time-domain features and frequency-domain features can more comprehensively reflect the characteristics of EEG signals. Since different features may have different sensitivities to brain fatigue, by integrating these features, the brain fatigue state can be identified more accurately. Moreover, the time-domain features include sample entropy, differential entropy, approximate entropy, fractal dimension, and time-domain average absolute value of EEG signal data, and the frequency-domain features include band energy and band ratio of EEG signal data. Among them, the band ratio quantifies the dynamic balance state of brain nerve activities by calculating the relative ratio of energy features in different frequency bands. These features provide an effective means for the quantitative assessment of brain fatigue, thus solving the technical problem of unclear neural mechanisms of brain fatigue.
[0102] Based on the above embodiments, the training steps of the brain fatigue detection model include: Step 310, obtaining an initial brain fatigue detection model, sample EEG signal data, and the labeled brain fatigue classification result of the sample EEG signal data; the initial brain fatigue detection model includes a sample robust feature set extraction module, a regression model, and a classification model connected to the sample robust feature set extraction module; the labeled brain fatigue classification result includes labeled brain fatigue classification and labeled brain fatigue score; the labeled brain fatigue classification result is determined based on the Karolinska Sleepiness Scale score; Step 320, based on the sample robust feature set extraction module, extracting sample time-domain features, sample frequency-domain features, and sample spatial-domain features from the sample EEG signal data, performing feature fusion on the sample time-domain features and the sample frequency-domain features in the channels corresponding to the sample spatial-domain features to obtain sample multi-scale fusion features, and based on the contribution value of the features to the brain fatigue detection result of the sample multi-scale fusion features, performing feature screening on the sample multi-scale fusion features for a preset number of times to obtain the preset number of sample candidate feature groups, and based on the selection times of the sample single features in the preset number of sample candidate feature groups and the preset number, determining the sample target frequency of the sample single features, and based on the sample target frequency, determining a sample robust feature set from the sample candidate feature groups; Step 330, based on the classification model, performing brain fatigue classification on the sample robust feature set to obtain a predicted brain fatigue classification result; Step 340, based on the regression model, performing brain fatigue score prediction on the sample robust feature set to obtain a predicted brain fatigue score; Step 350: Determine the target loss based on the predicted brain fatigue classification result and the labeled brain fatigue classification, as well as the predicted brain fatigue score and the labeled brain fatigue score, and perform parameter iteration on the initial brain fatigue detection model based on the target loss to obtain the brain fatigue detection model.
[0103] Specifically, to better train the brain fatigue detection model, the training can be carried out based on the following steps: First, obtain the initial brain fatigue detection model, sample electroencephalogram (EEG) signal data, and the labeled brain fatigue classification result of the sample EEG signal data. Among them, the initial brain fatigue detection model includes a sample robust feature set extraction module, a regression model, and a classification model connected to the sample robust feature set extraction module. The labeled brain fatigue classification result includes the labeled brain fatigue classification and the labeled brain fatigue score, where the labeled brain fatigue classification result is determined based on the Karolinska Sleepiness Scale (KSS) score.
[0104] Specifically, the Karolinska Sleepiness Scale (KSS) can be used as a subjective evaluation tool to label the objective physiological index EEG data. By combining psychological and physiological indicators, the deficiency of physiological signals in subjective fatigue perception can be supplemented, and at the same time, the individual difference problem that may occur when solely relying on physiological signals can be alleviated. Table 3 is the KSS fatigue scale, as shown in Table 3 below: Table 3. KSS Fatigue Scale
[0105] The KSS scale only requires 9 rating levels, as shown in Table 3. During the experiment, the filling of KSS is mainly interspersed after each EEG acquisition. The subjects refer to this KSS scale for self-assessment. The scores of the scale range from 1 to 9. The numbers in the previous column represent 9 different fatigue state levels. The higher the score, the stronger the fatigue feeling of the individual. On the contrary, the lower the score, the higher the level of wakefulness of the individual. The subjects complete self-assessment according to their actual physiological state during the experiment, referring to 9 consecutive fatigue levels.
[0106] To improve the sensitivity of EEG data to different fatigue levels and facilitate subsequent fatigue assessment and analysis. The fatigue level is divided into three categories for use as classification detection labels in fatigue assessment: (1) Wakefulness state: 1 - 5 points, the individual has a low level of fatigue, usually has a good task performance, and the cognitive function is at a relatively high level; (2) Mild fatigue state: 6 - 7 points, the individual has a slight sense of fatigue, the cognitive burden increases, but the overall task performance has not been seriously affected; (3) Severe fatigue state: 8 - 9 points, the individual is in an obvious state of fatigue or drowsiness, showing obvious decline in cognitive function and significant decline in task performance.
[0107] Here, the parameters of the initial brain fatigue detection model can be preset or randomly generated, and the embodiments of the present invention do not make specific limitations thereto.
[0108] Here, the initial brain fatigue detection model can be a random forest model, a gradient boosting tree, a decision tree, etc., and the embodiments of the present invention do not make specific limitations thereto.
[0109] After obtaining the sample electroencephalogram signal data, based on the sample robust feature set extraction module, the sample time-domain features, sample frequency-domain features, and sample spatial-domain features in the sample electroencephalogram signal data can be extracted. In the channels corresponding to the sample spatial-domain features, the sample time-domain features and sample frequency-domain features are subjected to feature fusion to obtain sample multi-scale fusion features, and based on the feature contribution values of the brain fatigue detection results to the sample multi-scale fusion features, the sample multi-scale fusion features are subjected to feature screening for a preset number of times to obtain a preset number of sample candidate feature groups, and based on the selection times of the sample single features in the preset number of sample candidate feature groups and the preset number, the sample target frequencies of the sample single features are determined, and based on the sample target frequencies, the sample robust feature set is determined from the sample candidate feature groups. It should be noted that this processing flow is similar to that in step 130 and will not be elaborated here.
[0110] Then, after obtaining the sample robust feature set, based on the classification model, the sample robust feature set can be classified for brain fatigue to obtain the predicted brain fatigue classification result. Here, the predicted brain fatigue classification result includes a wake state, a mild fatigue state, and a severe fatigue state.
[0111] Based on the regression model, the brain fatigue score is predicted for the sample robust feature set to obtain the predicted brain fatigue score.
[0112] Finally, after obtaining the predicted brain fatigue classification result and the predicted brain fatigue score, the first loss can be determined based on the predicted brain fatigue classification result and the labeled brain fatigue classification, the second loss can be determined based on the predicted brain fatigue score and the labeled brain fatigue score, then the target loss can be determined based on the first loss and the second loss, and finally, based on the target loss, the parameters of the initial brain fatigue detection model are iterated, and the initial brain fatigue detection model after the parameter iteration is used as the brain fatigue detection model.
[0113] It can be understood that the greater the difference between the predicted brain fatigue classification result and the labeled brain fatigue classification, the greater the first loss; the smaller the difference between the predicted brain fatigue classification result and the labeled brain fatigue classification, the smaller the first loss.
[0114] It can be understood that the greater the difference between the predicted brain fatigue score and the labeled brain fatigue score, the greater the second loss; the smaller the difference between the predicted brain fatigue score and the labeled brain fatigue score, the smaller the second loss.
[0115] Here, the target loss can be determined based on the sum of the first loss and the second loss, or based on the weighted sum of the first loss and the second loss. The embodiments of the present invention do not make specific limitations thereto.
[0116] Based on the above embodiments, the regression model is a random forest model; The predicted brain fatigue score is obtained by taking the arithmetic mean of the prediction results of all decision regression trees of the random forest model.
[0117] Specifically, the regression model can be a random forest model. Correspondingly, the predicted brain fatigue score is obtained by taking the arithmetic mean of the prediction results of all decision regression trees of the random forest model. The formula is as follows:
[0118] where represents the predicted brain fatigue score, is the predicted score of the th decision regression tree in the random forest model, represents the total number of decision regression trees.
[0119] Based on any of the above embodiments, in the embodiments of the present invention, an objective evaluation of the brain fatigue detection model is performed. In the first stage of objectively evaluating brain fatigue, first, through a classification method, the brain fatigue detection problem is simplified into relatively simple categories, reducing the difficulty of training the brain fatigue detection model and at the same time reducing the influence of noise on the regression process, and a preliminary evaluation of the fatigue level of an individual is performed from a macroscopic qualitative level. In the construction of the classification model, a random forest is used for three-class fatigue classification. The random forest realizes classification optimization by constructing multiple decision trees. When each tree is split, the Gini index is used to quantitatively score the splitting effect each time, and the best feature and splitting point value are continuously selected as the splitting basis until the splitting stops. To evaluate the classification results, the following two performance indicators are used for each subject: (1) Accuracy: Defined as the proportion of correctly classified samples in the total samples, reflecting the overall classification efficacy.
[0120]
[0121] where represents the accuracy rate, is the number of correctly identified positive samples; TN is the number of correctly identified negative samples; is the number of unrecognized positive samples; is the number of unrecognized negative samples.
[0122] (2) F1 score: F1 score is the weighted average of precision and recall. It is applicable to the case of imbalanced classification in this dataset. Precision reflects the model's ability to distinguish negative samples, while recall reflects the model's ability to identify positive samples. The higher the F1 score, the more robust the model.
[0123]
[0124] in, Indicates the accuracy, Represents the recall rate.
[0125] In addition, in order to further verify that these features are consistent among different subjects, the standard deviation of classification accuracy is introduced as an evaluation indicator to determine the classification stability of the feature set among different individuals. Specifically, a lower standard deviation indicates that the feature set can provide consistent classification information among different subjects, and it can be determined that the feature set can overcome the interference of individual differences and has higher classification stability and reliability. On the contrary, a higher standard deviation indicates that these features are too sensitive to individual differences, resulting in fluctuations in classification results with changes in subjects, and cannot be widely applied to different subjects.
[0126] Considering that the fatigue state of an individual is often a continuous and gradual process rather than a sudden change. It is difficult to capture the subtle dynamic changes of the fatigue state by simply conducting macro-level classification research. Especially in practical applications, the design of fatigue warning and intervention measures often depends on the accurate judgment of the fatigue state. When different levels of fatigue are classified into the same category, subsequent intervention measures may be misjudged, making it difficult to provide targeted and effective intervention. Therefore, in the second stage of objective evaluation of brain fatigue, the research perspective is expanded from classification evaluation to the micro-quantitative level, and a quantitative regression model of brain fatigue based on a continuous scoring mechanism is constructed. The 1-100 linear scale is used to achieve a fine description of the degree of fatigue, which is more in line with the dynamic change process of fatigue in real life. In the fatigue regression task, a mapping method based on sample distribution is adopted to evenly distribute the data in each category to the corresponding regression interval. The mapping rules are shown in Table 4.
[0127] Table 4. Regression mapping rules
[0128] To eliminate the dimensional differences between different features, the study adopted the Z-score standard deviation method to transform the input features into a normal distribution with a mean of 0 and a standard deviation of 1, ensuring that the impacts of various features on the regression model training are on the same scale. Subsequently, the random forest algorithm was used to establish an independent random forest regression model for each subject, integrating multiple regression decision trees. The mean squared error (MSE) was used as the criterion when selecting the splitting point. The mean squared error is the average of the sum of the squares of the differences between the predicted values and the true values. The mean squared error has the formula:
[0129] where is the true value, is the predicted value, is the number of samples. By minimizing the MSE, the regression tree can find the most appropriate splitting point. As each regression tree is constructed, the random forest regression model has multiple independent regression trees. Each tree gives a prediction result, but due to the different training data for each tree, their prediction results will also vary. To obtain the final prediction result, the random forest regression averages the prediction results of all the trees. Specifically, the final regression prediction is the arithmetic mean of the prediction results of all the trees, that is:
[0130] where is the predicted value of the th tree, is the total number of trees, is the final prediction of the random forest. After training, the following three evaluation metrics are used to evaluate the regression prediction results: (1) Root Mean Squared Error (RMSE): The root mean squared error is the square root of the expectation of the sum of the squares of the differences between the fitted output values and the fitted true values, reflecting the root mean squared value of the prediction errors and emphasizing the impact of larger errors.
[0131]
[0132] where represents the root mean squared error, is the true value, is the predicted value, is the number of samples.
[0133] (2) Mean Absolute Error (MAE): The mean absolute error is the expected value of the absolute value of the difference between all individual fitted output values and the fitted true values. It is used to measure the average absolute error between the predicted value and the true value, reflecting the magnitude of the deviation of the model prediction.
[0134]
[0135] Among them, represents the mean absolute error, is the true value, is the predicted value, is the number of samples.
[0136] (3) Coefficient of determination : It is used to measure the goodness of fit of the regression model, and its value range is , and the larger the value, the better the fitting effect of the model.
[0137]
[0138] Among them, represents the coefficient of determination, is the true value, is the predicted value, is the number of samples, represents the average value of the predicted values.
[0139] Finally, based on the evaluation results, a dynamic visualization dashboard system for brain fatigue is developed to provide a convenient decision-making support and feedback platform for quantifying brain fatigue.
[0140] In the embodiments of the present invention, the 38-dimensional robust features obtained by feature screening are used as the input of the brain fatigue detection model. In the first stage of brain fatigue assessment, in order to verify the reliability of the experimental results, for each subject, the training set:test set = 7:3 division method is adopted, and the average classification accuracy rate of 32 subjects reaches 91.64%, and the average F1 score reaches 91.21%. Compared with the initial feature set, the classification accuracy rate is increased by about 2.3%. Compared with the non-robust feature set (initial feature set - robust feature), the accuracy rate is increased by about 7%. This confirms that the feature screening process effectively removes a large number of redundant and non-classification contributing features, and only using about 6.4% of the initial feature quantity, a better classification effect can be achieved. After Spearman rank correlation test, the differences in accuracy rates among different feature sets among subjects are statistically significant (p < 0.01), which statistically corroborates the significant role of robust features in improving the classification efficiency of the model. These findings fully prove the potential and advantages of the robust feature set in the fatigue detection task, and can achieve accurate fatigue state discrimination by streamlining the feature dimension. In addition, through stability verification, it is found that the standard deviations of the classification accuracy rates of the initial feature set and the non-robust feature set are 6.28% and 6.56% respectively, and the standard deviations among different individuals are generally high, indicating that the performance differences of these feature sets among different subjects are large and the stability is poor. While the standard deviation of the classification accuracy rate of the robust feature set among different subjects is 5.07%, which is reduced by 1.21% compared with the original feature set (p < 0.05), confirming that the screening mechanism can effectively eliminate sensitive features and retain common physiological features, thus significantly improving the generalization ability of the model. Therefore, it can be considered that the 38 selected features not only show excellent feature stability and cross-subject universality in the cross-subject generalization experiment, but also show strong discrimination ability in brain fatigue assessment.
[0141] In the second stage of brain fatigue assessment, ten-fold cross-validation is used to divide the data set to obtain the average performance evaluation indexes of each subject's model.
[0142] The robust feature extraction and brain fatigue detection system based on electroencephalogram signals provided by the present invention will be described below. The robust feature extraction and brain fatigue detection system based on electroencephalogram signals described below can be mutually corresponding and referred to the robust feature extraction and brain fatigue detection method based on electroencephalogram signals described above.
[0143] Based on any of the above embodiments, the present invention provides a robust feature extraction and brain fatigue detection system based on electroencephalogram signals, Figure 6 which is a schematic structural diagram of the robust feature extraction and brain fatigue detection system based on electroencephalogram signals provided by the present invention, as Figure 6 shown. The system includes: An acquisition unit 610, configured to acquire electroencephalogram signal data to be detected; A fusion unit 620 is configured to extract time-domain features, frequency-domain features, and spatial-domain features from the electroencephalogram (EEG) signal data, and perform feature fusion on the time-domain features and the frequency-domain features in channels corresponding to the spatial-domain features to obtain multi-scale fusion features; A feature screening unit 630 is configured to perform feature screening on the multi-scale fusion features a preset number of times based on the feature contribution value of the multi-scale fusion features to the brain fatigue detection result, obtain the preset number of candidate feature groups, and determine the target frequency of a single feature based on the selection times of the single feature in the preset number of candidate feature groups and the preset number, and determine a robust feature set from the candidate feature groups based on the target frequency; A detection unit 640 is configured to input the robust feature set into a brain fatigue detection model to obtain a brain fatigue detection result output by the brain fatigue detection model.
[0144] On the one hand, the system provided by the embodiment of the present invention performs feature screening on the multi-scale fusion features a preset number of times based on the feature contribution value of the multi-scale fusion features to the brain fatigue detection result, obtains the preset number of candidate feature groups, evaluates the importance of the multi-scale fusion features from the overall data distribution, is conducive to capturing the interaction effect between features, thereby reducing the selection fluctuation caused by explaining the internal randomness of the model, and enhancing the robustness of feature screening. And, based on the selection times of a single feature in the preset number of candidate feature groups and the preset number, the target frequency of the single feature is determined, and a robust feature set is determined from the candidate feature groups based on the target frequency, further improving the robustness of feature screening from the universality of group features; on the other hand, the obtained robust feature set is input into a brain fatigue detection model to obtain a brain fatigue detection result output by the brain fatigue detection model, thereby improving the recognition accuracy of brain fatigue detection and providing an effective means for quantitative evaluation of brain fatigue.
[0145] Based on any of the above embodiments, the time-domain features include sample entropy, differential entropy, approximate entropy, fractal dimension, and time-domain average absolute value of the EEG signal data; the frequency-domain features include band energy and band ratio of the EEG signal data; the band ratio quantifies the dynamic balance state of brain nerve activities by calculating the relative ratio of energy features in different frequency bands.
[0146] Based on any of the above embodiments, the robust feature set includes sub-band energy, total band energy, band energy ratio, sample entropy, and approximate entropy of the EEG signal data, and the robust feature set has a symmetric distribution of left and right brain features.
[0147] Based on any of the above embodiments, the electroencephalogram (EEG) signal data is collected offline on the basis of the action prompts corresponding to the brain fatigue induction experiment; the brain fatigue induction experiment includes a 2-back fatigue induction paradigm, and the 2-back fatigue induction paradigm is used to require the subject to compare whether the current stimulus is the same as the stimulus before the previous stimulus of the current stimulus.
[0148] Based on any of the above embodiments, it further includes an EEG signal data acquisition unit, and the EEG signal data acquisition unit is specifically used for: Acquire the original EEG signal data; Filter the original EEG signal data to obtain filtered EEG signal data; Downsample the filtered EEG signal data to obtain downsampled EEG signal data; Re-reference the downsampled EEG signal data to obtain the re-referenced EEG signal data; Perform independent component analysis on the re-referenced EEG signal data to obtain the EEG signal data.
[0149] Based on any of the above embodiments, it further includes a training unit, and the training unit is specifically used for: Obtain an initial brain fatigue detection model, sample EEG signal data, and the labeled brain fatigue classification result of the sample EEG signal data; the initial brain fatigue detection model includes a sample robust feature set extraction module, a regression model, and a classification model connected to the sample robust feature set extraction module; the labeled brain fatigue classification result includes labeled brain fatigue classification and labeled brain fatigue score; the labeled brain fatigue classification result is determined based on the Karolinska Sleepiness Scale score; Based on the sample robust feature set extraction module, extract the sample time-domain features, sample frequency-domain features, and sample spatial-domain features in the sample EEG signal data. In the channels corresponding to the sample spatial-domain features, perform feature fusion on the sample time-domain features and the sample frequency-domain features to obtain sample multi-scale fusion features, and based on the feature contribution value of the brain fatigue detection result to the sample multi-scale fusion features, perform feature screening on the sample multi-scale fusion features for a preset number of times to obtain the preset number of sample candidate feature groups, and based on the selection times of the sample single features in the preset number of sample candidate feature groups and the preset number, determine the sample target frequency of the sample single features, and based on the sample target frequency, determine the sample robust feature set from the sample candidate feature groups; Based on the classification model, perform brain fatigue classification on the sample robust feature set to obtain a predicted brain fatigue classification result; Based on the regression model, perform brain fatigue score prediction on the sample robust feature set to obtain a predicted brain fatigue score; Based on the predicted brain fatigue classification result and the labeled brain fatigue classification, as well as the predicted brain fatigue score and the labeled brain fatigue score, determine the target loss, and perform parameter iteration on the initial brain fatigue detection model based on the target loss to obtain the brain fatigue detection model.
[0150] Based on any of the above embodiments, the regression model is a random forest model; The predicted brain fatigue score is obtained by arithmetic averaging the prediction results of all decision regression trees of the random forest model.
[0151] Figure 7 is a schematic structural diagram of the electronic device provided by the present invention, as Figure 7 shown, the electronic device may include: a processor 710, a communication interface 720, a memory 730, and a communication bus 740. Among them, the processor 710, the communication interface 720, and the memory 730 complete mutual communication through the communication bus 740. The processor 710 can call the logical instructions in the memory 730 to execute a method for robust feature extraction and brain fatigue detection based on electroencephalogram signals. The method includes: acquiring electroencephalogram signal data to be detected; extracting time-domain features, frequency-domain features, and spatial-domain features from the electroencephalogram signal data, and performing feature fusion on the time-domain features and the frequency-domain features in the channels corresponding to the spatial-domain features to obtain multi-scale fusion features; based on the feature contribution value of the multi-scale fusion features to the brain fatigue detection result, performing feature screening on the multi-scale fusion features for a preset number of times to obtain the preset number of candidate feature groups, and based on the selection times of a single feature in the preset number of candidate feature groups and the preset number, determining the target frequency of the single feature, and based on the target frequency, determining a robust feature set from the candidate feature groups; inputting the robust feature set into a brain fatigue detection model to obtain a brain fatigue detection result output by the brain fatigue detection model.
[0152] In addition, when the logical instructions in the above-mentioned memory 730 are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention. The aforementioned storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical discs that can store program codes.
[0153] On the other hand, the present invention also provides a computer program product. The computer program product includes a computer program that can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the method for robust feature extraction and brain fatigue detection based on electroencephalogram signals provided by the above-mentioned various methods. The method includes: obtaining electroencephalogram signal data to be detected; extracting time-domain features, frequency-domain features, and spatial-domain features from the electroencephalogram signal data, and performing feature fusion on the time-domain features and the frequency-domain features in the channels corresponding to the spatial-domain features to obtain multi-scale fusion features; based on the feature contribution values of the multi-scale fusion features to the brain fatigue detection results, performing feature screening on the multi-scale fusion features a preset number of times to obtain the preset number of candidate feature groups, and based on the selection times of a single feature in the preset number of candidate feature groups and the preset number, determining the target frequency of the single feature, and based on the target frequency, determining a robust feature set from the candidate feature groups; inputting the robust feature set into a brain fatigue detection model to obtain the brain fatigue detection result output by the brain fatigue detection model.
[0154] In another aspect, the present invention also provides a non-transitory computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it implements a robust feature extraction and brain fatigue detection method based on electroencephalogram (EEG) signals, and the method includes: obtaining EEG signal data to be detected; extracting time-domain features, frequency-domain features, and spatial-domain features from the EEG signal data, and in the channels corresponding to the spatial-domain features, performing feature fusion on the time-domain features and the frequency-domain features to obtain multi-scale fusion features; based on the feature contribution values of the multi-scale fusion features to the brain fatigue detection result, performing feature screening on the multi-scale fusion features for a preset number of times to obtain the preset number of candidate feature groups, and based on the selection times of a single feature in the preset number of candidate feature groups and the preset number, determining the target frequency of the single feature, and based on the target frequency, determining a robust feature set from the candidate feature groups; inputting the robust feature set into a brain fatigue detection model to obtain a brain fatigue detection result output by the brain fatigue detection model.
[0155] The system embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art can understand and implement it without creative efforts.
[0156] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the essence of the above technical solutions, or the part that contributes to the prior art, can be embodied in the form of a software product. The computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disc, etc., and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0157] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements on some of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A robust feature extraction and brain fatigue detection method based on electroencephalogram signals, characterized in that, Including: Obtaining electroencephalogram (EEG) signal data to be detected; Extracting time-domain features, frequency-domain features, and spatial-domain features from the EEG signal data. In the channels corresponding to the spatial-domain features, performing feature fusion on the time-domain features and the frequency-domain features to obtain multi-scale fusion features; Based on the feature contribution values of the multi-scale fusion features to the brain fatigue detection results, performing feature screening on the multi-scale fusion features for a preset number of times to obtain the preset number of candidate feature groups, and based on the selection times of a single feature in the preset number of candidate feature groups and the preset number, determining the target frequency of the single feature, and based on the target frequency, determining a robust feature set from the candidate feature groups; Inputting the robust feature set into a brain fatigue detection model to obtain the brain fatigue detection results output by the brain fatigue detection model.
2. The robust feature extraction and brain fatigue detection method based on electroencephalogram signals according to claim 1, wherein, The time-domain features include sample entropy, differential entropy, approximate entropy, fractal dimension, and time-domain average absolute value of the EEG signal data; the frequency-domain features include band energy and band ratio of the EEG signal data; the band ratio quantifies the dynamic balance state of brain nerve activities by calculating the relative ratio of energy features in different frequency bands.
3. The robust feature extraction and brain fatigue detection method based on electroencephalogram signals according to claim 1, wherein The robust feature set includes sub-band energy, total band energy, band energy ratio, sample entropy, and approximate entropy of the EEG signal data, and there is a symmetric distribution of left and right brain features in the robust feature set.
4. The robust feature extraction and brain fatigue detection method based on electroencephalogram signals according to any one of claims 1 to 3, characterized in that The EEG signal data is collected offline based on the action prompts corresponding to the brain fatigue induction experiment; the brain fatigue induction experiment includes a 2-back fatigue induction paradigm, and the 2-back fatigue induction paradigm is used to require the subject to compare whether the current stimulus and the stimulus before the previous stimulus of the current stimulus are the same.
5. The robust feature extraction and brain fatigue detection method based on electroencephalogram signals according to claim 4, wherein The steps for obtaining the EEG signal data include: Obtaining the original EEG signal data; Filtering the original EEG signal data to obtain filtered EEG signal data; Downsampling the filtered EEG signal data to obtain downsampled EEG signal data; Performing re-referencing on the downsampled EEG signal data to obtain the re-referenced EEG signal data; Performing independent component analysis on the re-referenced EEG signal data to obtain the EEG signal data.
6. The robust feature extraction and brain fatigue detection method based on electroencephalogram signals according to any one of claims 1 to 3, characterized in that, The training steps of the brain fatigue detection model include: Obtaining an initial brain fatigue detection model, sample EEG signal data, and the labeled brain fatigue classification results of the sample EEG signal data; the initial brain fatigue detection model includes a sample robust feature set extraction module, a regression model, and a classification model connected to the sample robust feature set extraction module; the labeled brain fatigue classification results include labeled brain fatigue classification and labeled brain fatigue scores; the labeled brain fatigue classification results are determined based on the Karolinska Sleepiness Scale score. Based on the sample robust feature set extraction module, extract the sample time-domain features, sample frequency-domain features, and sample spatial-domain features from the sample EEG signal data. In the channels corresponding to the sample spatial-domain features, perform feature fusion on the sample time-domain features and the sample frequency-domain features to obtain sample multi-scale fusion features. And based on the feature contribution values of the sample multi-scale fusion features to the brain fatigue detection results, perform feature screening on the sample multi-scale fusion features for a preset number of times to obtain the preset number of sample candidate feature groups. And based on the selection times of the sample single features in the preset number of sample candidate feature groups and the preset number, determine the sample target frequencies of the sample single features. And based on the sample target frequencies, determine the sample robust feature set from the sample candidate feature groups; Based on the classification model, perform brain fatigue classification on the sample robust feature set to obtain a predicted brain fatigue classification result; Based on the regression model, perform brain fatigue score prediction on the sample robust feature set to obtain a predicted brain fatigue score; Based on the predicted brain fatigue classification result and the labeled brain fatigue classification, and the predicted brain fatigue score and the labeled brain fatigue score, determine the target loss. And based on the target loss, perform parameter iteration on the initial brain fatigue detection model to obtain the brain fatigue detection model.
7. The method for robust feature extraction and brain fatigue detection based on electroencephalogram signals according to claim 6, wherein The regression model is a random forest model; The predicted brain fatigue score is obtained by performing arithmetic mean on the prediction results of all decision regression trees of the random forest model.
8. A robust feature extraction and brain fatigue detection system based on electroencephalogram signals, characterized in that, It includes: An acquisition unit for acquiring the EEG signal data to be detected; A fusion unit for extracting the time-domain features, frequency-domain features, and spatial-domain features from the EEG signal data, and performing feature fusion on the time-domain features and the frequency-domain features in the channels corresponding to the spatial-domain features to obtain multi-scale fusion features; A feature screening unit for performing feature screening on the multi-scale fusion features for a preset number of times based on the feature contribution values of the multi-scale fusion features to the brain fatigue detection results to obtain the preset number of candidate feature groups, and based on the selection times of the single features in the preset number of candidate feature groups and the preset number, determine the target frequencies of the single features, and based on the target frequencies, determine the robust feature set from the candidate feature groups; A detection unit for inputting the robust feature set into the brain fatigue detection model to obtain the brain fatigue detection result output by the brain fatigue detection model.
9. An electronic device, comprising a memory, a processor, and a computer program stored on the memory and running on the processor, wherein, When the processor executes the computer program, it implements the robust feature extraction and brain fatigue detection method based on EEG signals according to any one of claims 1 to 7.
10. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the robust feature extraction and brain fatigue detection method based on EEG signals according to any one of claims 1 to 7.
Citation Information
Patent Citations
Non-contact fatigue detection method and system
CN113420624A
Employee real-time fatigue monitoring method and system based on electroencephalogram signals
CN118121212A
Fatigue driving detection method based on electroencephalogram signal and channel optimization
CN118285798A
Fatigue driving detection method based on multi-scale network
CN118366133A
Multi-scale feature fusion-based motor imagery electroencephalogram data classification method and device
CN120086640A
Cited By
Electroencephalogram signal-based dysmnesia assessment system
CN121101605A