CN115374812A - Signal feature extraction method for multi-feature fusion extraction of electroencephalogram signals - Google Patents
Signal feature extraction method for multi-feature fusion extraction of electroencephalogram signals Download PDFInfo
- Publication number
- CN115374812A CN115374812A CN202210924013.2A CN202210924013A CN115374812A CN 115374812 A CN115374812 A CN 115374812A CN 202210924013 A CN202210924013 A CN 202210924013A CN 115374812 A CN115374812 A CN 115374812A
- Authority
- CN
- China
- Prior art keywords
- matrix
- signal
- feature
- electroencephalogram
- extraction
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Classifications
-
- A—HUMAN NECESSITIES
- A61—MEDICAL OR VETERINARY SCIENCE; HYGIENE
- A61B—DIAGNOSIS; SURGERY; IDENTIFICATION
- A61B5/00—Measuring for diagnostic purposes; Identification of persons
- A61B5/16—Devices for psychotechnics; Testing reaction times ; Devices for evaluating the psychological state
- A61B5/165—Evaluating the state of mind, e.g. depression, anxiety
-
- A—HUMAN NECESSITIES
- A61—MEDICAL OR VETERINARY SCIENCE; HYGIENE
- A61B—DIAGNOSIS; SURGERY; IDENTIFICATION
- A61B5/00—Measuring for diagnostic purposes; Identification of persons
- A61B5/24—Detecting, measuring or recording bioelectric or biomagnetic signals of the body or parts thereof
- A61B5/316—Modalities, i.e. specific diagnostic methods
- A61B5/369—Electroencephalography [EEG]
- A61B5/372—Analysis of electroencephalograms
-
- A—HUMAN NECESSITIES
- A61—MEDICAL OR VETERINARY SCIENCE; HYGIENE
- A61B—DIAGNOSIS; SURGERY; IDENTIFICATION
- A61B5/00—Measuring for diagnostic purposes; Identification of persons
- A61B5/72—Signal processing specially adapted for physiological signals or for diagnostic purposes
- A61B5/7235—Details of waveform analysis
- A61B5/725—Details of waveform analysis using specific filters therefor, e.g. Kalman or adaptive filters
-
- A—HUMAN NECESSITIES
- A61—MEDICAL OR VETERINARY SCIENCE; HYGIENE
- A61B—DIAGNOSIS; SURGERY; IDENTIFICATION
- A61B5/00—Measuring for diagnostic purposes; Identification of persons
- A61B5/72—Signal processing specially adapted for physiological signals or for diagnostic purposes
- A61B5/7235—Details of waveform analysis
- A61B5/7264—Classification of physiological signals or data, e.g. using neural networks, statistical classifiers, expert systems or fuzzy systems
- A61B5/7267—Classification of physiological signals or data, e.g. using neural networks, statistical classifiers, expert systems or fuzzy systems involving training the classification device
Landscapes
- Health & Medical Sciences (AREA)
- Life Sciences & Earth Sciences (AREA)
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- Psychiatry (AREA)
- Veterinary Medicine (AREA)
- Animal Behavior & Ethology (AREA)
- Artificial Intelligence (AREA)
- Public Health (AREA)
- General Health & Medical Sciences (AREA)
- Surgery (AREA)
- Biophysics (AREA)
- Pathology (AREA)
- Biomedical Technology (AREA)
- Heart & Thoracic Surgery (AREA)
- Medical Informatics (AREA)
- Molecular Biology (AREA)
- Psychology (AREA)
- Signal Processing (AREA)
- Physiology (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Social Psychology (AREA)
- Child & Adolescent Psychology (AREA)
- Developmental Disabilities (AREA)
- Educational Technology (AREA)
- Hospice & Palliative Care (AREA)
- Evolutionary Computation (AREA)
- Fuzzy Systems (AREA)
- Mathematical Physics (AREA)
- Measurement And Recording Of Electrical Phenomena And Electrical Characteristics Of The Living Body (AREA)
Abstract
The invention discloses a signal feature extraction method for multi-element feature fusion extraction of an electroencephalogram signal, which comprises the following steps: acquiring electroencephalogram signal data and performing signal preprocessing on the electroencephalogram signal data to obtain a preprocessed signal; performing multi-dimensional feature extraction and matrix construction on the preprocessed signals to obtain an original feature matrix; performing fusion dimensionality reduction processing on the original feature matrix to obtain a final feature matrix; and inputting the final characteristic matrix into a pre-trained classification model for classification, and outputting a classification result. The invention overcomes the problem of incomplete electroencephalogram information in a single-domain feature extraction algorithm in the traditional algorithm, and effectively improves the classification performance. The invention can be widely applied to the field of signal processing.
Description
Technical Field
The invention relates to the field of signal processing, in particular to a signal feature extraction method for multi-element feature fusion extraction of electroencephalogram signals.
Background
The electroencephalogram signals are non-linear, non-stationary timing signals that can be detected by sensors of electrodes on the scalp, which are external manifestations of neuronal membrane potentials. The research based on the electroencephalogram signals can be used for emotion recognition, emotion recognition is mostly performed by extracting features of a single field at present, but the feature extraction of the single field only can contain partial information of the electroencephalogram signals, and the classification performance is not ideal.
Disclosure of Invention
The invention aims to provide a signal feature extraction method for multi-element feature fusion extraction of electroencephalogram signals, which solves the problem that electroencephalogram signal information in a single-domain feature extraction algorithm in the traditional algorithm is incomplete.
The first technical scheme adopted by the invention is as follows: a signal feature extraction method for multi-element feature fusion extraction of electroencephalogram signals comprises the following steps:
acquiring electroencephalogram signal data and performing signal preprocessing on the electroencephalogram signal data to obtain a preprocessed signal;
performing multi-dimensional feature extraction and matrix construction on the preprocessed signals to obtain an original feature matrix;
performing fusion dimensionality reduction processing on the original feature matrix to obtain a final feature matrix;
and inputting the final characteristic matrix into a pre-trained classification model for classification, and outputting a classification result.
Further, the step of acquiring the electroencephalogram signal data set and performing signal preprocessing on the electroencephalogram signal data set to obtain a preprocessed signal specifically includes:
acquiring electroencephalogram signal data;
carrying out noise separation processing on the electroencephalogram signal data based on an independent component analysis method to obtain a separated signal;
performing frequency screening processing on the separated signals based on a Butterworth band-pass filter to obtain screened signals;
and normalizing the screened signals to obtain preprocessed signals.
Further, the step of performing multi-dimensional feature extraction and matrix construction on the preprocessed signals to obtain an original feature matrix specifically includes:
performing feature extraction on the preprocessed signal on a time domain to obtain a time domain feature;
performing feature extraction on the preprocessed signal on a frequency domain based on an AR model power spectrum estimation method to obtain frequency domain features;
performing feature extraction on the preprocessed signal on a time-frequency domain based on a Hilbert-Huang transform method to obtain time-frequency domain features;
performing feature extraction on the preprocessed signals on a nonlinear domain based on nonlinear dynamics analysis to obtain nonlinear domain features;
performing feature extraction on the preprocessed signals on a space domain based on public space mode analysis to obtain space domain features;
and constructing a matrix according to the time domain characteristics, the frequency domain characteristics, the time-frequency domain characteristics, the nonlinear domain characteristics and the space domain characteristics to obtain an original characteristic matrix.
Further, the time domain features include standard deviation, root mean square, and mean of first order difference absolute values, and the non-linear features include approximate entropy, fuzzy entropy, and sample entropy.
Further, the step of performing fusion dimensionality reduction processing on the original feature matrix to obtain a final feature matrix specifically includes:
carrying out mean value removing processing on the original characteristic matrix to obtain a centralized matrix;
calculating a covariance matrix of the centralized matrix and decomposing an eigenvalue to obtain an eigenvalue and a corresponding eigenvector;
and sequencing the characteristic values and sequentially taking the characteristic vectors corresponding to the characteristic values of the preset number to construct a matrix to obtain a final characteristic matrix.
Further, the step of inputting the final feature matrix into a pre-trained classification model for classification and outputting a classification result pair specifically includes:
performing parameter optimization on the SVM-KNN classifier based on a particle swarm algorithm and a pre-constructed training set to obtain a pre-trained classification model;
calculating the distance between the sample to be tested and the optimal hyperplane based on a pre-trained classification model by taking the final characteristic matrix as input to obtain a sample distance;
comparing the sample distance with a preset threshold;
judging that the absolute value of the distance to the sample is smaller than a preset threshold value, classifying by adopting a KNN algorithm, and outputting a classification result;
and judging whether the absolute value of the distance to the sample is larger than or equal to a preset threshold value, classifying by adopting an SVM algorithm, and outputting a classification result.
Further, the calculation formula of the sample distance is as follows:
in the above formula, a i Is a Lagrangian multiplier, y i a i And k is a system constant and b is a constant term of the decision function in the SVM for the coefficient of the support vector in the decision function.
The second technical scheme adopted by the invention is as follows: a signal feature extraction system for multi-element feature fusion extraction of electroencephalogram signals comprises:
the preprocessing module is used for acquiring electroencephalogram signal data and preprocessing the electroencephalogram signal data to obtain preprocessed signals;
the characteristic extraction module is used for carrying out multi-dimensional characteristic extraction and matrix construction on the preprocessed signals to obtain an original characteristic matrix;
the dimension reduction module is used for carrying out fusion dimension reduction processing on the original feature matrix to obtain a final feature matrix;
and the classification module is used for inputting the final characteristic matrix into a pre-trained classifier for classification and outputting a classification result.
The third technical scheme adopted by the invention is as follows: a signal feature extraction device for multi-element feature fusion extraction of electroencephalogram signals comprises:
at least one processor;
at least one memory for storing at least one program;
when the at least one program is executed by the at least one processor, the at least one processor implements a signal feature extraction method for multi-feature fusion extraction of brain electrical signals as described above.
The method of the invention has the beneficial effects that: the invention can keep the information contained in the electroencephalogram signal as completely as possible through the multi-dimensional characteristics, effectively improve the classification performance of the classifier, make the calculation of the classifier simpler and more convenient through dimension reduction processing, and further improve the performance of the classifier.
Drawings
FIG. 1 is a flow chart of the steps of a signal feature extraction method for multi-element feature fusion extraction of electroencephalogram signals according to the present invention;
FIG. 2 is a block diagram of a signal feature extraction system for multi-feature fusion extraction of electroencephalogram signals.
Detailed Description
The invention is described in further detail below with reference to the figures and the specific embodiments. The step numbers in the following embodiments are provided only for convenience of illustration, the order between the steps is not limited at all, and the execution order of each step in the embodiments can be adapted according to the understanding of those skilled in the art.
As shown in fig. 1, the present invention provides a signal feature extraction method for multi-feature fusion extraction of electroencephalogram signals, which comprises the following steps:
s1, acquiring electroencephalogram signal data and preprocessing the electroencephalogram signal data to obtain preprocessed signals;
in particular, because the brain electrical signals have more noises and the information related to emotion is mostly concentrated in the frequency band of 0-50Hz, the brain electrical signal data needs to be preprocessed.
S1.1, acquiring electroencephalogram signal data;
s1.2, carrying out noise separation processing on the electroencephalogram signal data based on an independent component analysis method to obtain separated signals;
specifically, the eye electricity, the myoelectricity and other bioelectricity in human body in the electroencephalogram signal need to be separated, and at present, independent Component Analysis (ICA) can be adopted to separate the electroencephalogram signal from other noises for artifact removal.
S1.3, carrying out frequency screening processing on the separated signals based on a Butterworth band-pass filter to obtain screened signals;
specifically, the content in 0-50Hz in the brain electrical signals is reserved through a Butterworth band-pass filter.
S1.4, normalizing the screened signals to obtain preprocessed signals.
Specifically, the final normalization is performed by the self-contained mapminmax function in matlab.
S2, performing multi-dimensional feature extraction and matrix construction on the preprocessed signals to obtain an original feature matrix;
s2.1, performing feature extraction on the preprocessed signal on a time domain to obtain time domain features;
specifically, the time domain features are features of signal statistics of the electroencephalogram signals in a time domain, and the time domain features include standard deviation, root mean square, and mean of first-order difference absolute values.
The standard deviation is calculated as follows:
wherein x is i Is the value of the ith sample point in the time series, μ x The mean of the current time series, N being the length of the time series.
The root mean square is calculated as follows:
the calculation formula of the mean value of the first order difference absolute values is as follows:
s2.2, performing feature extraction on the preprocessed signals on a frequency domain based on an AR model power spectrum estimation method to obtain frequency domain features;
specifically, when extracting the electroencephalogram frequency domain features, the signals are mapped onto the corresponding frequency bands, and then the feature quantities on the frequency bands are obtained. As the electroencephalogram signal is a random signal, the frequency domain analysis and the feature extraction are carried out by adopting an AR model power spectrum estimation method. The AR model is also called autoregressive moving average model, and the estimation of model parameters requires solving the Y-W equation. For a general random signal, the AR model can be expressed in the form:
where y (n) is the nth sample value of the signal, p is the model order, a i Is the model coefficient and r (n) is the residual error of zero mean white noise.
System function of AR model:
model output power spectrum:
obtaining power spectrum of EEG signal by AR model method, calculating spectrum energy or power corresponding to each rhythm of EEG as frequency domain characteristics of theta, alpha, beta and gamma rhythms of EEG
S2.3, performing feature extraction on the preprocessed signals on a time-frequency domain based on a Hilbert-Huang transform method to obtain time-frequency domain features;
specifically, the Hilbert-yellow transform method mainly includes Empirical Mode Decomposition (EMD) and Hilbert Spectral Analysis (HSA).
Empirical mode decomposition (IMF) is to obtain an eigenmode function (IMF) which has the modulation characteristics of adaptivity, orthogonality, completeness, and IMF components. EMD satisfies the following two conditions:
1) The number of the signal extreme points is equal to or different from the zero point number by 1;
2) The local mean of the upper envelope of the signal, defined by the maxima, and the lower envelope, defined by the minima, is 0.
The EMD process is as follows:
1) All the maximum points and minimum points are found for the input signal.
2) Fitting the extreme value point and the minimum value point by adopting cubic splines, solving curves enveloped at the upper part and the lower part, calculating a mean function, and further solving the difference value h between the signal to be analyzed and the mean value.
3) Whether h meets the IMF condition is considered, if so, h is taken as the 1 st IMF; otherwise, the first two steps are carried out until the kth step meets the IMF condition, then the 1 st IMF is obtained, and the difference r between the original signal and the IMF is obtained.
4) Taking the difference r as a signal to be decomposed until the remaining r is a monotone signal or only one pole exists, and obtaining the following expression:
wherein x (t) is the original signal, C i (t) represents the IMF component obtained in the ith screening, N is the number of screening, R n (t) is the final residual component.
After the EMD process, hilbert Spectral Analysis (HSA) was performed, and Hilbert spectral transformation was performed for each IMF component as follows:
the analytic signal is:
wherein A is i (t) is an instantaneous amplitude, pi (t) is an instantaneous phase, and an instantaneous frequency omega can be further obtained i (t), namely:
the distribution of the signal amplitude in the time-frequency domain can be described, i.e. the Hilbert spectrum:
wherein Re is a real part.
The Instantaneous Energy Spectrum (IES) and the Marginal Energy Spectrum (MES) can be further found according to the above equation:
in the formula: [ omega ] 1 ,ω 2 ]Is the frequency range of the signal, [ t 2 ,t 2 ]Is the time range of the signal.
S2.4, performing feature extraction on the preprocessed signals on a nonlinear domain based on nonlinear dynamics analysis to obtain nonlinear domain features;
in particular, the non-linear characteristics include approximate entropy, fuzzy entropy, sample entropy.
The approximate entropy is adopted as one of the nonlinear dynamic features, has the advantages of quantifying the regularity and unpredictability of the EEG signal based on the approximate entropy, and can represent the complexity of the EEG signal and reflect the possibility of new information in the signal.
Approximate entropy processing of the pre-processed EEG signal x (t) is as follows:
(1) The time sequence of the N-dimensional original signal is sampled at equal time intervals to reconstruct m-dimensional vectors X (1), X (2), and (8230), and X (N-m +1, wherein Xi = [ u (i), u (i + 1), and (8230), and u (i + m-1) ].
(2) For 1,2, \8230;, N-m +1, the number of vectors satisfying the following conditions was counted
Wherein the condition to be satisfied by X (i) is d [ X (i), X (j)]≤r,d[X,X * ]Where u (a) is an element of the vector X, d represents the distance between two vectors X, j has a value l ≦ j ≦ N-m +1, j may be equal to i.
(3) Defining:
(4) The approximate entropy can be defined as:
ApEn=Φ m (r)-Φ m+1 (r)
in the formula, the parameter m =2 or m =3, m =3 is usually set, so that the dynamic evolution process of the system can be reconstructed in more detail; the value of r depends mainly on the application, r =0.2 × std (std is the standard deviation of the time series) is usually chosen.
The fuzzy entropy is adopted as one of nonlinear dynamics characteristics, the sample entropy advantage is inherited, the dependence on the time sequence length is reduced, and the method has better continuity and robustness and can be effectively used for the analysis of the electroencephalogram time sequence.
The processing steps of the fuzzy entropy on the preprocessed brain electric signal x (t) are as follows:
(1) Given an N-dimensional time series of signals, the same approximate entropy is used, defining the phase space dimension as m (m)<N-2) and r, reconstructed phase space: x (i) = [ u (i), u (i + 1), \8230;, u (i + m-1)]-u 0 (i)
(2) Introducing a fuzzy relation function A (x), and calculating:
(4) Then the fuzzy entropy can be defined as:
FuzzyEn=InΦ m (r)-InΦ m+1 (r)
the sample entropy is adopted as one of nonlinear dynamics characteristics, the sample entropy reflects the complexity of a time sequence, the probability of generating a new mode in the time sequence can be measured, and the larger the sample entropy value is, the larger the probability of generating the new mode is, and the more complex the sequence is. Under different emotional states, the degree of activation of the corresponding cerebral cortex is different, and the complexity of the brain electrical activity is also different. Therefore, the sample entropy characteristics can reflect the change of the emotional electroencephalogram.
The processing steps of the sample entropy on the preprocessed brain signal x (t) are as follows:
(1) The sample entropy and the approximate entropy of the first three steps are the same, wherein the approximate entropy isInstead, it is changed intoWill be provided withThe denominator N-m +1 of (1) is changed into N-m, and j is not equal to i.
(3) Let k = m +1, repeating the first and second steps of the sample entropy, one obtains:
(4) The sample entropy can be defined as:
s2.5, performing feature extraction on the preprocessed signals on a space domain based on public space mode analysis to obtain space domain features;
in particular, a one-to-one (OVO) method is adopted to carry out multi-classification expansion on the CSP algorithm. And performing space domain feature extraction on the electroencephalogram signals by adopting an OVO-CSP method. The method divides multi-classification into a plurality of two-classification problems, so the concrete implementation process of the CSP traditional algorithm for the two-classification is explained.
(1) And (3) solving a spatial covariance matrix of two types of data:
wherein E i A data matrix formed by converting two types of signals,representing the sum of the elements on the diagonal of the matrix.
(2) Calculating the average covariance matrix C of each class i And then summing:
(3) Performing eigenvalue decomposition and whitening treatment on the mixed spatial covariance matrix according to an expression to obtain S with the same eigenvector 1 And S 2 Then, for the feature vector S 1 And S 2 And respectively carrying out eigenvalue decomposition processing.
S 1 =Bλ 1 B T S 2 =Bλ 2 B T
B is S 1 And S 2 Common feature vectors, the sum of the feature values is 1.
(4) After a spatial filter is constructed, an electroencephalogram signal matrix E is filtered to obtain Z, and the Z is obtained i The following operations are performed as characteristic values:
wherein p =1,2, \ 8230;, 2m (2m < -n).
And S2.6, constructing a matrix according to the time domain characteristics, the frequency domain characteristics, the time-frequency domain characteristics, the nonlinear domain characteristics and the space domain characteristics to obtain an original characteristic matrix.
Specifically, all f are combined p Form the final characteristic moment F = { F = { F } 1 ,f 2 ,...f 2m And obtaining a group of electroencephalogram characteristics.
S3, performing fusion dimensionality reduction on the original feature matrix to obtain a final feature matrix;
specifically, the dimensionality of the combined feature vectors is high, so that the feature vectors are not beneficial to classifier identification, and the algorithm is not accurate and rapid enough, so that the PCA algorithm is selected to realize dimensionality reduction. The PCA uses a group of new vectors which are independent linearly and orthogonal mutually to characterize the original vector according to the principle of maximization of variance, the group of new vectors, namely principal components, are linear combination indexes of the original vector, and the implementation steps are as follows:
s3.1, aiming at an original characteristic matrix { x 1 ,x 2 ,…,x n Performing mean value removing processing to obtain a centralized matrix;
specifically, the de-centered matrix is represented as follows:
s3.2, calculating a covariance matrix C of the centralized matrix X and decomposing an eigenvalue to obtain an eigenvalue lambda and a corresponding eigenvector U;
specifically, λ is a diagonal matrix, representing the magnitude of the principal component variance.
And S3.3, sequencing the characteristic values and sequentially taking the characteristic vectors corresponding to the characteristic values of the preset number to construct a matrix to obtain a final characteristic matrix.
Specifically, λ is ordered: lambda [ alpha ] 1 ≥λ 2 ≥…≥λ d Taking eigenvectors corresponding to the first d' eigenvalues to form a projection matrix shape W = (u) 1 ,u 2 ,…,u d′ ). Wherein d' represents the dimensionality after dimensionality reduction and is determined by the cumulative contribution rate of each component, namely:
general arrangement C rate Greater than 85%.
And calculating a new characteristic quantity F = X W of the low dimensional space according to W. The new features processed by PCA represent useful information to the maximum extent, and feature vectors corresponding to d-d' feature values are removed, so that the sample sampling density is increased, a denoising effect is achieved to a certain extent, and the new features are better used as the input of a next classifier.
And S4, inputting the final characteristic matrix into a pre-trained classification model for classification, and outputting a classification result.
Specifically, an SVM-KNN classifier optimized by a particle swarm algorithm is selected in this embodiment.
S4.1, performing parameter optimization on the SVM-KNN classifier based on the particle swarm algorithm and a pre-constructed training set to obtain a pre-trained classification model;
specifically, in the PSO algorithm, the position and velocity of the particle in the n-dimensional space are continuously corrected by the particle in the particle swarm through the experience of the flight motion of the particle and the experience of the flight motion of the particle swarm, where n is the number of parameters that need to be optimized. The particle swarm updates its position and speed by tracking both individual extremum (Pbest) and global extremum (Gbest) values through constant iterative updating. The velocity and position update formula is as follows:
V id (t+1)=ω·V id (t)+c 1 r 1 (Pbest(t)-x id (t))+c 2 r 2 (Gbest(t)-x id (t))
X id (t+1)=X id (t)+V id (t+1)
wherein i is more than or equal to 1 and less than or equal to n, d is more than or equal to 1 and less than or equal to m, and m is the number of particles in the example group; omega is the inertial weight, c 1 、c 2 Is an acceleration constant, typically 2,r 1 、r 2 Is a random number between (0, 1) and t is an iterative algebra.
Before the PSO algorithm is performed to optimize the parameters, the ranges of some parameters need to be set: where ω is the inertial weight set to 1,c 1 、c 2 Set to 2, the maximum flight speed upper limit V max Set to 200, the total number of population particles is 50, and the maximum number of iterations is set to 10000. The parameters to be optimized are set to be in a range, the penalty factor C in the SVM algorithm and the parameter gamma of the RBF kernel function are set to be in a numerical range of (-100, 100), the parameter K in the KNN is selected to be in a numerical range of (0, 50), and the other threshold value omega for judging the distance is set to be in a range of (0.3, 0.8).
After the parameters are set, the parameter optimizing steps are as follows:
(1) The position and velocity of all particles are initialized.
(2) And calculating the classification precision of the SVM-KNN classification model under the current parameters, and calculating the fitness of each particle by taking the classification precision as a fitness function.
(3) And (4) updating the Pbest by comparing the current value with the individual extreme value of the searched fitness, comparing all the Pbest, selecting the best overall extreme value Gbest from the Pbest, and updating the Gbest.
(4) For each update, the SVM penalty factor C is reset, so that a larger research space is created for the particles, and the particles are prevented from falling into a local area with the current optimal value.
(5) The velocity and position of the particles are updated according to the velocity and position update formula mentioned above.
(6) When the maximum iteration times are reached, outputting an optimal parameter; otherwise, returning to the step (2).
And after the parameters of the SVM-KNN classification model are adjusted and optimized through a PSO algorithm, a group of optimal parameters are obtained, and the classification model is set according to the parameters.
And setting a penalty factor C of the SVM algorithm and a parameter gamma of a kernel function, a K value in the KNN algorithm and a threshold omega in the SVM-KNN algorithm by depending on the optimal parameter searched by the PSO algorithm.
S4.2, calculating the distance between the sample to be measured and the optimal hyperplane based on the pre-trained classification model to obtain a sample distance;
specifically, the distance is calculated in the classification model herein by the following formula:
in the above formula, a i Is a Lagrangian multiplier, y i a i And k is a system constant and b is a constant term of the decision function in the SVM for the coefficient of the support vector in the decision function.
The distance of the judgment is determined by considering a set threshold value, the smaller the threshold value is, the greater the proportion of the SVM algorithm in the fusion algorithm is, the algorithm is more biased to the SVM algorithm as a whole, and when the threshold value is 0, the fusion algorithm is equivalent to the SVM algorithm; on the contrary, the larger the threshold value is, the more the proportion of the improved KNN algorithm in the fusion algorithm is, and when the threshold value is larger than infinity, the algorithm is equivalent to the KNN classification algorithm.
S4.3, comparing the sample distance with a preset threshold value;
s4.4, judging that the absolute value of the distance from the sample is smaller than a preset threshold, classifying by adopting a KNN algorithm, and outputting a classification result;
specifically, g (x) is compared with a threshold value ω, if | g (x) | < ω, the sample point can be regarded as a sample point which is close to the optimal hyperplane, classification is performed by adopting a KNN algorithm, distances between the sample point to be detected and all feature vectors are calculated, the sample points with the minimum K distances are selected, and the corresponding classes of the sample points are counted, wherein the class of the sample to be detected is the same as the class with high occurrence probability.
And S4.5, judging that the absolute value of the distance from the sample to the sample is larger than or equal to a preset threshold value, classifying by adopting an SVM algorithm, and outputting a classification result.
Specifically, if | g (x) | ω, this sample point may be regarded as a sample point farther from the optimal hyperplane, and classification is performed by using an SVM algorithm in which F (x) = sgn (g (x)) is calculated to obtain a classification category.
The invention provides a novel signal classification method, namely a PSO-based improved SVM-KNN classification algorithm, which solves the problem that the classification of an SVM algorithm is inaccurate when facing a sample point which is closer to a hyperplane by fusing an SVM and the improved KNN algorithm. Meanwhile, the PSO algorithm is used for optimizing the traditional SVM-KNN algorithm, the optimal parameters of the SVM-KNN classifier are searched, the classification performance of the system is improved, and the emotion classification efficiency is greatly improved; the invention adopts the characteristics of time domain, frequency domain, time-frequency domain, nonlinearity and space domain to extract the characteristics of the electroencephalogram signal, and completely retains the information contained in the electroencephalogram signal as far as possible. And calculating the contribution rate of each feature by PCA, eliminating all features with the contribution rate lower than 85%, and constructing a new feature matrix, so that the information in the signal can be retained to the maximum extent, and the calculation efficiency of the classifier can be improved.
As shown in fig. 2, a signal feature extraction system for multi-feature fusion extraction of electroencephalogram signals includes:
the preprocessing module is used for acquiring electroencephalogram signal data and preprocessing the electroencephalogram signal data to obtain preprocessed signals;
the characteristic extraction module is used for carrying out multi-dimensional characteristic extraction and matrix construction on the preprocessed signals to obtain an original characteristic matrix;
the dimension reduction module is used for carrying out fusion dimension reduction processing on the original feature matrix to obtain a final feature matrix;
and the classification module is used for inputting the final characteristic matrix into a pre-trained classifier for classification and outputting a classification result.
The contents in the above method embodiments are all applicable to the present system embodiment, the functions specifically implemented by the present system embodiment are the same as those in the above method embodiment, and the beneficial effects achieved by the present system embodiment are also the same as those achieved by the above method embodiment.
A signal feature extraction device for multi-element feature fusion extraction of electroencephalogram signals comprises:
at least one processor;
at least one memory for storing at least one program;
when the at least one program is executed by the at least one processor, the at least one processor is caused to implement the signal feature extraction method for multi-component feature fusion extraction of an electroencephalogram signal as described above.
The contents in the above method embodiments are all applicable to the present apparatus embodiment, the functions specifically implemented by the present apparatus embodiment are the same as those in the above method embodiments, and the advantageous effects achieved by the present apparatus embodiment are also the same as those achieved by the above method embodiments.
A storage medium having stored therein instructions executable by a processor, the storage medium comprising: the processor-executable instructions, when executed by the processor, are for implementing a signal feature extraction method for multi-feature fusion extraction of electroencephalogram signals as described above.
The contents in the above method embodiments are all applicable to the present storage medium embodiment, the functions specifically implemented by the present storage medium embodiment are the same as those in the above method embodiments, and the advantageous effects achieved by the present storage medium embodiment are also the same as those achieved by the above method embodiments.
While the invention has been described with reference to a preferred embodiment, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the invention as defined by the appended claims.
Claims (7)
1. A signal feature extraction method for multi-element feature fusion extraction of an electroencephalogram signal is characterized by comprising the following steps:
acquiring electroencephalogram signal data and performing signal preprocessing on the electroencephalogram signal data to obtain a preprocessed signal;
performing multi-dimensional feature extraction and matrix construction on the preprocessed signals to obtain an original feature matrix;
performing fusion dimensionality reduction processing on the original feature matrix to obtain a final feature matrix;
and inputting the final characteristic matrix into a pre-trained classification model for classification, and outputting a classification result.
2. The method for extracting signal features of multi-feature fusion extraction of electroencephalogram signals according to claim 1, wherein the step of obtaining an electroencephalogram signal data set and performing signal preprocessing on the electroencephalogram signal data set to obtain a preprocessed signal specifically comprises:
acquiring electroencephalogram signal data;
carrying out noise separation processing on the electroencephalogram signal data based on an independent component analysis method to obtain a separated signal;
performing frequency screening processing on the separated signals based on a Butterworth band-pass filter to obtain screened signals;
and normalizing the screened signals to obtain preprocessed signals.
3. The method for extracting signal features of multi-feature fusion extraction of electroencephalogram signals according to claim 2, wherein the step of performing multi-dimensional feature extraction and matrix construction on the preprocessed signals to obtain an original feature matrix specifically comprises:
performing feature extraction on the preprocessed signals on a time domain to obtain time domain features;
performing feature extraction on the preprocessed signal on a frequency domain based on an AR model power spectrum estimation method to obtain frequency domain features;
performing feature extraction on the preprocessed signal on a time-frequency domain based on a Hilbert-Huang transform method to obtain time-frequency domain features;
performing feature extraction on the preprocessed signals on a nonlinear domain based on nonlinear dynamics analysis to obtain nonlinear domain features;
performing feature extraction on the preprocessed signals on a space domain based on public space mode analysis to obtain space domain features;
and constructing a matrix according to the time domain characteristics, the frequency domain characteristics, the time-frequency domain characteristics, the nonlinear domain characteristics and the space domain characteristics to obtain an original characteristic matrix.
4. The method for extracting signal features of multi-feature fusion extraction of electroencephalogram signals according to claim 3, wherein the time-domain features comprise standard deviation, root mean square, mean of first-order difference absolute values, and the non-linear features comprise approximate entropy, fuzzy entropy, and sample entropy.
5. The method for extracting signal features through multi-feature fusion extraction of electroencephalogram signals according to claim 3, wherein the step of performing fusion dimensionality reduction processing on the original feature matrix to obtain a final feature matrix specifically comprises the following steps:
carrying out mean value removing processing on the original characteristic matrix to obtain a centralized matrix;
calculating a covariance matrix of the centralized matrix and decomposing an eigenvalue to obtain an eigenvalue and a corresponding eigenvector;
and sequencing the characteristic values and sequentially taking the characteristic vectors corresponding to the characteristic values of the preset number to construct a matrix to obtain a final characteristic matrix.
6. The method for extracting signal features through multi-feature fusion extraction of electroencephalogram signals according to claim 5, wherein the step of inputting the final feature matrix into a pre-trained classification model for classification and outputting a classification result specifically comprises:
performing parameter optimization on the SVM-KNN classifier based on a particle swarm algorithm and a pre-constructed training set to obtain a pre-trained classification model;
calculating the distance between the sample to be tested and the optimal hyperplane based on a pre-trained classification model by taking the final characteristic matrix as input to obtain a sample distance;
comparing the sample distance with a preset threshold value;
judging that the absolute value of the distance to the sample is smaller than a preset threshold value, classifying by adopting a KNN algorithm, and outputting a classification result;
and judging whether the absolute value of the distance to the sample is larger than or equal to a preset threshold value, classifying by adopting an SVM algorithm, and outputting a classification result.
7. The method for extracting signal features of multi-feature fusion extraction of electroencephalogram signals according to claim 6, wherein the calculation formula of the sample distance is as follows:
in the above formula, a i Is a Lagrangian multiplier, y i a i And k is a system constant and b is a constant term of the decision function in the SVM for the coefficient of the support vector in the decision function.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210924013.2A CN115374812A (en) | 2022-08-02 | 2022-08-02 | Signal feature extraction method for multi-feature fusion extraction of electroencephalogram signals |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210924013.2A CN115374812A (en) | 2022-08-02 | 2022-08-02 | Signal feature extraction method for multi-feature fusion extraction of electroencephalogram signals |
Publications (1)
Publication Number | Publication Date |
---|---|
CN115374812A true CN115374812A (en) | 2022-11-22 |
Family
ID=84062824
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210924013.2A Pending CN115374812A (en) | 2022-08-02 | 2022-08-02 | Signal feature extraction method for multi-feature fusion extraction of electroencephalogram signals |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115374812A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116808391A (en) * | 2023-06-29 | 2023-09-29 | 北京理工大学 | Sleep awakening method and system based on physiological signal decoding |
CN117338313A (en) * | 2023-09-15 | 2024-01-05 | 武汉纺织大学 | Multi-dimensional characteristic electroencephalogram signal identification method based on stacking integration technology |
CN117860200A (en) * | 2024-01-10 | 2024-04-12 | 山东宝德龙健身器材有限公司 | Feature analysis method and terminal for Alzheimer's disease based on peripheral blood and electroencephalogram information |
-
2022
- 2022-08-02 CN CN202210924013.2A patent/CN115374812A/en active Pending
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116808391A (en) * | 2023-06-29 | 2023-09-29 | 北京理工大学 | Sleep awakening method and system based on physiological signal decoding |
CN116808391B (en) * | 2023-06-29 | 2023-12-26 | 北京理工大学 | Sleep awakening method and system based on physiological signal decoding |
CN117338313A (en) * | 2023-09-15 | 2024-01-05 | 武汉纺织大学 | Multi-dimensional characteristic electroencephalogram signal identification method based on stacking integration technology |
CN117338313B (en) * | 2023-09-15 | 2024-05-07 | 武汉纺织大学 | Multi-dimensional characteristic electroencephalogram signal identification method based on stacking integration technology |
CN117860200A (en) * | 2024-01-10 | 2024-04-12 | 山东宝德龙健身器材有限公司 | Feature analysis method and terminal for Alzheimer's disease based on peripheral blood and electroencephalogram information |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN115374812A (en) | Signal feature extraction method for multi-feature fusion extraction of electroencephalogram signals | |
CN109389059B (en) | P300 detection method based on CNN-LSTM network | |
CN110680313B (en) | Epileptic period classification method based on pulse group intelligent algorithm and combined with STFT-PSD and PCA | |
CN108256629B (en) | EEG signal unsupervised feature learning method based on convolutional network and self-coding | |
CN111310570B (en) | Electroencephalogram signal emotion recognition method and system based on VMD and WPD | |
Gnanasivam et al. | Fingerprint gender classification using wavelet transform and singular value decomposition | |
CN106963369B (en) | Electroencephalogram relaxation degree identification method and device based on neural network model | |
CN110472649B (en) | Electroencephalogram emotion classification method and system based on multi-scale analysis and integrated tree model | |
CN104771163A (en) | Electroencephalogram feature extraction method based on CSP and R-CSP algorithms | |
CN111797674B (en) | MI electroencephalogram signal identification method based on feature fusion and particle swarm optimization algorithm | |
CN105913066B (en) | A kind of digitlization lungs sound feature dimension reduction method based on Method Using Relevance Vector Machine | |
CN105266804B (en) | A kind of brain-electrical signal processing method based on low-rank and sparse matrix decomposition | |
CN114533086A (en) | Motor imagery electroencephalogram decoding method based on spatial domain characteristic time-frequency transformation | |
CN112990008B (en) | Emotion recognition method and system based on three-dimensional characteristic diagram and convolutional neural network | |
CN104504407A (en) | Electronic nose feature selection optimization method on basis of multiple Fisher kernel discriminant analysis | |
CN117503057B (en) | Epileptic seizure detection device and medium for constructing brain network based on high-order tensor decomposition | |
CN106503733B (en) | The useful signal recognition methods clustered based on NA-MEMD and GMM | |
CN111310656A (en) | Single motor imagery electroencephalogram signal identification method based on multi-linear principal component analysis | |
Jinliang et al. | EEG emotion recognition based on granger causality and capsnet neural network | |
CN113536882A (en) | Multi-class motor imagery electroencephalogram signal feature extraction and classification method | |
Hwaidi et al. | A noise removal approach from eeg recordings based on variational autoencoders | |
CN106923825B (en) | Electroencephalogram relaxation degree identification method and device based on frequency domain and phase space | |
Cai et al. | EEG-based emotion recognition using multiple kernel learning | |
CN116982993B (en) | Electroencephalogram signal classification method and system based on high-dimensional random matrix theory | |
Gurve et al. | Deep learning of EEG time–frequency representations for identifying eye states |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |