This repository includes installation instructions, source code, extra documents and more from Lennert Bontinck's Master Thesis on processing and using EEG signals from motor imagery tasks in a BCI setting @ VUB 2021 - 2022.
The PDF version of the master thesis is available here.
Name | Role | VUB mail | Personal mail |
---|---|---|---|
Lennert Bontinck | Master Thesis writer | [email protected] | [email protected] |
Geraint Wiggins | Promotor | [email protected] | / |
Arnau Dillen | Supervisor | [email protected] | / |
Kevin De Pauw | Co-Supervisor | [email protected] | / |
To make reproducing the project easier, the following documentation is provided.
Most of the libraries related to the OpenBCI hardware work best on Windows machines. Some of the required dependencies aren't even available on macOS, for this reason, these install instructions focus mainly on Windows 10 machines. However, a conda environment for macOS is also made available as well as some notes for macOS-specific installs. Non-OpenBCI-related code works well on both macOS and Windows normally, although Windows is still advised.
Title | Documentation |
---|---|
Install instructions of anaconda environment | Available here |
Running the anaconda environment to open the Jupyter Notebooks is straightforward when the environment is installed as discussed above. For completeness, some instructions on running the environment are given as well.
Title | Documentation |
---|---|
Initialisation of the Anaconda environment | Available here |
All of the code used for creating the paper associated with this thesis and more are provided to ensure full transparency.
Some utility files are provided to extract certain aspects from the main notebooks such as data retrieval in a simply python importable utility file. Import instructions for the utility files are given in the header of the corresponding file.
Title | Location |
---|---|
CLA dataset util | Available here |
TF tools | Available here |
EEG models | Available here |
What we refer to as paper notebooks are notebooks which include code for experiments and plotting results that are directly used in the paper or directly referenced in the paper. Special attention to reproduction and well-documented code is given in these notebooks to improve their scientific value. A HTML export of each notebook is made so the code and output can be looked at without requiring the Anaconda environment.
Title | Notebook location | HTML export location |
---|---|---|
1: Data visualisation | Available here | Available here |
2: Standard CSP pipelines | Available here | Available here |
3: Advanced CSP pipelines | Available here | Available here |
4: EEGNet | Available here | Available here |
5: DeepConvNet | Available here | Available here |
6: ShallowConvNet | Available here | Available here |
7: EEGNet with LSTM | Available here | Available here |
8: Further improvements | Available here | Available here |
A: Figures | Available here | Available here |
Some of the code written is not used explicitly in the paper but was used to gain information or test code that will be used in the final project. We call these experimental notebooks and they contain a lot of annotations as well. The following experimental notebooks are available:
Title | Notebook location |
---|---|
1: CLA dataset exploration notebook | Available here |
2: MNE datastructure exploration notebook | Available here |
3: MNE epoching | Available here |
4: CSP based classification | Available here |
5: CSP based classification using parameters from the previous subject | Available here |
6: Deep Learning based classification | Available here |
7: Improving inter-session EEGNet | Available here |
The literature review is one of the most important aspects of any scientific paper. All scientific sources that were considered are available in a Zotero maintained list, the reference list of the paper lists all of these sources that are effectively used in the paper, both directly as indirectly.
As this master thesis should be scientific grade, the sources should also be scientific. Finding good sources isn't an easy task since there are so many to choose from. Luckily Arnau Dillen and Geraint Wiggins gave some great pointers on where to begin and how to proceed. A list of all scientific sources is available in the form of a Zotero file, more information on the scientific literature used for the thesis is available here.
For more intuitive insight into certain aspects of both code and theory, some informal sources were also used. The most important ones are listed below and are summarized to inform what was intuitively gained from them.
Title | Type | Notes |
---|---|---|
Testing Brain-Computer Interfaces | Youtube video by James Bruton - 1M subs | Notes available here |
NeuroTechX Webinars (1-3) | Professional webinars by NeuroTechX | Notes available here |
Pybrain: M/EEG analysis with MNE Python | Workshop by Richard Höchenberger - 8 hours | References throughout multiple notebooks |