Code Monkey home page Code Monkey logo

eeg-stress-prediction's Introduction

Comparison of EEG stress-prediction using constructive vs static networks.

This repository compares the performance of static and constructive neural networks. Results from the corresponding writeup (V1) can be reproduced as follows:

  1. Run data_prep.ipynb to process data/features_by_participant.xlsx.
  2. Run train_test.ipynb. The training cell must be re-run for each dataset, which is done by changing the variable dataset at the top of the cell.

Note that 5-run k-fold cross-validation can take a while to run.

In addition to packages from the standard library, you'll need:

sklearn, torch, matplotlib, seaborn, numpy, pandas, ipympl, openpyxl.

All other python files are helpers:

  • constr_casc.py defines the constructive cascade network architecture (Casper).
  • static_nets.py defines the static network architecture (both for logistic regression and MLP training).
  • performance_metrics.py contains helpers for tracking the performance of each model.
  • data_prep.ipynb processes the original dataset.

To track results across sessions, performance metrics are saved to .csv files under results/. The results included with the current repository reflect those presented in the writeup linked above. Each time a model is run/evaluated, results for the corresponding dataset and model ID will be overwritten in the appropriate CSV file, unless recompute_model_perfs is removed from the end of the training cell.

For references, see the writeup.

eeg-stress-prediction's People

Contributors

patgleeson101 avatar

Watchers

 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.