Created
July 28, 2016 21:20
-
-
Save robintibor/ccab012129fb2c37507933665155f8a4 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"cells": [ | |
{ | |
"cell_type": "code", | |
"execution_count": 1, | |
"metadata": { | |
"collapsed": true | |
}, | |
"outputs": [], | |
"source": [ | |
"%%capture\n", | |
"import sklearn\n", | |
"import os\n", | |
"import site\n", | |
"site.addsitedir('/home/schirrmr/.local/lib/python2.7/site-packages/')\n", | |
"site.addsitedir('/usr/lib/pymodules/python2.7/')\n", | |
"os.sys.path.insert(0, '/home/schirrmr/braindecode/code/')\n", | |
"%cd /home/schirrmr/braindecode/code/braindecode/\n", | |
"assert 'THEANO_FLAGS' in os.environ\n", | |
"# switch to cpu\n", | |
"os.environ['THEANO_FLAGS'] = 'floatX=float32,device=cpu,nvcc.fastmath=True'\n", | |
"\n", | |
"%load_ext autoreload\n", | |
"%autoreload 2\n", | |
"import numpy as np\n", | |
"\n", | |
"import matplotlib\n", | |
"from matplotlib import pyplot\n", | |
"from matplotlib import cm\n", | |
"%matplotlib inline\n", | |
"%config InlineBackend.figure_format = 'png' \n", | |
"matplotlib.rcParams['figure.figsize'] = (12.0, 3.0)\n", | |
"matplotlib.rcParams['font.size'] = 7\n", | |
"\n", | |
"import matplotlib.lines as mlines\n", | |
"import seaborn\n", | |
"seaborn.set_style('darkgrid')\n" | |
] | |
}, | |
{ | |
"cell_type": "code", | |
"execution_count": 2, | |
"metadata": { | |
"collapsed": true | |
}, | |
"outputs": [], | |
"source": [ | |
"from braindecode.datasets.loaders import BBCIDataset" | |
] | |
}, | |
{ | |
"cell_type": "code", | |
"execution_count": 5, | |
"metadata": { | |
"collapsed": false | |
}, | |
"outputs": [], | |
"source": [ | |
"cnt = BBCIDataset('data/robot-hall/NiRiNBD1S001_ds10_realMovement.BBCI.mat', load_sensor_names=['C3']).load()\n" | |
] | |
}, | |
{ | |
"cell_type": "code", | |
"execution_count": 7, | |
"metadata": { | |
"collapsed": false | |
}, | |
"outputs": [ | |
{ | |
"data": { | |
"text/plain": [ | |
"200" | |
] | |
}, | |
"execution_count": 7, | |
"metadata": {}, | |
"output_type": "execute_result" | |
} | |
], | |
"source": [ | |
"len(cnt.markers)" | |
] | |
}, | |
{ | |
"cell_type": "code", | |
"execution_count": 8, | |
"metadata": { | |
"collapsed": false | |
}, | |
"outputs": [ | |
{ | |
"data": { | |
"text/plain": [ | |
"600" | |
] | |
}, | |
"execution_count": 8, | |
"metadata": {}, | |
"output_type": "execute_result" | |
} | |
], | |
"source": [ | |
"cnt = BBCIDataset('data/robot-hall/NiRiNBD1S001_ds10_imagMovement.BBCI.mat', load_sensor_names=['C3']).load()\n", | |
"len(cnt.markers)" | |
] | |
} | |
], | |
"metadata": { | |
"kernelspec": { | |
"display_name": "Python 2", | |
"language": "python", | |
"name": "python2" | |
}, | |
"language_info": { | |
"codemirror_mode": { | |
"name": "ipython", | |
"version": 2 | |
}, | |
"file_extension": ".py", | |
"mimetype": "text/x-python", | |
"name": "python", | |
"nbconvert_exporter": "python", | |
"pygments_lexer": "ipython2", | |
"version": "2.7.6" | |
} | |
}, | |
"nbformat": 4, | |
"nbformat_minor": 0 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment