pbashivan / EEGLearn

A set of functions for supervised feature learning/classification of mental states from EEG based on "EEG images" idea.
GNU General Public License v2.0
710 stars 220 forks source link

Sample Code #31

Closed aby03 closed 6 years ago

aby03 commented 6 years ago

Hello there! I am new to this stuff.

Do you have any sample code for using it on any publicly available database which I can follow to understand how your library can be used?

I am just starting in this field and have very limited theoretical knowledge. I am trying to find code that I can run on the given data and it classifies it so I can understand it and use it on my data later

pbashivan commented 6 years ago

try running https://github.com/pbashivan/EEGLearn/blob/master/eeglearn/eeg_cnn_lib.py by changing the working directory to eeglearn and running python eeg_cnn_lib.py.

This will load a sample data from the repo, generate images and train the network.

aby03 commented 6 years ago

Thanks for that.

Also, is there any code using those weights generated by network to classify inputs and return class labels?

PS- There are some issues in print function and range function when running in python3 though they are easily fixable.

pbashivan commented 6 years ago

You should be able to use lasagne.layers.set_all_param_values to load the weights. Look at the sample code here:

https://lasagne.readthedocs.io/en/latest/modules/layers/helper.html