A kind of electroencephalogramsignal signal analysis method that accuracy high practicability is strong

文档序号:1761920 发布日期:2019-12-03 浏览:13次 中文

阅读说明:本技术 一种准确性高实用性强的脑电信号分析方法 (A kind of electroencephalogramsignal signal analysis method that accuracy high practicability is strong ) 是由 朱厚杰 齐金鹏 刘佳伦 李娜 邹俊晨 于 2019-07-19 设计创作,主要内容包括:本发明主要涉及了一种准确性高实用性强的脑电信号分析方法。本发明中,首先采用时间序列数据流模型进行数据预处理,主要包括脑电时序数据的获取、数据缓冲区设置以及基于滑动窗口理论的数据分割;然后采用TSTKS算法对单个窗口的数据进行数据波动分析;寻找突变点搜索最优路径,进行突变点检测,窗口波动量的计算及归一化;最后采用波动向量模式匹配进行癫痫的预测和诊断,主要包括数据波动向量整合与再映射处理,基于模式匹配的癫痫快速分析、预测与诊断,以及专家知识库模板向量的智能学习与在线更新策略设计内容。(The invention mainly relates to a kind of electroencephalogramsignal signal analysis methods that accuracy high practicability is strong.In the present invention, data prediction, the main acquisition including brain electricity time series data, data buffer zone setting and the data segmentation based on sliding window theory are carried out using time series data flow model first;Then data fluctuations analysis is carried out using data of the TSTKS algorithm to single window;Mutation point search optimal path is found, Singularity detection, the calculating and normalization of window undulate quantity are carried out;The prediction and diagnosis of epilepsy are finally carried out using fluctuation vector pattern matching, it mainly include that data fluctuations vector is integrated and re-maps processing, the quick prediction of epilepsy and diagnosis and the intelligence learning of expert knowledge library template vector and online updating strategy design content based on pattern match.)

1. a kind of electroencephalogramsignal signal analysis method that accuracy high practicability is strong, which comprises the following steps:

Step 1 obtains eeg data to be detected, divides eeg data to be detected using sliding window theory, so that it is determined that Eeg data to be detected fluctuates matrix dimensionality size;

Step 2 analyzes eeg data using TSTKS algorithm, comprising the following steps:

The eeg data in each window that step 1 obtains is resolved into different frequency domain components with multistage Haar wavelet theory, Virtual medial fascicle is respectively added in each non-leaf nodes of existing binary search tree TcA and difference binary tree TcD, Mean value ternary tree TSTcA and difference ternary tree TSTcD are obtained, is sought using search strategy one, search strategy two and search strategy three The optimum search approach for looking for a difference ternary tree TSTcD or mean value ternary tree TSTcA brain electricity to be mutated, detects catastrophe point position, Calculate the undulate quantity of each window, in which: search strategy one and search strategy two are based respectively on statistical fluctuation and details fluctuation, search Rope strategy three establishes the position that catastrophe point is determined on the basis of search strategy one and search strategy two, it is assumed that mean value ternary tree Nonleaf node in the last one n omicronn-leaf grade of TSTcA strategically one and two detects, left and right side cotyledonary node Point cA0,2j-1And cA0,2jAnd two statistical variable SLAnd SRBy KS statistical definition are as follows:

In formula (1) and formula (2), Smn() indicates the statistical variable of unilateral cotyledon node;M=n=2k-2;N indicate normal data and Data to be tested total length;Fm() indicates normal data standard empirical distribution function;Gn() indicates accumulative point of data to be tested Cloth function;Xl={ X1,...,Xc};Xr={ Xc+1,...,XN};I () indicates probability density;

Maximum statistical discrepancy is that occur before catastrophe point occurs or later, in order to accurately calculate maximum statistical error, according to formula (1) and (2) are by statistical variable SLAnd SRIt is newly defined asWithThen have:

Indicate the limit on the left of the 2j-1 element in Z;Indicate the limit on the left of the 2j element in Z;

Statistical fluctuation S' is then calculatedLAnd S'R:

To introduce search strategy three, if max=(S'L,S'R)>C3(σ), C3(σ) indicates C3The value of (σ) can be according to conspicuousness water The value of flat σ is found in statistical form, then has provided max=(S' from one layer choosing of mean value ternary tree TSTcA leaf nodeL,S'R) leaf Node is as catastrophe point, and using this statistical fluctuation value as the undulate quantity of the window;Or from difference ternary tree TSTcD leaf node one Layer choosing has provided max=(S'L,S'R) leaf node as catastrophe point, and using this statistics details coefficients as the fluctuation of the window Amount.

2. a kind of electroencephalogramsignal signal analysis method that accuracy high practicability is strong as described in claim 1, which is characterized in that in institute Stating step 2 further includes later step 3:

The undulate quantity of each window is normalized, current window undulate quantity normalized transfer function such as formula (7) It is shown:

In formula, diFluctuation magnitude after indicating the normalization of current window;SiIndicate the current window obtained by the step 2 Undulate quantity;SmaxIndicate maximum fluctuation value in all windows.

3. a kind of electroencephalogramsignal signal analysis method that accuracy high practicability is strong as claimed in claim 2, which is characterized in that in institute Stating step 3 further includes later step 4:

Fluctuation magnitude after the normalization of each window is carried out to re-map processing, processing is mapped to [0,1,2,3,4,5], i.e., by brain Electric data fluctuations are divided into six grades, and setting normal brain activity electricity threshold fluctuations are 0.5, the wave lower than normality threshold after normalization Dynamic grade is all 0, stress normally to fluctuate under people's own biological electricity and environmental stimuli;[0.5,0.6],[0.6,0.7], [0.7,0.8], [0.8,0.9], [0.9,1.0] are respectively mapped to [1,2,3,4,5] five grades, when certain section fluctuates vector medium wave When dynamic element is all 0, it is believed that this section of eeg data is normal data.

4. a kind of electroencephalogramsignal signal analysis method that accuracy high practicability is strong as described in claim 1, which is characterized in that step In 1, data receiver buffer area is established for caching the eeg data, data receiver buffer area uses queue structure, new to be added The eeg data successively fall in lines sequentially in time from tail of the queue, when data buffering is completed, when into data handling procedure, delay The eeg data of punching is successively fallen out from head of the queue in chronological order again.

5. a kind of electroencephalogramsignal signal analysis method that accuracy high practicability is strong as described in claim 1, which is characterized in that step In 1, when dividing eeg data to be detected using sliding window theory, the width of sliding window is set as W, then each sliding window The number of eeg data in mouthful is W, then eeg data to be detected is divided into several wide sliding windows by sliding window In mouthful, quickly determine that eeg data fluctuates vector dimension size.

Technical field

The present invention relates to a kind of electroencephalogramsignal signal analysis method that accuracy high practicability is strong, belong to big data quickly analyze with Pattern match field.

Background technique

Brain diseases are a kind of principal diseases for threatening human life, its main feature is that high incidence, high disabled and height is dead Rate.With the rapid development of medical technology, the brain diagnostic techniques of many exquisitenesses is applied to clinic.

EEG signals are the bioelectrical signals of earliest human research and applying clinical medicine, when it reflects brain activity The variation of current potential after neuronal synapse is a kind of objective electrical activity of brain.Electroencephalogram (Electroencephalogram, referred to as EEG it is noninvasive, repeatable, quick, accurate) to have many advantages, such as.Although modern electroencephalography have developed rapidly in medical domain, It more tests vast electroencephalogram worker, clinician and constantly reinforces study to electroencephalogram knowledge, to enrich oneself clinic Technical ability improves diagnostic accordance rate.But with more and more patients and case, these all substantially increase the work of doctor Amount, so that spending the time on electroencephalogram excessive, and the accuracy diagnosed is also to vary with each individual.And epilepsy invasion is with prominent Hair property, it is desirable to which accurately prediction and diagnosis need to obtain a large amount of eeg datas.The eeg data of most of the time is all located among these In normal condition, only there is abnormal and mutation before and after epilepsy generation, and exception is difficult to capture during one's sickness.In face of magnanimity when Ordinal number evidence can waste plenty of time and energy to the processing of normal eeg data.

Summary of the invention

The object of the present invention is to provide a kind of electroencephalogramsignal signal analysis methods, to effectively filter the normal brain activity electricity number of redundancy According to quick positional mutation point, fluctuation vector is established.

In order to achieve the above object, the technical solution of the present invention is to provide a kind of brain telecommunications that accuracy high practicability is strong Number analysis method, which comprises the following steps:

Step 1 obtains eeg data to be detected, divides eeg data to be detected using sliding window theory, thus Determine eeg data fluctuation matrix dimensionality size to be detected;

Step 2 analyzes eeg data using TSTKS algorithm, comprising the following steps:

The eeg data in each window that step 1 obtains is resolved into different frequency domains point with multistage Haar wavelet theory Virtual medial fascicle, is respectively added to each non-leaf nodes of existing binary search tree TcA and difference binary tree TcD by amount In, mean value ternary tree TSTcA and difference ternary tree TSTcD are obtained, search strategy one, search strategy two and search strategy three are utilized Find the optimum search approach of a difference ternary tree TSTcD or the mutation of mean value ternary tree TSTcA brain electricity, detection mutation point It sets, calculates the undulate quantity of each window, in which: search strategy one and search strategy two are based respectively on statistical fluctuation and details wave Dynamic, search strategy three establishes the position that catastrophe point is determined on the basis of search strategy one and search strategy two, it is assumed that mean value three Nonleaf node in the last one n omicronn-leaf grade of fork tree TSTcA strategically one and two detects that left and right side is sub Leaf node cA0,2j-1And cA0,2jAnd two statistical variable SLAnd SRBy KS statistical definition are as follows:

In formula (1) and formula (2), Smn() indicates the statistical variable of unilateral cotyledon node;M=n=2k-2, 1≤j≤N/2k, 2≤k≤log2N;M=n=2k-2, N expression data to be tested total length;Fm() indicates that normal data standard empirical is distributed letter Number;Gn() indicates data to be tested Cumulative Distribution Function;Xl={ X1,...,Xc};Xr={ Xc+1,...,XN};I () is indicated Probability density;

Maximum statistical discrepancy is that occur before catastrophe point occurs or later, in order to accurately calculate maximum statistical error, root According to formula (1) and (2) by statistical variable SLAnd SRIt is newly defined asWithThen have:

In formula (3) and formula (4),Indicate the limit on the left of the 2j-1 element in Z;Indicate the 2j member in Z The limit on the left of element;

Statistical fluctuation S ' is then calculatedLAnd S 'R:

To introduce search strategy three, if max=(S 'L,S′R)>C3(σ), C3(σ) indicates C3The value of (σ) can be according to significant The value of the horizontal σ of property is found in statistical form, then has provided max=(S ' from one layer choosing of mean value ternary tree TSTcA leaf nodeL,S′R) Leaf node as catastrophe point, and using this statistical fluctuation value as the undulate quantity of the window;Or from difference ternary tree TSTcD leaf segment One layer choosing of point has provided max=(S 'L,S′R) leaf node as catastrophe point, and using this statistics details coefficients as the window Undulate quantity.

Preferably, further include step 3 after the step 2:

The undulate quantity of each window is normalized, current window undulate quantity normalized transfer function such as formula (7) shown in:

In formula, diFluctuation magnitude after indicating the normalization of current window;SiExpression is obtained current by the step 2 The undulate quantity of window;SmaxIndicate maximum fluctuation value in all windows.

Preferably, further include step 4 after the step 3:

Fluctuation magnitude after the normalization of each window is carried out to re-map processing, processing is mapped to [0,1,2,3,4,5], i.e., Eeg data fluctuation is divided into six grades, setting normal brain activity electricity threshold fluctuations are 0.5, are lower than normality threshold after normalization Fluctuation grade be all 0, for people's own biological electricity and environmental stimuli under stress normally fluctuate;[0.5,0.6],[0.6,0.7], [0.7,0.8], [0.8,0.9], [0.9,1.0] are respectively mapped to [1,2,3,4,5] five grades, when certain section fluctuates vector medium wave When dynamic element is all 0, it is believed that this section of eeg data is normal data.

Preferably, in step 1, data receiver buffer area is established for caching the eeg data, data receiver buffer area Using queue structure, the eeg data being newly added successively is fallen in lines from tail of the queue sequentially in time, when data buffering complete, into When entering data handling procedure, the eeg data of buffering is successively fallen out from head of the queue in chronological order again.

Preferably, in step 1, when dividing eeg data to be detected using sliding window theory, sliding window is set Width is W, then the number of the eeg data in each sliding window is W, then sliding window divides eeg data to be detected In the sliding window wide to several, quickly determine that eeg data fluctuates vector dimension size.

The present invention has the advantage that

First, in conjunction with sliding window theory, by time series data cutting to be detected be several subsegments, respectively to each subsegment into Row detection, calculates undulate quantity, has the features such as time-consuming less, relative error rate is minimum, hit rate highest;

Second, existing HWKS frame is compared, the present invention increases medial fascicle on the basis of binary search tree, to data The position of middle catastrophe point has better sensibility;

Third establishes three kinds of ternary tree search strategies, can quickly determine optimal search in conjunction with KS statistical theory is improved Route finds the time series data where abnormal point, quickly establishes fluctuation vector;

4th, the fluctuation element normalization for integrating each window re-maps composition fluctuation vector, with preset expert Library medium wave moving vector is matched, and can be realized the quick predict and diagnosis of the brain diseases such as epilepsy, while data may be implemented The dynamic in library updates.

Detailed description of the invention

Fig. 1 is the flow chart of the embodiment of the present invention

Fig. 2 is the buffer queue structure of the embodiment of the present invention;

Fig. 3 is the sliding window model of the embodiment of the present invention;

Fig. 4 is the TSTKS algorithm detection catastrophe point flow chart of the embodiment of the present invention;

Fig. 5 is that the embodiment of the present invention is based on multistage Harr wavelet transformation building TSTcA and TSTcD process;

Fig. 6 is the fluctuation vector establishment process of the embodiment of the present invention;

Fig. 7 is that undulate quantity re-maps foundation fluctuation vector schematic diagram.

Specific embodiment

With reference to the accompanying drawing, the present invention is further explained.It should be understood that these embodiments are merely to illustrate the present invention and do not have to In limiting the scope of the invention.In addition, it should also be understood that, after reading the content taught by the present invention, those skilled in the art can be with The present invention is made various changes or modifications, such equivalent forms equally fall within model defined by the application the appended claims It encloses.

A kind of electroencephalogramsignal signal analysis method that accuracy high practicability is strong provided by the invention is applied for insane below The present invention is further illustrated in epilepsy prediction and diagnosis.The present invention applies after epileptic prediction and diagnosis the following steps are included: first Data prediction, the main acquisition including brain electricity time series data, data buffer zone are first carried out using time series data flow model It is arranged and the data based on sliding window theory is divided;Then data are carried out using data of the TSTKS algorithm to single window Fluction analysis mainly includes that the different frequency domain components based on multistage Haar wavelet theory decompose, mean value ternary tree TSTcA and difference Ternary tree TSTcD building, and based on the search strategy design for improving KS statistical theory, the multi-path search of catastrophe point optimal path With quick detection;Mutation point search optimal path is found, Singularity detection, the calculating and normalization of window undulate quantity are carried out;Most The prediction and diagnosis for carrying out epilepsy using fluctuation vector pattern matching afterwards mainly include that data fluctuations vector is integrated and re-maps place Reason, the quick prediction of epilepsy based on pattern match and diagnosis and the intelligence learning of expert knowledge library template vector with Line more new strategy design content.

The present invention specifically includes the following steps:

(1) firstly, carrying out data prediction using time series data flow model, epileptics to be detected is obtained using EEG The eeg data of people, establishes data buffer zone.Divide data to be tested using sliding window theory, so that it is determined that epilepsy to be detected Eeg data fluctuates matrix dimensionality size.

Data buffer zone uses queue structure, as shown in Figure 2.The eeg data being newly added will sequentially in time successively from Tail of the queue is fallen in lines, and when data buffering is completed, when into data handling procedure, the eeg data in data buffer zone is again in chronological order Successively fall out from head of the queue.

According to sliding window theory, as W, i.e., each the eeg data Z for being N for length sets the width of sliding window The number of data is W in window, as shown in Figure 3.Then eeg data Z is divided into several wide sliding windows by sliding window It is interior, quickly determine eeg data abnormal point distribution and fluctuation vector dimension size.

(2) secondly, being analyzed using TSTKS algorithm eeg data, with multistage Haar wavelet theory by each window Data resolve into different frequency domain components in mouthful, increase virtual branch on the basis of existing HWKS algorithm binary tree, propose three and search Rope strategy detects catastrophe point position, calculates the undulate quantity of each window.

TSTKS theory of algorithm frame is as shown in Figure 4.TSTKS algorithm belongs to ternary tree search strategy, which is by HWKS Algorithm improvement can be roughly divided into two parts.First part is building mean value ternary tree TSTcA and difference ternary tree TSTcD, second part carry out the detection of catastrophe point with improved search strategy.

A) building of mean value ternary tree TSTcA and difference ternary tree TSTcD

Ternary tree is constructed on the basis of binary tree, as shown in figure 5, by adding on the basis of binary tree or so branch Adding medial fascicle, there are coincidence data section in the branch and left and right branch, the case where being overlapped to avoid cut-off and catastrophe point position, It is a kind of improvement to HWKS.Leaf node is directly from element in eeg data Z, and there are coincidence in medial fascicle and left and right branch Data segment is finally, that virtual medial fascicle is respectively added to each of existing mean value binary tree TcA and difference binary tree TcD is non- In leaf node, mean value ternary tree TSTcA and difference ternary tree TSTcD are obtained.

B) search strategy of the ternary tree based on improved KS statistical theory

In order to find the optimum search approach of a mean value ternary tree TSTcA or the mutation of difference ternary tree TSTcD brain electricity, TSTKS algorithm gives three search strategies.Search strategy one and search strategy two are based respectively on statistical fluctuation and details fluctuation, Search strategy three establishes the position that catastrophe point is determined on the basis of the first two strategy.

Assuming that the nonleaf node cA in the penultimate stage (the last one n omicronn-leaf grade) of mean value ternary tree TSTcAk,j(k=1) It is to be detected according to search strategy one and search strategy two, left and right side cotyledon node cA0,2j-1And cA0,2jAnd two A statistical variable SLAnd SRBy KS statistical definition are as follows:

In formula (1) and formula (2), Smn() indicates the statistical variable of unilateral cotyledon node;M=n=2k-2, m=2j-1 or 2j, 1≤j≤N/2k, 2≤k≤log2N;M=n=2k-2, n=N-m, N indicate data to be tested total length;Fm() indicates just Regular data standard empirical distribution function;Gn() indicates data to be tested Cumulative Distribution Function;Xl={ X1,...,Xc};Xr= {Xc+1,...,XN};I () indicates probability density;

In order to accurately calculate maximum statistical error, according to formula (1) and (2) by statistical variable SLAnd SRIt is newly defined asWithThen have:

In formula (3) and formula (4),Indicate the limit on the left of the 2j-1 element in Z;Indicate the 2j member in Z The limit on the left of element;

Therefore F can be recalculatedm(x) and Gn(x) the statistical fluctuation S ' betweenLAnd S 'R:

To introduce search strategy three, if max=(S 'L,S′R)>C3(σ), C3(σ) indicates C3The value of (σ) can be according to significant The value of the horizontal σ of property is found in statistical form, then has provided max=(S ' from one layer choosing of mean value ternary tree TSTcA leaf nodeL,S′R) Leaf node as catastrophe point, and using this statistical fluctuation value as the undulate quantity of the window;Or from difference ternary tree TSTcD leaf segment One layer choosing of point has provided max=(S 'L,S′R) leaf node as catastrophe point, and using this statistics details coefficients as the window Undulate quantity.By three above search strategy, can be obtained from the top root node in TSTcA or TSTcD to bottom leaf node The optimum search path of mutation is found, is realized to the quick of brain electricity time series data undulate quantity, it is accurate to calculate.

C) normalization of window undulate quantity

In order to improve the precision and discrimination of fluctuation vector, carries out compared with and weight convenient for different magnitude of undulate quantity, to every The undulate quantity of a window is normalized, shown in current window undulate quantity normalized transfer function such as formula (7):

In formula, diFluctuation magnitude after indicating the normalization of current window;SiExpression is obtained current by the step 2 The undulate quantity of window;SmaxIndicate maximum fluctuation value in all windows.

(3) finally, carrying out the prediction and diagnosis of epilepsy using fluctuation vector pattern matching.Integrate the undulate quantity of all windows The fluctuation vector and epilepsy specialists library system medium wave moving vector for forming 1 × m carry out pattern match, and normalized undulate quantity is carried out Re-map, integrate all sliding windows undulate quantity establish fluctuation vector, respectively with before epilepsy invasion in experts database, morbidity when, The vector of three parts template fluctuation after the onset carries out pattern match, according to whether the threshold value for reaching setting is realized the prediction of epilepsy and examined It is disconnected.Experts database is added together with state of an illness label in successful match data simultaneously, realizes that the dynamic of experts database updates, specifically includes following Step:

A) undulate quantity re-maps and fluctuates the foundation of vector

In order to improve fluctuation vector precision simultaneously also raising epilepsy different phase discrimination, each window is normalized Fluctuation magnitude afterwards carries out re-mapping processing.Processing is mapped to [0,1,2,3,4,5], i.e., eeg data fluctuation is divided into six Grade.It is 0.5 that normal brain activity electricity threshold fluctuations, which are arranged, and it is mainly people that the fluctuation grade lower than normality threshold after normalization, which is all 0, It stress normally be fluctuated under own biological electricity and environmental stimuli;[0.5,0.6],[0.6,0.7],[0.7,0.8],[0.8,0.9], [0.9,1.0] is respectively mapped to [1,2,3,4,5] five grades, when fluctuation element is all 0 in certain section of fluctuation vector, it is believed that This section of eeg data is normal data.

B) foundation and update in epilepsy specialists library

Occurs and used many standard EEG datas library in the world at present, the present invention chooses in existing database to be had Data in representative and authoritative several databases, establish the present invention relates to epilepsy specialists library.Epileptic condition experts database In include two databases, respectively normal eeg data and epileptic electroencephalogram (eeg) data.Wherein epileptic electroencephalogram (eeg) database is by being related to year The subject data composition of other representative selections such as age, gender and life habit, before the onset of mainly including, when morbidity, morbidity Three parts afterwards, as shown in Figure 7.Eeg data fluctuation before the onset has an obvious fluctuating, when morbidity eeg data fluctuation acutely, after the onset Fluctuation tendency slows down, and has and slightly rises and falls and tend to be normal.Without age and gender patient degree of fluctuation difference.Experts database is more It is newly a dynamic updating process, once data to be tested matching degree reaches setting threshold in fluctuation vector pattern matching process Value, is up to the fluctuation vector of threshold value together with the corresponding state of an illness label of this segment data, gender, at the age, the labels such as living habit are all It is added in the corresponding classification of experts database, realizes that the dynamic of experts database is updated and extended.

C) the fluctuation matched epileptic prediction of vector pattern and diagnosis

According to being fluctuated patient's essential information to be detected, vector and age in experts database are close, gender is identical respectively Before the onset of, when morbidity, the vector of three parts template fluctuation after the onset is matched.When matching, respectively from each different phase with Machine is selected one third data and is matched with data to be tested, if equal with the fluctuation Vectors matching of template selected by certain stage Value reaches given threshold, i.e., it is believed that patient's epilepsy to be detected is currently at this stage, while can become to epilepsy future development Gesture is made prediction.The prediction of epilepsy can be realized for the size of matching threshold setting again and made a definite diagnosis, threshold value is small can to carry out the state of an illness Prediction;Threshold value can carry out greatly the state of an illness and make a definite diagnosis.Once data to be tested reach given threshold, the fluctuation vector for being up to threshold value connects Herewith the corresponding state of an illness label of segment data is added in experts database, realizes that the dynamic of experts database updates.

13页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:基于脑-机接口的注意力调控系统

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!