Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixes to get docs building by github action #210

Merged
merged 3 commits into from
Oct 27, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,21 @@ on:

jobs:
build:
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v1
uses: actions/setup-python@v4
with:
python-version: 3.7
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip wheel
python -m pip install attrdict

# Install wxPython wheels since they are distribution-specific and therefore not on PyPI
# See: https://wxpython.org/pages/downloads/index.html
pip install -U -f https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-18.04 wxPython
pip install -U -f https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-20.04 wxPython

pip install .
- name: Build docs
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ examples/visual_cueing/*.csv
.coverage
coverage.xml
htmlcov

# PyCharm
.idea/
4 changes: 2 additions & 2 deletions examples/visual_cueing/01r__cueing_singlesub_analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@
# Left Cue
tfr, itc = tfr_morlet(epochs['LeftCue'], freqs=frequencies,
n_cycles=wave_cycles, return_itc=True)
tfr = tfr.apply_baseline([-1,-.5],mode='mean')
tfr = tfr.apply_baseline((-1,-.5),mode='mean')
tfr.plot(picks=[0], mode='logratio',
title='TP9 - Ipsi');
tfr.plot(picks=[1], mode='logratio',
Expand All @@ -143,7 +143,7 @@
# Right Cue
tfr, itc = tfr_morlet(epochs['RightCue'], freqs=frequencies,
n_cycles=wave_cycles, return_itc=True)
tfr = tfr.apply_baseline([-1,-.5],mode='mean')
tfr = tfr.apply_baseline((-1,-.5),mode='mean')
tfr.plot(picks=[0], mode='logratio',
title='TP9 - Contra');
tfr.plot(picks=[1], mode='logratio',
Expand Down
4 changes: 2 additions & 2 deletions examples/visual_cueing/02r__cueing_group_analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@
# Left Cue
tfr, itc = tfr_morlet(epochs['LeftCue'], freqs=frequencies,
n_cycles=wave_cycles, return_itc=True)
tfr = tfr.apply_baseline([-1,-.5],mode='mean')
tfr = tfr.apply_baseline((-1,-.5),mode='mean')
#tfr.plot(picks=[0], mode='logratio',
# title='TP9 - Ipsi');
#tfr.plot(picks=[3], mode='logratio',
Expand All @@ -134,7 +134,7 @@
# Right Cue
tfr, itc = tfr_morlet(epochs['RightCue'], freqs=frequencies,
n_cycles=wave_cycles, return_itc=True)
tfr = tfr.apply_baseline([-1,-.5],mode='mean')
tfr = tfr.apply_baseline((-1,-.5),mode='mean')
#tfr.plot(picks=[0], mode='logratio',
# title='TP9 - Contra');
#tfr.plot(picks=[3], mode='logratio',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,14 +136,14 @@
# Left Cue
tfr, itc = tfr_morlet(epochs['LeftCue'], freqs=frequencies,
n_cycles=wave_cycles, return_itc=True)
tfr = tfr.apply_baseline([-1,-.5],mode='mean')
tfr = tfr.apply_baseline((-1,-.5),mode='mean')
power_Ipsi_TP9 = tfr.data[0,:,:]
power_Contra_TP10 = tfr.data[1,:,:]

# Right Cue
tfr, itc = tfr_morlet(epochs['RightCue'], freqs=frequencies,
n_cycles=wave_cycles, return_itc=True)
tfr = tfr.apply_baseline([-1,-.5],mode='mean')
tfr = tfr.apply_baseline((-1,-.5),mode='mean')
power_Contra_TP9 = tfr.data[0,:,:]
power_Ipsi_TP10 = tfr.data[1,:,:]

Expand Down
4 changes: 2 additions & 2 deletions examples/visual_cueing/CueingAnalysis_Colab.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@
"# Left Cue\n",
"tfr, itc = tfr_morlet(epochs['LeftCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
"tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
"tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
"tfr.plot(picks=[0], mode='logratio', \n",
" title='TP9 - Ipsi');\n",
"tfr.plot(picks=[1], mode='logratio', \n",
Expand All @@ -445,7 +445,7 @@
"# Right Cue\n",
"tfr, itc = tfr_morlet(epochs['RightCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
"tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
"tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
"tfr.plot(picks=[0], mode='logratio', \n",
" title='TP9 - Contra');\n",
"tfr.plot(picks=[1], mode='logratio', \n",
Expand Down
4 changes: 2 additions & 2 deletions examples/visual_cueing/CueingGroupAnalysis_Colab.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@
" # Left Cue\n",
" tfr, itc = tfr_morlet(epochs['LeftCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
" tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
" tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
" #tfr.plot(picks=[0], mode='logratio', \n",
" # title='TP9 - Ipsi');\n",
" #tfr.plot(picks=[3], mode='logratio', \n",
Expand All @@ -226,7 +226,7 @@
" # Right Cue\n",
" tfr, itc = tfr_morlet(epochs['RightCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
" tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
" tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
" #tfr.plot(picks=[0], mode='logratio', \n",
" # title='TP9 - Contra');\n",
" #tfr.plot(picks=[3], mode='logratio', \n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -215,14 +215,14 @@
" # Left Cue\n",
" tfr, itc = tfr_morlet(epochs['LeftCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
" tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
" tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
" power_Ipsi_TP9 = tfr.data[0,:,:]\n",
" power_Contra_TP10 = tfr.data[1,:,:]\n",
"\n",
" # Right Cue\n",
" tfr, itc = tfr_morlet(epochs['RightCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
" tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
" tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
" power_Contra_TP9 = tfr.data[0,:,:]\n",
" power_Ipsi_TP10 = tfr.data[1,:,:]\n",
"\n",
Expand Down
4 changes: 2 additions & 2 deletions examples/visual_cueing/cueing.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -529,7 +529,7 @@
"# Left Cue\n",
"tfr, itc = tfr_morlet(epochs['LeftCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
"tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
"tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
"tfr.plot(picks=[0], mode='logratio', \n",
" title='TP9 - Ipsi');\n",
"tfr.plot(picks=[1], mode='logratio', \n",
Expand All @@ -540,7 +540,7 @@
"# Right Cue\n",
"tfr, itc = tfr_morlet(epochs['RightCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
"tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
"tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
"tfr.plot(picks=[0], mode='logratio', \n",
" title='TP9 - Contra');\n",
"tfr.plot(picks=[1], mode='logratio', \n",
Expand Down
4 changes: 2 additions & 2 deletions examples/visual_cueing/cueing_group_analysis.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@
" # Left Cue\n",
" tfr, itc = tfr_morlet(epochs['LeftCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
" tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
" tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
" #tfr.plot(picks=[0], mode='logratio', \n",
" # title='TP9 - Ipsi');\n",
" #tfr.plot(picks=[3], mode='logratio', \n",
Expand All @@ -236,7 +236,7 @@
" # Right Cue\n",
" tfr, itc = tfr_morlet(epochs['RightCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
" tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
" tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
" #tfr.plot(picks=[0], mode='logratio', \n",
" # title='TP9 - Contra');\n",
" #tfr.plot(picks=[3], mode='logratio', \n",
Expand Down
4 changes: 2 additions & 2 deletions examples/visual_cueing/cueing_loop.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,7 @@
" # Left Cue\n",
" tfr, itc = tfr_morlet(epochs['LeftCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
" tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
" tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
" #tfr.plot(picks=[0], mode='logratio', \n",
" # title='TP9 - Ipsi');\n",
" #tfr.plot(picks=[3], mode='logratio', \n",
Expand All @@ -612,7 +612,7 @@
" # Right Cue\n",
" tfr, itc = tfr_morlet(epochs['RightCue'], freqs=frequencies, \n",
" n_cycles=wave_cycles, return_itc=True)\n",
" tfr = tfr.apply_baseline([-1,-.5],mode='mean')\n",
" tfr = tfr.apply_baseline((-1,-.5),mode='mean')\n",
" #tfr.plot(picks=[0], mode='logratio', \n",
" # title='TP9 - Contra');\n",
" #tfr.plot(picks=[3], mode='logratio', \n",
Expand Down
1 change: 1 addition & 0 deletions examples/visual_ssvep/01r__ssvep_viz.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
experiment='visual-SSVEP', site='eegnb_examples', device_name='muse2016',
data_dir = eegnb_data_path,
replace_ch_names={'Right AUX': 'POz'})
raw.set_channel_types({'POz': 'eeg'})

###################################################################################################
# Visualize the power spectrum
Expand Down