A method and device for evaluating electroencephalogram data quality
By preprocessing and secondary searching of EEG data, and calculating EEG quality indicators, the low accuracy and misjudgment of EEG data quality evaluation in the existing technology are solved, and efficient and accurate EEG data quality evaluation and quality control are achieved.
Patent Information
- Application Number
- CN202411519936.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-29
- Publication Date
- 2025-05-06
- Estimated Expiration
- 2044-10-29
AI Technical Summary
The existing EEG data quality evaluation methods have low accuracy, complex calculations, low efficiency, lack of EEG data quality evaluation information, and misjudgment of preprocessing marks.
By collecting continuous raw EEG data under specific induced task stimulation, preprocessing and labeling, single trial EEG data segments are extracted, and secondary searches are performed to calculate EEG quality indicators, quantitative analysis and comprehensive evaluation are carried out to improve evaluation accuracy and efficiency.
Accurate, simple and efficient quality evaluation of EEG data is achieved, pre-processing misjudgment is reduced, and objective comprehensive overall quality evaluation and quality control methods are provided.
Smart Images

Figure CN119523499B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to a technical field related to an electroencephalogram (EEG) signal processing method, and in particular to an electroencephalogram (EEG) data quality assessment method and device. Background Art
[0002] In recent years, with the continuous advancement of brain projects in various countries, large-scale multi-center research has gradually become a new research model for understanding and studying the brain. Under this model, frequent collaboration among multiple research institutions makes EEG data consistency and data standardization processing increasingly important. The quality control of event-related potential signals has received attention from researchers because it can ensure the interpretability and reliability of data in related studies. In terms of factors affecting quality, the quality of event-related potential signals is affected by acquisition hardware, software, physiological and psychological states of subjects, and external factors. Among them, electrooculographic signals, due to the influence of eye movement, will cause bioelectric signals of changes in the potential around the eyes, thereby generating artifacts in the EEG signals, resulting in data distortion and affecting the accuracy and reliability of subsequent analysis. This effect is particularly evident in event-related potential analysis.
[0003] In the prior art, when evaluating the quality of EEG data, eye artifacts can be removed by filtering, manual removal, independent component analysis, regression analysis, etc. However, since the existing methods are relatively independent of the overall quality evaluation of EEG data, the following problems may exist:
[0004] On the one hand, from the perspective of existing methods themselves, although filter elimination is relatively simple and has low computational overhead, it may remove useful low-frequency or high-frequency EEG information, so its accuracy is not high and it is sensitive to parameter selection; manual elimination methods are inefficient and rely on the operator's experience, which may also cause problems of low accuracy; independent component analysis and regression analysis have good accuracy, but due to the complex parameter selection and high computational overhead, there is a risk of long processing time and large amount of calculation.
[0005] On the other hand, from the perspective of EEG data quality assessment, existing EOG artifact removal methods do not evaluate and grade the data, but mostly adopt a direct elimination method. Therefore, they are less flexible and limited, and have little room for subsequent operations, especially in collaborative data transmission in multiple locations. They cannot provide effective quality information. In the overall comprehensive evaluation, due to the lack of quantitative indicators of EOG quality, the overall assessment is often made through experience, which is not objective enough.
[0006] On the other hand, during the EEG data quality preprocessing process, some data may be mistakenly considered to be substandard due to the failure to consider the impact of EO data, thus causing data loss and increasing the workload of experimental testing.
[0007] Therefore, in view of the low accuracy, complex calculation and low efficiency of the existing EEG data electrooculogram quality evaluation, the lack of EO data quality assessment information, and the existence of misjudgment in preprocessing marks, it is a technical problem to be solved to evaluate the quality of EO data at the trial level through accurate, simple and efficient methods, reduce preprocessing misjudgments, and objectively evaluate the comprehensive overall quality of EEG data and provide quality control methods. Summary of the invention
[0008] In view of the above problems in the prior art, the present application provides an EEG data quality assessment method and device, which can evaluate the quality of electrooculogram data at the trial level through an accurate, simple and efficient method, reduce preprocessing misjudgments, thereby objectively evaluating the comprehensive overall quality of EEG data and providing a quality control method.
[0009] To achieve the above objectives, the present application provides a method for evaluating the quality of electroencephalogram data in the first aspect, comprising:
[0010] Collecting and preprocessing the continuous raw EEG data under the stimulation of a specific induced task, marking EEG data segments with abnormal quality; extracting single trial EEG data segments under the stimulation of the specific induced task; marking the single trial EEG data segments that have an intersection with the EEG data segments marked with abnormal quality as single trial EEG data segments with abnormal quality;
[0011] Performing a secondary search on the EEG data segment with abnormal quality in the single trial, and calculating the electrooculographic quality index;
[0012] Evaluate the electrooculogram quality at a single trial level according to the electrooculogram quality index; and correct the continuous raw electroencephalogram data in combination with the single trial event-related potential electroencephalogram data quality index;
[0013] A comprehensive evaluation is performed on the overall EEG data, and quality control is performed based on the comprehensive evaluation results.
[0014] From the above, the EEG data quality assessment method of the present application provides an assessment basis for EEG data by quantitatively analyzing the eye contact quality of a single trial EEG data segment; reduces preprocessing misjudgments by performing a secondary search on EEG data marked as quality abnormalities after preprocessing; and performs quality assessment by retrieving data abnormality sites, which has a small amount of calculation and a fast speed, and can obtain highly accurate quality evaluation results by directly judging peaks or mutations in EEG data.
[0015] As a possible implementation of the first aspect, the continuous raw EEG data is a signal obtained by 64 electrodes; the preprocessing includes detecting bad conductors, high-pass or notch filtering, artifact removal, bad conductor interpolation, REST re-reference and marking bad segments.
[0016] From the above, acquiring EEG signals through 64 electrodes can improve spatial resolution and signal quality; conventional preprocessing is used to obtain the EEG data to be detected and mark the EEG data segments with abnormal quality, and the EEG quality assessment method of the present application can obtain a standardized assessment effect.
[0017] As a possible implementation of the first aspect, a secondary search is performed on the EEG data segment with abnormal quality in the single trial, and the electrooculogram quality of the EEG data segment with abnormal quality is searched to eliminate misjudgment due to the influence of electrooculogram.
[0018] From the above, by performing electrooculography evaluation or retrieval on EEG data segments with abnormal marking quality, misjudgment due to electrooculography can be eliminated, the utilization efficiency of experimental data can be improved, and duplication of work can be reduced.
[0019] As a possible implementation manner of the first aspect, the secondary search includes:
[0020] Extracting a single electrode waveform in the EEG data segment with abnormal quality of the single trial, and setting the drawing range of the single electrode waveform as the starting point and the end point;
[0021] Starting from the starting point of the waveform, searching for the pixel point of the waveform and ending at the end point, obtaining the position to be inspected;
[0022] The sites to be inspected are inspected one by one to obtain data abnormal sites.
[0023] From the above, the sites to be tested in the EEG data at the level of a single electrode trial are retrieved, and the abnormal positions affected by the electrooculogram are preliminarily screened to reduce the possibility of misjudgment and the amount of calculation.
[0024] As a possible implementation manner of the first aspect, the electrooculogram quality assessment is performed on waveforms of multiple electrodes, thereby assessing the electrooculogram quality of the overall EEG data.
[0025] From the above, by evaluating the electrooculographic quality of the overall EEG data using multiple electrode waveforms, a more comprehensive and accurate quality evaluation of the original EEG data can be obtained, reducing the possible bias caused by a single electrode evaluation.
[0026] As a possible implementation of the first aspect, the search is for a waveform diagram of an EEG data segment for quantifying abnormal quality of the single trial, specifically including:
[0027] Set the range size of the single search window to the stroke size of the waveform starting point, and set the step size to the recognition length;
[0028] Taking the input graphic area corresponding to the current search window position as the template image, setting three search directions of up, down and right, sliding the search window along the search directions by the step lengths respectively; recording the three input graphic areas of up, down and right corresponding to the search window as search results;
[0029] Matching the search results with the template image, and taking the search result with the highest matching value as the new current search window position;
[0030] All search results with the highest matching values and their positions are recorded, and search results whose vertical distance from the search result position to the starting point position is greater than a certain range are recorded in the to-be-checked set.
[0031] From the above, obtaining the position to be inspected by searching for matching values can reduce the difficulty of calculation, reduce the amount of calculation, and respond more quickly; since all positions of the image are traversed, it is not easy to cause omissions. Compared with filtering and other methods, it reduces the possibility of misjudgment and eliminates the complex operation of parameter setting.
[0032] As a possible implementation of the first aspect, the inspection of the site to be inspected specifically includes:
[0033] The coordinates (x n ,y n ) as the reference point, within the waveform drawing range, take the reference point as the starting point, and n -1 and x n +1 direction respectively to find a point that makes the absolute value of the EEG data pixel coordinate |y| the smallest; if the minimum absolute values are the same, then select the distance x n The coordinates of the selected points are respectively denoted as x n -a and x n +b; calculate the value of |ab|. If it is less than or equal to the set threshold, the retrieval result of the element is recorded as the data abnormality site; if it is greater than the set threshold, it is recorded as a non-abnormal site.
[0034] As mentioned above, by searching for spikes or mutations, we can obtain an accuracy close to that of manual inspection and reduce the uncertainty of manual methods.
[0035] As a possible implementation of the first aspect, the electrooculographic quality indicator PSN can be obtained by the following formula:
[0036]
[0037] Wherein, ∑SN is the number of data abnormal sites, and |SN| is the number of sites to be checked.
[0038] From the above, by using quantitative electrooculogram quality indicators, the EEG data quality assessment is made more standardized, intuitive and explainable. At the same time, it can be added to the original EEG data quality indicator evaluation system to form an objective quality evaluation quantitative result for further analysis.
[0039] The second aspect of the present application provides an electroencephalogram data quality assessment device, comprising:
[0040] The data acquisition and preprocessing module is used to acquire and preprocess the continuous raw EEG data under the stimulation of a specific induced task, mark the EEG data segments with abnormal quality; extract the single trial EEG data segments under the stimulation of the specific induced task; mark the single trial EEG data segments that have an intersection with the EEG data segments marked with abnormal quality as single trial EEG data segments with abnormal quality;
[0041] An electrooculogram (EOO) abnormality retrieval module is used to perform a secondary retrieval on the EEG data segment with abnormal quality of the single trial and calculate the EOO quality index;
[0042] An evaluation module is used to evaluate the electrooculogram quality at a single trial level according to the electrooculogram quality index; to correct the continuous raw EEG data in combination with the single trial event-related potential EEG data quality index; to conduct a comprehensive evaluation of the overall EEG data; and to perform quality control based on the comprehensive evaluation results.
[0043] A third aspect of the present application provides a computing device, comprising: a processor, and a memory on which program instructions are stored, and when the program instructions are executed by the processor, the processor executes the EEG data quality assessment method described in any one of the first aspects. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] Figure 1 is a flow chart of a first embodiment of the method for evaluating the quality of electroencephalogram data of the present application;
[0045] Figure 2 is a flow chart of a second embodiment of the method for evaluating the quality of electroencephalogram data of the present application;
[0046] Figure 3 is a schematic diagram of an EEG data quality assessment device provided in an embodiment of the present application;
[0047] Figure 4 is a structural schematic diagram of a computing device provided in an embodiment of the present application;
[0048] It should be understood that the size and shape of each block diagram in the above structural diagram are for reference only and should not constitute an exclusive interpretation of the embodiment of the present invention. The relative position and inclusion relationship between the blocks presented in the structural diagram are only schematic representations of the structural association between the blocks, and do not limit the physical connection method of the embodiment of the present invention. DETAILED DESCRIPTION
[0049] The technical solution provided by the present application is further described below with reference to the accompanying drawings and examples. It should be understood that the system structure and business scenarios provided in the examples of the present application are mainly to illustrate the possible implementation methods of the technical solution of the present application and should not be interpreted as the only limitation on the technical solution of the present application. It is known to those of ordinary skill in the art that with the evolution of the system structure and the emergence of new business scenarios, the technical solution provided by the present application is also applicable to similar technical problems.
[0050] It should be understood that the EEG data quality assessment scheme provided in the embodiments of the present application includes an EEG data quality assessment method, device and computing device. Since the principles of solving the problems in these technical solutions are the same or similar, some repetitions may not be repeated in the introduction of the following specific embodiments, but it should be regarded as that these specific embodiments have been referenced to each other and can be combined with each other.
[0051] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by technicians in the technical field of this application. In the event of any inconsistency, the meaning described in this specification or the meaning derived from the contents recorded in this specification shall prevail. In addition, the terms used herein are only for the purpose of describing the embodiments of the present application and are not intended to limit the present application. In order to accurately describe the technical content in this application and to accurately understand the present invention, the following explanations or definitions are given to the terms used in this specification before describing the specific embodiments:
[0052] 1) Reference Electrode Standardization Technique (REST): A mathematical technique that bridges the gap between a traditional reference electrode (e.g., a scalp point or average reference) and a theoretical zero reference (i.e., a reference point at infinity with a theoretically neutral potential). REST works by approximately converting the scalp EEG signal to a reference point at infinity, thus serving as an ideal neutral reference.
[0053] The EEG data quality assessment scheme provided in the embodiment of the present application can be pre-processed by the EEG data under the stimulation of a specific induced task, and the EEG data segment is evaluated for electrooculography quality at the trial level, and the data segment with abnormal quality mark during processing is further eliminated from the electrooculography quality interference; the electrooculography quality assessment index is added to the original EEG data quality assessment index system, the quality of the original EEG data is corrected and the quality is comprehensively evaluated, so as to perform quality control. This method evaluates the quality of electrooculography data at the trial level by an accurate, simple and efficient method, reduces pre-processing misjudgment, thereby objectively evaluating the comprehensive overall quality of EEG data and providing a method for quality control. The embodiment of the present application can be applied to the diagnosis and treatment of EEG data quality assessment in scientific research in the fields of psychology, neuroscience, medicine and other fields related to EEG. The embodiments of the present application are described in detail below with reference to the accompanying drawings.
[0054] The first embodiment of the present application provides a method for evaluating the quality of electroencephalogram data. Figure 1 , the implementation of each step of the method is specifically described, including steps S10-S40.
[0055] S10: collecting continuous raw EEG data under the stimulation of a specific induced task and performing preprocessing, marking EEG data segments with abnormal quality; extracting single trial EEG data segments under the stimulation of the specific induced task; marking the single trial EEG data segments that have an intersection with the EEG data segments marked with abnormal quality as single trial EEG data segments with abnormal quality.
[0056] In some embodiments, the specific induced tasks are commonly used induced tasks in the fields of psychology, neuroscience, and medicine, such as visual, visual, tactile, cognitive, emotional, motor, clinical, social, and other induced tasks, as well as a combination of multimodal tasks; specifically, they may include flash stimulation, picture stimulation, pure tone stimulation, work tasks, attention tasks, finger tapping, pain induction, facial recognition, etc. The specific induced tasks here refer to pre-set or selected induced tasks.
[0057] In some embodiments, continuous raw EEG data can be collected by a portable, clinical or research EGG device, which can be collected using wet electrodes or dry electrodes; such as using a head-mounted EEG cap containing 64 electrodes.
[0058] In some embodiments, preprocessing can be performed using tools such as MNE-Python, PyEDF, FieldTrip, or professional EEG data processing software; the preprocessing steps may include at least one of the following: importing data, electrode positioning, eliminating useless electrodes, re-referencing, filtering, reducing the sampling rate, marking specific induced tasks, marking bad segments, interpolating bad leads, removing artifacts, and saving data; among them, the imported data can be transmitted by wire or wirelessly; the data is stored in common standard formats such as EDF and BDF; electrode positioning can be determined by traditional electrode placement such as the 10-20 system, or with the help of other scanning cameras and other instruments; eliminating useless electrodes can remove electrodes for non-EEG signals such as electrooculogram, electrocardiogram, and electromyography to reduce subsequent analysis The workload of noise and artifacts in the experiment; the re-reference can adopt the methods of bilateral mastoid average reference, whole brain average reference, zero reference, etc., or use the code implementation methods such as REST re-reference; filtering can adopt high-pass filtering, low-pass filtering, notch filtering, etc. to remove noise or highlight signals of specific frequencies; if necessary, the sampling rate can be reduced to reduce the amount of data and improve the efficiency of calculating data; the EEG data can be marked according to the marker of the specific induced task involved in the experiment; the marked bad segment can be detected and marked according to the signal quality, data continuity, amplitude range, spectrum characteristics, etc.; the interpolation bad guide method can include direct interpolation, spherical spline interpolation, automatic interpolation, manual interpolation, etc.; artifact removal can preliminarily identify and remove electromyographic artifacts, ECG artifacts, etc.
[0059] In some embodiments, continuous EEG data are segmented into individual trials based on the markers of the marked EEG data, and each trial typically includes an event window, such as data from 200 milliseconds before stimulation to 600 milliseconds after stimulation; the length of the trial time window depends on the experimental design and research purpose; the processed trial data will be saved separately for further analysis.
[0060] In some embodiments, a baseline correction is performed after the trial is extracted to eliminate the effects of baseline drift.
[0061] In some embodiments, after preprocessing, it is determined whether each extracted single trial EEG data segment has any intersection with the data segment marked with quality abnormalities during the preprocessing process. If there is an intersection, the corresponding single trial EEG data segment is marked as having quality abnormalities.
[0062] S20: Perform a secondary search on the EEG data segments with abnormal quality of the single trial, and calculate the electrooculogram quality index; in some embodiments, when evaluating the EEG data of a single trial, at least one electrode data may be selected for evaluation, or a comprehensive evaluation may be performed based on the evaluation results of multiple electrode data; wherein the comprehensive evaluation may include visual inspection or quantifying the evaluation results by calculating the mean, median, or other statistical methods.
[0063] In some embodiments, the fluctuations caused by eye movements are usually manifested as sudden and large fluctuations, forming peaks or mutations on the waveform graph; the secondary retrieval is divided into two parts: searching and checking. The search is to find the sites in the waveform graph that deviate far from the baseline as the sites to be checked, and the check is to check the sites to be checked to determine whether the sites to be checked are peaks or mutations.
[0064] In some embodiments, the search for the site to be tested can be performed by quantifying the waveform graph of the single trial EEG data segment through an image matching method, and by setting the position of the input graphic sub-region and the single search sub-region, the graphic contents of the two are matched, and the graphics with high matching values can be used for subsequent searches until all positions on the waveform image are traversed once; wherein, the matching value can be calculated and compared by means of Euclidean distance, normalized cross-correlation, absolute error sum, square error sum, etc.; wherein, after quantization, a matrix formed by null values and pixel points can be formed, and the pixel sites can also be recorded by other methods.
[0065] In some embodiments, after traversing the pixel sites of the waveform graph obtained by the search, the position that deviates far from the baseline is selected as the site to be tested; the site to be tested can be obtained by means of a threshold. For example, after exceeding a certain threshold, there may be a possibility of a spike or mutation at the point; wherein the threshold can be determined by a combination of the mean and the standard deviation, and the threshold can be a percentage or a certain micro-floating value.
[0066] In some embodiments, when performing an inspection, a peak or mutation can be determined by obtaining the peak and trough morphology of the site to be inspected, or by analyzing the slope, amplitude, period and other signal information of the site to be inspected, and performing Fourier transform on the signal. The judgment can also be made by using a local anomaly detection algorithm, which is not limited here.
[0067] In some embodiments, the electrooculographic quality can be evaluated by the ratio of abnormal electrooculographic sites to all sites, or can be evaluated after calculation by other quantitative methods, which is not limited here.
[0068] In some embodiments, performing the same operation as the electrooculogram quality retrieval on the EEG data segments marked as abnormal after preprocessing can prevent misjudgment of abnormal quality data under the influence of electrooculogram.
[0069] S30: Evaluate the electrooculogram quality at a single trial level according to the electrooculogram quality index; and correct the continuous raw electroencephalogram data in combination with the single trial event-related potential electroencephalogram data quality index.
[0070] In some embodiments, the EOG quality is evaluated at a single trial level according to the EOG quality index, the EOG quality index can be graded, and the EEG data can be corrected according to the grading results and the required research task content. For example, the EOG quality index can be divided into four levels: 0%-39% is a high-quality level, with very few EOG artifacts and high data quality, which is suitable for all types of research; 40%-59% is a medium-quality level, with fewer EOG artifacts and better data quality, which is suitable for most research, but caution is required when performing high-precision analysis; 60%-79% is a low-quality level, with more EOG artifacts and average data quality, which is suitable for preliminary research or as reference data, and is not recommended for high-precision analysis; 80%-100% is an extremely low-quality level, with serious EOG artifacts and poor data quality, which is not recommended for any research.
[0071] In some embodiments, event-related potential EEG data quality indicators can also be combined to comprehensively judge whether a single trial EEG data segment is a data segment with abnormal quality, or to propose a single trial EEG data segment that is still of abnormal quality after a secondary retrieval; event-related potential EEG data quality indicators include signal-to-noise ratio, baseline stability, waveform matching, high-frequency noise, low-frequency drift, timing consistency and other indicators.
[0072] In some embodiments, when correcting continuous raw EEG data, EEG data segments with higher EEG influence can be excluded by calculating EEG quality indicators, and data with misjudged EEG quality in EEG data segments marked as abnormal can be re-added to the continuous EEG data.
[0073] In some embodiments, various psychology, neuroscience, and medical event-related potential studies can also be conducted directly on the corrected EEG data at the trial level; research methods may include statistical analysis methods such as t-test, regression analysis, and cluster analysis.
[0074] S40: Comprehensively evaluate the overall EEG data, and perform quality control based on the comprehensive evaluation results.
[0075] In some embodiments, the overall EEG data can be comprehensively evaluated from an empirical perspective in combination with the corrected results; a corresponding comprehensive evaluation model can also be constructed, such as a weight model, a machine learning model, etc. for comprehensive evaluation.
[0076] In some embodiments, the results of the comprehensive evaluation can be used for quality control, and the control method can be manual control or automatic control; specifically, quality control can retain data with higher comprehensive evaluations, and further review, process or exclude data with lower comprehensive evaluations; the data can also be marked for further processing; the experimental design can also be optimized and the data quality can be improved based on the evaluation results.
[0077] The second embodiment of the present application provides a method for evaluating the quality of EEG data. In this embodiment, the experimenter wears an EEG cap of an EEG acquisition device on his head, and the EEG cap includes 64 electrodes. Figure 2 As shown in the flowchart, the method provided by the second embodiment includes the following steps S200-220.
[0078] S200: Collecting continuous raw EEG data under specific induced task stimulation, and preprocessing, marking EEG data segments with abnormal quality. This step is as follows:
[0079] First, the EEG signal data obtained by 64 electrodes were collected using EEG acquisition equipment.
[0080] Then, the collected EEG data is preprocessed by detecting bad conductors, high-pass or notch filtering, artifact removal, bad conductor interpolation, REST re-reference and marking bad segments. In the preprocessing process, the data segments with abnormal quality will be automatically identified by the program or algorithm. Among them, some data segments with abnormal quality include data quality abnormalities caused by electrooculographic signal interference.
[0081] S205: Extracting each single trial EEG data segment about a specific induced task event from the preprocessed continuous EEG data. Among them, when the extracted single trial EEG data segment belongs to a data segment marked with abnormal quality during the preprocessing process, the single trial EEG data segment is marked as abnormal quality. This step is as follows:
[0082] Firstly, the continuous EEG data obtained by preprocessing are segmented according to m specific evoked task event labels and k event point lengths, and the EEG data segments of each single trial under the specific evoked task event are extracted.
[0083] Then, determine whether each extracted single trial EEG data segment has any intersection with the data segment marked with quality abnormalities during the preprocessing process. If there is an intersection, the corresponding single trial EEG data segment is marked as having quality abnormalities. S210: For each single trial EEG data segment marked as having quality abnormalities, calculate the electrooculogram quality index PSN, which is used to evaluate the degree to which the single trial EEG data segment is affected by the electrooculogram signal. It can also be understood that PSN is used to evaluate the degree to which the quality abnormality of the single trial EEG data segment is related to the electrooculogram signal.
[0084] Specifically, in this step, for each single trial EEG data segment marked as having abnormal quality, the following steps are performed:
[0085] 1) Based on the image matching method, the waveform of the single trial EEG data segment is quantified, and a matrix S formed by null values and pixel points is formed after quantization. The following sub-steps are included:
[0086] 1.1) For the extracted EEG data segment of the current single trial, extract the waveform image of the corresponding single electrode, and set the drawing range of the waveform image as the starting point and the end point.
[0087] 1.2) Starting from the starting point of the waveform, the range size of the single search window is set to the stroke size of the starting point of the waveform, and the step size is set to the recognition length; the input graphic area corresponding to the current search window can be defined as a template image, recorded as s1;
[0088] Take s1 as the anchor point, set the three search directions of up, down and right, slide the search window along the search directions by the step length respectively, and set the results of the three input graphic areas of up, down and right corresponding to the search window as slu, sld and slr.
[0089] Match slu, sld, slr with the template image s1 to generate three pixel locations slu pixel ,sld pixel ,slr pixel , select the site with the highest matching value among the three pixel sites as s2 pixel , s2 pixel The corresponding graphic area is recorded as s2;
[0090] 1.3) Then, take s2 as the anchor point, set the three search directions of up, down, and right, repeat the steps in 1.2 above, and obtain s3; and so on, until all the sites within the waveform drawing range are matched. At this point, a matrix S containing null values and pixel sites can be generated based on the results, and the waveform is quantized into matrix S.
[0091] 2) For the obtained matrix S, each site to be inspected is determined according to a set threshold value to form a set SN of sites to be inspected.
[0092] Specifically, in this step, the starting point of the matrix S corresponds to the starting point of the waveform graph, and the coordinates of the starting point are set to (0, 0), and the coordinates of the remaining values of the matrix are the corresponding micro-floating values of the waveform graph.
[0093] In this example, the threshold is set to the vertical coordinate [-50,50] based on the empirical value. Based on this threshold, elements with y values outside the [-50,50] area will be marked as sites to be inspected. These elements can be recorded as Sn1, Sn2...SnN, and the set of all these marked elements is recorded as SN, that is, the set of sites to be inspected.
[0094] 3) Next, the electrooculographic quality index PSN of the current single trial EEG data segment is calculated based on the set of sites to be tested SN, so as to determine the degree to which the single trial EEG data segment is affected by the electrooculographic signal. This step is specifically as follows:
[0095] Taking Sn1 as an example, assuming that the coordinates of Sn1 in the matrix S are (xn1,yn1), then look for xn1-a and xn1+b that minimize the |yn1| value in the directions of xn1-1 and xn1+1 (i.e., the left and right directions), and then calculate the value of |ab|. If |ab| is less than or equal to 10, the value of Sn1 is recorded as 1, indicating that the element Sn1 is affected by the electrooculogram signal; if |ab| is greater than 10, the value of Sn1 is recorded as 0, indicating that the element Sn1 is not affected by the electrooculogram signal. The 10 here is set based on the empirical value.
[0096] Repeat the above method to assign values to Sn2...SnN until all the sites to be inspected in the SN set have completed the corresponding assignment of 0 or 1.
[0097] Then, the electrooculographic quality index PSN of the single trial EEG data segment is calculated based on the following formula:
[0098]
[0099] Among them, ∑SN is the sum of the values of Sn1~SnN in the SN set, |SN| is the size of the SN set. In this example, since the SN set has N data, the value of |SN| here is N.
[0100] Therefore, using the above method, the electrooculographic quality index PSN can be calculated for each single trial EEG data segment marked as having abnormal quality.
[0101] S215: For each single trial EEG data segment marked as having abnormal quality, re-evaluate the abnormal quality according to each calculated electrooculographic quality index, wherein there are multiple evaluation methods, as illustrated below:
[0102] The first method is to directly evaluate the quality anomaly based on the PSN value, for example, as follows:
[0103] According to the PSN result range of 0%-100%, the PSN results can be evaluated according to the following four levels:
[0104] When the PSN value is 0%-39%, the EEG data segment of this single trial is of high quality, with very few electrooculographic artifacts and high data quality, which is suitable for all types of research;
[0105] When the PSN value is 40%-59%, the EEG data segment of this single trial is of medium quality, with fewer electrooculographic artifacts and good data quality, which is suitable for most studies, but caution is required when performing high-precision analysis;
[0106] When the PSN value is 60%-79%, the EEG data segment of this single trial is of low quality, with many electrooculogram artifacts and average data quality. It is suitable for preliminary research or as reference data, but not recommended for high-precision analysis.
[0107] When the PSN value is 80%-100%, the EEG data segment of this single trial is of extremely low quality, with serious electrooculographic artifacts and poor data quality, and is not recommended for any research.
[0108] The second method is to combine the PSN value with the conventional indicators of the quality of the relevant potential EEG data to evaluate the quality abnormality, which can be as follows:
[0109] Calculate common indicators of the quality of single-trial event-related potential EEG data, such as signal-to-noise ratio, baseline stability, waveform matching, high-frequency noise, low-frequency drift, or timing consistency.
[0110] The PSN indicator is added to the conventional indicator system, and each indicator can be assigned a different weight, so as to obtain the comprehensive quality indicator of the single trial EEG data segment after correction based on the PSN indicator. Based on the comprehensive quality indicator, it is re-judged whether the single trial EEG data segment is a quality abnormal data segment, which can be used to correct the misjudged EEG data segment with abnormal quality mark (for example, remove the quality abnormal mark), or to eliminate the single trial EEG data segment that is still of abnormal quality after re-judgment.
[0111] S220: For each single trial EEG data segment, including the re-evaluated single trial EEG data segment, correct the experimental data, or conduct a comprehensive evaluation of the overall EEG data.
[0112] The corrected experimental data here include correcting to normal data segments or identifying to abnormal data segments and eliminating them mentioned in the previous step, or may also include re-experimenting to obtain corresponding data.
[0113] Among them, the comprehensive evaluation of the overall EEG data here is to use existing algorithms to conduct a comprehensive evaluation of the overall EEG data based on the corrected results after correcting the experimental data. Existing algorithms, such as expert algorithms (i.e., empirical algorithms), build corresponding comprehensive evaluation models, such as weight models, machine learning models, etc. for comprehensive evaluation.
[0114] In addition, it can also include marking the data according to the results of the comprehensive evaluation, optimizing the experimental design, retaining the data with a higher comprehensive evaluation, and further reviewing, processing or excluding the data with a lower comprehensive evaluation, etc., to achieve quality control.
[0115] The third embodiment of the present application provides an EEG data quality assessment device, such as Figure 3 As shown, the device can be used to implement the EEG data quality assessment method in the above embodiment. Figure 3 As shown, the projection device comprises:
[0116] The data acquisition and preprocessing module is used to acquire and preprocess the continuous raw EEG data under the stimulation of a specific induced task, mark the EEG data segments with abnormal quality, and extract the EEG data segments of a single trial under the stimulation of the specific induced task;
[0117] The electrooculogram abnormality retrieval module performs secondary retrieval on the data segments of a single trial EEG data segment that are marked as having abnormal quality, and calculates the electrooculogram quality index;
[0118] An evaluation module is used to evaluate the electrooculogram quality at a single trial level according to the electrooculogram quality index; to correct the continuous raw EEG data in combination with the single trial event-related potential EEG data quality index; to conduct a comprehensive evaluation of the overall EEG data; and to perform quality control based on the comprehensive evaluation results.
[0119] Figure 4 900 is a schematic structural diagram of a computing device 900 provided in an embodiment of the present application. The computing device can execute each optional embodiment of the above method, and the computing device can be a terminal, or a chip or chip system inside the terminal. Figure 4 As shown, the computing device 900 includes: a processor 910 , a memory 920 , and a communication interface 930 .
[0120] It should be understood that Figure 4 The communication interface 930 in the computing device 900 shown may be used to communicate with other devices, and may specifically include one or more transceiver circuits or interface circuits.
[0121] The processor 910 may be connected to a memory 920. The memory 920 may be used to store the program code and data. Therefore, the memory 920 may be a storage unit inside the processor 910, or an external storage unit independent of the processor 910, or a component including a storage unit inside the processor 910 and an external storage unit independent of the processor 910.
[0122] Optionally, the computing device 900 may further include a bus. The memory 920 and the communication interface 930 may be connected to the processor 910 via the bus. The bus may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 4A line without an arrow is used to represent the bus, but this does not mean that there is only one bus or one type of bus.
[0123] It should be understood that in the embodiment of the present application, the processor 910 may adopt a central processing unit (CPU). The processor may also be other general-purpose processors, digital signal processors (DSP), application specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. Alternatively, the processor 910 may adopt one or more integrated circuits to execute relevant programs to implement the technical solutions provided in the embodiment of the present application.
[0124] The memory 920 may include a read-only memory and a random access memory, and provides instructions and data to the processor 910. A portion of the processor 910 may also include a nonvolatile random access memory. For example, the processor 910 may also store information on the device type.
[0125] When the computing device 900 is running, the processor 910 executes the computer-executable instructions in the memory 920 to perform any operation step of the above method and any optional embodiment thereof.
[0126] It should be understood that the computing device 900 according to the embodiment of the present application can correspond to the corresponding subjects in the methods according to the embodiments of the present application, and the above-mentioned and other operations and / or functions of each module in the computing device 900 are respectively for implementing the corresponding processes of each method of the present embodiment. For the sake of brevity, they will not be repeated here.
[0127] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0128] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0129] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0130] 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 on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0131] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0132] If the functions 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 this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
Claims
1. A method for evaluating the quality of electroencephalogram data, characterized in that: include: Collect and pre-process the continuous raw EEG data under specific induced task stimulation, and mark the EEG data segments with abnormal quality; extracting a single trial EEG data segment under the specific induced task stimulation; Marking the single trial EEG data segment that has an intersection with the EEG data segment marked with abnormal quality as the single trial EEG data segment with abnormal quality; The EEG data segments with abnormal quality in the single trial are searched for the second time, and the electrooculogram quality index is calculated; wherein the second time search is divided into two parts: searching and checking. The searching part is to find the sites in the waveform graph that deviate far from the baseline as the sites to be checked, and the checking part is to check the sites to determine whether the sites to be checked are spikes or mutations. Evaluate the electrooculogram quality at a single trial level according to the electrooculogram quality index; and correct the continuous raw electroencephalogram data in combination with the single trial event-related potential electroencephalogram data quality index; A comprehensive evaluation is performed on the overall EEG data, and quality control is performed based on the comprehensive evaluation results.
2. The method according to claim 1, characterized in that The continuous raw EEG data is a signal obtained by 64 electrodes; The preprocessing includes detecting bad conductors, high-pass or notch filtering, artifact removal, bad conductor interpolation, REST re-referencing and marking bad segments.
3. The method according to claim 1, characterized in that A secondary search is performed on the EEG data segment with abnormal quality in the single trial, and the electrooculogram quality of the EEG data segment with abnormal quality is searched to eliminate misjudgment due to the influence of electrooculogram.
4. The method according to claim 1, characterized in that The secondary search includes: Extracting a single electrode waveform in the EEG data segment with abnormal quality of the single trial, and setting the drawing range of the single electrode waveform as the starting point and the end point; Starting from the starting point of the waveform, searching for the pixel point of the waveform and ending at the end point, obtaining the position to be inspected; The sites to be inspected are inspected one by one to obtain data abnormal sites.
5. The method according to claim 4, characterized in that The electrooculogram quality evaluation is performed on the waveforms of multiple electrodes, thereby evaluating the electrooculogram quality of the overall EEG data.
6. The method according to any one of claims 4 to 5, characterized in that: The search is for quantifying the EEG data segment waveform of the single trial quality abnormality, specifically including: Set the range size of the single search window to the stroke size of the waveform starting point, and set the step size to the recognition length; Taking the input graphic area corresponding to the current search window position as the template image, setting three search directions of up, down and right, sliding the search window along the search directions by the step lengths respectively; recording the three input graphic areas of up, down and right corresponding to the search window as search results; Matching the search results with the template image, and taking the search result with the highest matching value as the new current search window position; All search results with the highest matching values and their positions are recorded, and search results whose vertical distance from the search result position to the starting point position is greater than a certain range are recorded in the to-be-checked set.
7. The method according to any one of claims 4 to 5, characterized in that: The inspection of the site to be inspected specifically includes: The coordinates corresponding to a certain point to be tested As the reference point, within the waveform drawing range, take the reference point as the starting point, and In each direction, find a pixel coordinate absolute value of the EEG data. The smallest point; if the absolute values of the smallest points found are the same, then the distance The closer point; the coordinates of the selected points are recorded as and ;calculate If the value is less than or equal to the set threshold, the search result of a certain site to be checked is recorded as the data abnormal site; if it is greater than the set threshold, it is recorded as a non-abnormal site.
8. The method according to any one of claims 4 to 5, characterized in that: The electrooculographic quality index PSN can be obtained by the following formula: in, is the number of abnormal data points, is the number of the sites to be inspected.
9. An electroencephalogram data quality assessment device, characterized in that: include: The data acquisition and preprocessing module is used to acquire and preprocess the continuous raw EEG data under the stimulation of a specific induced task, and mark the EEG data segments with abnormal quality; extracting a single trial EEG data segment under the specific induced task stimulation; An electrooculogram abnormality retrieval module is used to perform a secondary retrieval on a single trial EEG data segment that is marked as having abnormal quality, and calculate an electrooculogram quality index; An evaluation module is used to evaluate the electrooculogram quality at a single trial level according to the electrooculogram quality index; to correct the continuous raw EEG data in combination with the single trial event-related potential EEG data quality index; to conduct a comprehensive evaluation of the overall EEG data; and to perform quality control based on the comprehensive evaluation results.
10. A computing device, characterized in that include: processor, and A memory having program instructions stored thereon, wherein when the program instructions are executed by the processor, the processor executes the method for evaluating the quality of electroencephalogram data according to any one of claims 1 to 8.
Citation Information
Patent Citations
Magnetic resonance brain image based subject individual difference data relation analysis method
CN106667490A
Image quality evaluation method based on electroencephalogram signals and structural uncertainty
CN116468692A