GithubHelp home page GithubHelp logo

xiruicao2000 / emotion-recogniton-from-eeg-signals Goto Github PK

View Code? Open in Web Editor NEW

This project forked from hi-akshat/emotion-recogniton-from-eeg-signals

0.0 0.0 0.0 6.89 MB

Emotion Recognition from EEG Signals using the DEAP dataset with 86.4% accuracy. Applied multiple machine learning models and implemented various signal transforming algorithms like the DWT algorithm.

License: MIT License

Python 100.00%

emotion-recogniton-from-eeg-signals's Introduction

Emotion-Recogniton-from-DEAP

We used data from the DEAP dataset that has been pre-processed in MATLAB.

In this dataset, 32 subjects viewed 40 clips of video that could stimulate various emotions.

The length of each video is 60s.

Each subject provided a personal rating in the valence-arousal-dominance-liking four dimensions, ranging from 1 to 9, 1 is the smallest, and 9 is the largest.

During the pre-processing phase, a preparation time of 3 s was added to each video, thereby changing the total time of each video to 63s.

We analyzed the emotion in the valence and arousal dimensions. If an individual’s score is greater than 4.5, the level of arousal/valence is classified as high, whereas if the individual’s score is less than 4.5, the level of arousal/valence is classified as low.

We used the average mean reference (AMR)method to pre-process the EEG data. Then, toeliminate individual differences and channel differences, we normalized the EEG signals for each channel of each person to [0,1] using the min-max normalization method, thereby reducing the computational complexity.

We used discrete wavelet transform (DWT) to extract EEG features. A series of wavelet coefficients were obtained by stretching and shifting the EEG signals using the mother wavelet function.

In our project, the window of 4 s was used for each EEG channel and each window overlaps the previous one by 2 s, for a total of 29 windows.

Then, the data of each window were decomposed 4 times by using db4 DWT and extracting all the high frequency components as four frequency bands, namely, gamma, beta, alpha and theta.

Decomposition of EEG signal into different frequency bands using DWT

Frequency band Frequency range (Hz) Frequency bandwidth (Hz) Decomposition level

Theta 4–8 4 D4 Alpha 8–16 8 D3 Beta 16–32 16 D2 Gamma 32–64 32 D1

Finally,the entropy and energy of each frequency band were calculated as features. Thus, there are 2 features in each band for each channel. There are 20 (2*10) features in 10 channels, and the numbers of features are 28, 36 and 64 in 14, 18 and 32 channels, respectively.

emotion-recogniton-from-eeg-signals's People

Contributors

hi-akshat avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.