CN115844421B - Electroencephalogram emotion recognition method and equipment based on fractional Fourier transform - Google Patents
Electroencephalogram emotion recognition method and equipment based on fractional Fourier transform Download PDFInfo
- Publication number
- CN115844421B CN115844421B CN202211439327.XA CN202211439327A CN115844421B CN 115844421 B CN115844421 B CN 115844421B CN 202211439327 A CN202211439327 A CN 202211439327A CN 115844421 B CN115844421 B CN 115844421B
- Authority
- CN
- China
- Prior art keywords
- electroencephalogram
- emotion
- fourier transform
- fractional fourier
- signal
- 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.)
- Active
Links
Images
Classifications
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D30/00—Reducing energy consumption in communication networks
- Y02D30/70—Reducing energy consumption in communication networks in wireless communication networks
Landscapes
- Measurement And Recording Of Electrical Phenomena And Electrical Characteristics Of The Living Body (AREA)
Abstract
The invention relates to an electroencephalogram emotion recognition method and equipment based on fractional Fourier transform, comprising the following steps: selecting single-channel brain electrical signals under different emotions; carrying out sectional processing on each single-channel electroencephalogram signal; processing each segmented electroencephalogram signal by a fractional Fourier transform method to obtain transformed electroencephalogram signals; extracting emotion characteristics of each section of transformed electroencephalogram signals respectively, and extracting maximum values, average values, supporting area widths, energy, power, differential entropy and variance under different emotions respectively; and establishing an emotion recognition model by adopting an SVM algorithm and emotion characteristics. The method can capture the emotion characteristics of the electroencephalogram signals in the time domain and the frequency domain at the same time, is beneficial to emotion recognition of the electroencephalogram signals, and can perform emotion recognition by adopting the electroencephalogram signals on the single channel Cz.
Description
Technical Field
The invention belongs to the technical field of emotion recognition, and particularly relates to an electroencephalogram emotion recognition method based on fractional Fourier transform.
Background
Emotion perception is an important cognitive ability of human beings in social interaction, but a great deal of recognition difficulty exists in obtaining emotion perception nowadays because emotion has complexity and is easily interfered and influenced by individual subjective factors. Because electroencephalogram signals are not influenced by subjective factors and can shield external interference, research on electroencephalogram signal emotion recognition is also increasingly focused.
Although there are many methods applied to emotion recognition of an electroencephalogram signal, for example, fourier transform (FFT), short-time fourier transform (STFT), independent component analysis, wavelet transform, and the like. However, since these methods only analyze the electroencephalogram signals from a specific transformation domain, they fail to contain electroencephalogram information with different dimensions, and thus the ability of sensing and recognizing emotion is still lacking.
Disclosure of Invention
The invention aims to provide an electroencephalogram emotion recognition method and equipment based on fractional Fourier transform, which can improve the characteristic representation capability of an electroencephalogram signal on a time-frequency domain and improve emotion recognition effect;
in order to achieve the above purpose, the invention adopts the following technical scheme:
an electroencephalogram emotion recognition method based on fractional Fourier transform comprises the following steps:
selecting single-channel brain electrical signals under different emotions;
carrying out sectional processing on each single-channel electroencephalogram signal;
processing each segmented electroencephalogram signal by a fractional Fourier transform method to obtain transformed electroencephalogram signals;
extracting emotion characteristics of each segment of transformed EEG signal respectively, extracting emotion characteristics under different emotions respectively,
the emotion characteristics comprise the maximum value, the mean value, the supporting area width, the differential entropy, the variance, the energy and the power of the electroencephalogram signals;
and an emotion recognition model is established by adopting an SVM algorithm and emotion characteristics, so that emotion type recognition of the electroencephalogram signals under different emotions is realized.
Preferably, the single-channel electroencephalogram signal is an electroencephalogram signal on a Cz channel.
Preferably, the segmentation process includes the steps of:
setting the segment length as the value of the sampling rate, obtaining the number of segments of the electroencephalogram signal according to the total length of the electroencephalogram signal, wherein the number of segments is the total length of the electroencephalogram signal divided by the segment length, and if the total length cannot be divided by the segment length, carrying out zero padding on the residual electroencephalogram signal which is not divided so as to make the number of segments be an integer.
Preferably, in the fractional fourier transform method, for the time domain electroencephalogram signal f (t), the fractional fourier transform of the p-order can be expressed as:
wherein (1) K is p (u,t)=A α exp[jπ(u 2 cotα-2utcscα+t 2 cota) is a kernel function,alpha = ppi/2, p is not equal to 2n, n is an integer, alpha represents the transformation angle of the brain electrical signal from the time domain to the frequency domain, and the value range of alpha is [0,1]。
Preferably, said α=0.4.
Preferably, the maximum value is characterized by the maximum value in each section of transformed electroencephalogram signals;
the mean value characteristic is the mean value of the brain electrical signals after each section of transformation;
the support region width feature
Wherein (2) formula f p (M) represents the brain electrical value at the mth sampling point, M is the total sampling point number;
said differential entropy
Wherein, sigma in the formula (3) represents a variance value in the electroencephalogram signal;
the variance feature
Wherein n is the total sampling point number in the formula (4), M represents the average amplitude of n electroencephalogram signals,
the energy characteristics
Wherein s (N) is an electroencephalogram signal value in the formula (5), N is the number of electroencephalogram signal sampling points,
the power characteristics
Wherein, s (N) is an electroencephalogram signal value in the formula (6), and N is the number of electroencephalogram signal sampling points.
According to another aspect of the present invention, there is also provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs steps in a method for identifying brain emotion based on fractional fourier transform.
According to another aspect of the present invention, there is also provided an electroencephalogram emotion recognition apparatus based on fractional fourier transform, including:
a memory for storing a software application,
and the processor is used for executing the software application program, and each program of the software application program correspondingly executes the steps in the electroencephalogram emotion recognition method based on fractional Fourier transform.
The fractional Fourier transform method adopted by the invention is suitable for the brain electrical non-stationary signal, and can capture the emotion characteristics of the brain electrical signal in the time domain and the frequency domain at the same time, thereby being beneficial to emotion recognition of the brain electrical signal.
The method can carry out emotion recognition by adopting the electroencephalogram signal on the single channel Cz, simplifies the multichannel electroencephalogram signal recognition process, improves the program operation efficiency, and is more in line with the application trend of electroencephalogram emotion recognition.
Drawings
FIG. 1 is a process flow diagram of the method of the present invention;
fig. 2 is a fractional fourier transform result of the DEAP brain electrical signal at α=0.4 order;
fig. 3 is a fractional fourier transform result of the SEED brain electrical signal at α=0.4 order;
fig. 4 is an emotion classification effect diagram of the DEAP electroencephalogram under the SVM algorithm;
fig. 5 is an emotion classification effect diagram of the SEED brain electrical signal under an SVM algorithm.
Detailed Description
The invention is further described below with reference to the drawings and specific examples.
As shown in fig. 1-5, the electroencephalogram emotion recognition method based on fractional order fourier transform of the invention comprises the following steps:
preprocessing an electroencephalogram signal:
s11, channel selection: selecting single-channel electroencephalogram signals under different emotion types;
specifically, in step S11, the single-channel electroencephalogram signal is an electroencephalogram signal on a Cz channel,
in this embodiment, the Cz channel on the DEAP emotion data set and the SEED emotion data set is selected as target data for electroencephalogram emotion recognition, the DEAP emotion data set and the SEED emotion data set include electroencephalogram signals with different emotions, the DEAP data set records electroencephalogram data and peripheral physiological signals from 32 participants, each participant watches 40 videos for 1 minute, and each participant scores each video according to arousal, valence state, like/dislike, dominance and familiarity degree in a scale of 1-9. The data are statistically divided into four emotional states on the arousal and valence planes, namely: low potency Low Arousal (LALV), high potency High Arousal (HAHV), low potency high arousal (LAHV) and high potency low arousal (HALV); the SEED data is a Shanghai university emotion electroencephalogram dataset that records electroencephalogram signals of 15 participants (7 men, 8 women) watching 6 different emotion movie fragments, each fragment being about 4 minutes long, three types of emotion in the electroencephalogram signals: positive, negative, neutral;
s12, signal segmentation: each single-channel electroencephalogram signal is subjected to sectional processing and is divided into a plurality of data segments;
wherein, an electroencephalogram signal is an emotion type;
specifically, in step S12, the segmentation process includes the following steps:
s121, setting the segment length as the sampling rate f s According to the total length N of the EEG signals, obtaining the segmentation number m=N/f of the EEG signals s If N cannot be f s Performing zero padding treatment on the residual undeviated electroencephalogram signals after the divisor is completed so that the number m of the segments is an integer,
for the DEAP emotion data set, the downsampling rate is 128Hz, the total length of brain electrical signals obtained by each person watching 1 video is 8064 sampling points, the segmentation length is 128, and the number of segments is 63; for the SEED emotion data set, the sampling rate is 200Hz, the total length of an electroencephalogram signal obtained by each person watching 1 emotion movie fragment is 37000 sampling points, and the number of fragments is 185 fragments;
s13, signal conversion: processing each segmented electroencephalogram signal by a fractional Fourier transform method to obtain transformed electroencephalogram signals;
specifically, in step S13, in the fractional fourier transform method, for the time domain electroencephalogram signal f (t), the fractional fourier transform of the p-order may be expressed as:
wherein (1) K is p (u,t)=A α exp[jπ(u 2 cotα-2ut cscα+t 2 cota) is a kernel function,alpha = ppi/2, p is not equal to 2n, n is an integer, alpha represents the transformation angle of the brain electrical signal from the time domain to the frequency domain, and the value range of alpha is [0,1],
The fractional Fourier transform method combines time domain and frequency domain characteristics, is different from the traditional Fourier transform, and can represent time-frequency characteristics of the electroencephalogram signal under the condition that the time-frequency angle is alpha, wherein the fractional Fourier transform refers to setting of a parameter alpha in a formula (1), and transformation of DEAP and SEED data under different orders is obtained by setting the value of the parameter alpha, wherein the value range of alpha is [0,1], and represents that the emotion electroencephalogram signal under any angle alpha in the process of transforming from the time domain to the frequency domain can be extracted;
specifically, the alpha=0.4,
the method comprises the steps of selecting alpha as 0.4 to perform fractional Fourier transform, and selecting alpha as 0.4 to obtain an intermediate signal with obvious characteristics and distinguishing time domain to frequency domain transform process.
Extracting emotion characteristics:
s2, respectively extracting emotion characteristics of each section of transformed EEG signal, respectively extracting emotion characteristics under different emotions,
in step S2, the emotion features include maximum value, average value, support area width, differential entropy, variance, energy and power of the electroencephalogram signals;
the extraction of emotion features is to extract 7 emotion features of the maximum value, the mean value, the supporting area width, the differential entropy, the variance, the energy and the power of each segment of the electroencephalogram signal after alpha=0.4 fractional Fourier transform is carried out on each segment of the electroencephalogram signal, 7×m emotion features of each electroencephalogram signal are obtained according to the electroencephalogram signal with the segmentation number of m, such as a DEAP emotion data set, the total length of the electroencephalogram signal obtained by each person watching 1 music video is 8064, the segmentation length is 128, the segmentation number is 63 segments, 7 emotion features, namely 7×63 emotion features, are extracted from each segment of 63 segments after fractional Fourier transform, and are the same emotion features, and 32×63×7 emotion features of 32 persons in the DEAP emotion data set after watching 1 video are extracted;
wherein, 7 electroencephalogram characteristics are specifically described as follows:
the maximum value characteristic is the maximum value in the brain electrical signal after each section of transformation, and reflects the maximum amplitude of all sample points in the section of data;
the mean value characteristic is the mean value of the brain electrical signals after each section of transformation, and reflects the mean amplitude value of all sample points of the section of data;
the support region width feature
Wherein (2) formula f p (M) represents the brain electricity value on the mth sampling point, M is the total sampling point number, and the width characteristic of the section of data is reflected by counting the point number of the value larger than the average value in the M sampling points;
said differential entropy
Wherein, sigma in the formula (3) represents a variance value in the electroencephalogram signal, which is a popularization form of the response shannon entropy on continuous variables;
the variance feature
Wherein n is the total sampling point number in the formula (4), M represents the average amplitude of n electroencephalogram signals, and the fluctuation characteristic of the data segment is reflected through variance;
the energy characteristics
Wherein s (N) is an electroencephalogram signal value, N is the number of electroencephalogram signal sampling points and E s Reflecting the effect of activity of the cerebral cortex on EEG signal amplitude;
the power characteristics
Wherein s (N) in the formula (6) is an electroencephalogram signal value, N is the number of sampling points of the electroencephalogram signal, and P s Reflecting the energy value corresponding to the number of unit samples.
Electroencephalogram emotion recognition:
s3, an emotion recognition model is established by adopting an SVM algorithm and emotion characteristics, and emotion type recognition of the electroencephalogram signals under different emotions is achieved.
Wherein, the electroencephalogram signals with the emotion feature extraction are labeled, different labels are used for representing different emotion categories, four-classification label processing is carried out on a DEAP data set, labels 1,2,3 and 4 respectively represent four emotion categories of low-valence low-arousal (LALV), high-valence high-arousal (HAHV), low-valence high-arousal (LAHV) and high-valence low-arousal (HALV), and for the SEED data set, the labels respectively correspond to three emotion categories of negative, neutral and positive through 0,1 and 2,
for DEAP data set, 7×64 emotion characteristics of each electroencephalogram signal are the same emotion type, and the emotion type of the electroencephalogram signal of which each person watches 40 videos for 1 minute is labeled, and the electroencephalogram signals of the same emotion type are labeled as one type.
And carrying out a one-to-many SVM classification algorithm for classifying the extracted emotion features and the emotion labels corresponding to the extracted emotion features, regarding any type of labels as 1, regarding the other types of labels as 2, training electroencephalogram emotion data through the SVM algorithm and the extracted emotion features, generating an emotion recognition model, inputting the emotion features or the electroencephalogram data into the emotion recognition model, knowing which type of emotion is according to the model, and realizing emotion type recognition of the electroencephalogram. The emotion feature recognition effect is better, and the distinction between different data is more beneficial, wherein the SVM algorithm and the SVM two-classification one-to-many SVM classification algorithm are all of the prior art, and the emotion feature can be automatically trained by inputting the emotion feature into the SVM algorithm model to generate the emotion recognition model.
According to another aspect of the present invention, there is also provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs steps in a method for identifying brain emotion based on fractional fourier transform.
According to another aspect of the present invention, there is also provided an electroencephalogram emotion recognition apparatus based on fractional fourier transform, including:
a memory for storing a software application,
and the processor is used for executing the software application program, and each program of the software application program correspondingly executes the steps in the electroencephalogram emotion recognition method based on fractional Fourier transform.
Claims (5)
1. The electroencephalogram emotion recognition method based on fractional Fourier transform is characterized by comprising the following steps of:
selecting single-channel brain electrical signals under different emotions;
carrying out sectional processing on each single-channel electroencephalogram signal;
processing each segmented electroencephalogram signal by a fractional Fourier transform method to obtain transformed electroencephalogram signals;
extracting emotion characteristics of each segment of transformed EEG signal respectively, extracting emotion characteristics under different emotions respectively,
the emotion characteristics comprise the maximum value, the mean value, the supporting area width, the differential entropy, the variance, the energy and the power of the electroencephalogram signals;
an emotion recognition model is established by adopting an SVM algorithm and emotion characteristics, so that emotion type recognition of electroencephalogram signals under different emotions is realized;
in the fractional Fourier transform method, for the time domain brain electrical signal f (t), the fractional Fourier transform of the p order is expressed as follows:
wherein (1) K is p (u,t)=A α exp[jπ(u 2 cotα-2utcscα+t 2 cota) is a kernel function,α=ppi/2, p+.2n, n being an integer, α representing the transformation angle of the electroencephalogram from the time domain to the frequency domain, said α=0.4;
the support region width feature
Wherein (2) formula f p (M) represents the brain electrical value at the mth sampling point, M is the total sampling point number;
said differential entropy
Wherein, sigma in the expression (3) represents a variance value in the transformed electroencephalogram signal.
2. The method for recognizing brain wave emotion based on fractional Fourier transform according to claim 1, wherein said single-channel brain wave signal is an brain wave signal on a Cz channel.
3. The electroencephalogram emotion recognition method based on fractional fourier transform according to claim 1, wherein the segmentation process comprises the steps of:
setting the segment length as the value of the sampling rate, obtaining the segment number of the electroencephalogram signals according to the total length of the electroencephalogram signals, wherein the segment number is the total length of the electroencephalogram signals divided by the segment length, and if the total length cannot be divided by the segment length, carrying out zero padding on the residual electroencephalogram signals which are not divided so as to enable the segment number to be an integer.
4. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, performs the steps of a method for identifying brain emotion based on fractional fourier transform as claimed in any one of claims 1 to 3.
5. An electroencephalogram emotion recognition device based on fractional order fourier transform, comprising:
a memory for storing a software application,
a processor for executing the software application program, each program of the software application program correspondingly executing the steps in the electroencephalogram emotion recognition method based on fractional fourier transform as claimed in any one of claims 1 to 3.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211439327.XA CN115844421B (en) | 2022-11-17 | 2022-11-17 | Electroencephalogram emotion recognition method and equipment based on fractional Fourier transform |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211439327.XA CN115844421B (en) | 2022-11-17 | 2022-11-17 | Electroencephalogram emotion recognition method and equipment based on fractional Fourier transform |
Publications (2)
Publication Number | Publication Date |
---|---|
CN115844421A CN115844421A (en) | 2023-03-28 |
CN115844421B true CN115844421B (en) | 2023-06-16 |
Family
ID=85663892
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211439327.XA Active CN115844421B (en) | 2022-11-17 | 2022-11-17 | Electroencephalogram emotion recognition method and equipment based on fractional Fourier transform |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115844421B (en) |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107832709A (en) * | 2017-11-10 | 2018-03-23 | 辽宁师范大学 | The brain electricity emotion identification method of feature extraction is carried out based on experience wavelet transformation |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20210041953A1 (en) * | 2019-08-06 | 2021-02-11 | Neuroenhancement Lab, LLC | System and method for communicating brain activity to an imaging device |
-
2022
- 2022-11-17 CN CN202211439327.XA patent/CN115844421B/en active Active
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107832709A (en) * | 2017-11-10 | 2018-03-23 | 辽宁师范大学 | The brain electricity emotion identification method of feature extraction is carried out based on experience wavelet transformation |
Also Published As
Publication number | Publication date |
---|---|
CN115844421A (en) | 2023-03-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Ozdemir et al. | Epileptic eeg classification by using time-frequency images for deep learning | |
Samiee et al. | Epileptic seizure detection in long-term EEG records using sparse rational decomposition and local Gabor binary patterns feature extraction | |
CN107361766B (en) | Emotion electroencephalogram signal identification method based on EMD domain multi-dimensional information | |
Candra et al. | Investigation of window size in classification of EEG-emotion signal with wavelet entropy and support vector machine | |
Shahnaz et al. | Emotion recognition based on wavelet analysis of Empirical Mode Decomposed EEG signals responsive to music videos | |
Cura et al. | Classification of epileptic EEG signals using synchrosqueezing transform and machine learning | |
Duman et al. | Patient specific seizure prediction algorithm using Hilbert-Huang transform | |
CN108742697B (en) | Heart sound signal classification method and terminal equipment | |
CN112603332A (en) | Emotion cognition method based on electroencephalogram signal characteristic analysis | |
Hassan et al. | Human attention recognition with machine learning from brain-EEG signals | |
CN114190944B (en) | Robust emotion recognition method based on electroencephalogram signals | |
Kuila et al. | Feature extraction of electrocardiogram signal using machine learning classification | |
Zhang et al. | Four-classes human emotion recognition via entropy characteristic and random Forest | |
CN113558644A (en) | Emotion classification method, medium and equipment for 3D matrix and multidimensional convolution network | |
CN115844421B (en) | Electroencephalogram emotion recognition method and equipment based on fractional Fourier transform | |
Gurve et al. | Deep learning of EEG time–frequency representations for identifying eye states | |
CN111317467A (en) | Electroencephalogram signal analysis method and device, terminal device and storage medium | |
Shahnaz et al. | Seizure detection exploiting EMD-wavelet analysis of EEG signals | |
Patil et al. | Classification of human emotions using multiclass support vector machine | |
Li et al. | Feature extraction based on high order statistics measures and entropy for eeg biometrics | |
CN113712574B (en) | Brain electrical biofeedback rehabilitation method and system | |
Baziyad et al. | A study and performance analysis of three paradigms of wavelet coefficients combinations in three-class motor imagery based BCI | |
Wang et al. | Combining STFT and random forest algorithm for epileptic detection | |
Bo et al. | Music-evoked emotion classification using EEG correlation-based information | |
Xu et al. | Eeg signal classification and feature extraction methods based on deep learning: A review |
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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant |