Separating Delta, Gamma, and Alpha Waves

  • MNE-Python version: 0.23.0
  • operating system: OS

I was curious if anyone knew of a way to separate out gamma, delta, and alpha waves from resting state data collected via EEG. We are interested in plotting these isolated waves onto an existing T1 image in freesurfer. Any and all help/advice is appreciated.

Hello, there’s an example at Compute source power spectral density (PSD) of VectorView and OPM data — MNE 0.23.0 documentation that maybe you could use as a starting point. It’s quite sophisticated in my view, so feel free to ask if you have any further questions. Also tagging @Denis, who contributed to this one.

Thank you so much! I am having an issue with this block of commands:


# Here we use a reduced size source space (oct5) just for speed
src = mne.setup_source_space(
    subject, 'oct5', add_dist=False, subjects_dir=subjects_dir)
# This line removes source-to-source distances that we will not need.
# We only do it here to save a bit of memory, in general this is not required.
del src[0]['dist'], src[1]['dist']
bem = mne.read_bem_solution(bem_fname)
fwd = dict()

# check alignment and generate forward for VectorView
kwargs = dict(azimuth=0, elevation=90, distance=0.6, focalpoint=(0., 0., 0.))
fig = mne.viz.plot_alignment(
    raws['vv'].info, trans=vv_trans_fname, subject=subject,
    subjects_dir=subjects_dir, dig=True, coord_frame='mri',
    surfaces=('head', 'white'))
mne.viz.set_3d_view(figure=fig, **kwargs)
fwd['vv'] = mne.make_forward_solution(
    raws['vv'].info, vv_trans_fname, src, bem, eeg=False, verbose=True)

Each time I run it, it crashes my kernel


I think you forgot to insert the actual error message here :slight_smile:

I do not get an error message. The window displays:

Setting up the source space with the following parameters:

SUBJECTS_DIR = /Users/labrain/mne_data/MNE-OPM-data/subjects
Subject      = OPM_sample
Surface      = white
Octahedron subdivision grade 5

>>> 1. Creating the source space...

Doing the octahedral vertex picking...
Loading /Users/labrain/mne_data/MNE-OPM-data/subjects/OPM_sample/surf/lh.white...
Mapping lh OPM_sample -> oct (5) ...
    Triangle neighbors and vertex normals...
Loading geometry from /Users/labrain/mne_data/MNE-OPM-data/subjects/OPM_sample/surf/lh.sphere...
Setting up the triangulation for the decimated surface...
loaded lh.white 1026/169022 selected to source space (oct = 5)

Loading /Users/labrain/mne_data/MNE-OPM-data/subjects/OPM_sample/surf/rh.white...
Mapping rh OPM_sample -> oct (5) ...
    Triangle neighbors and vertex normals...
Loading geometry from /Users/labrain/mne_data/MNE-OPM-data/subjects/OPM_sample/surf/rh.sphere...
Setting up the triangulation for the decimated surface...
loaded rh.white 1026/169992 selected to source space (oct = 5)

You are now one step closer to computing the gain matrix
Loading surfaces...

Loading the solution matrix...

Three-layer model surfaces loaded.
Loaded linear_collocation BEM solution from /Users/labrain/mne_data/MNE-OPM-data/subjects/OPM_sample/bem/OPM_sample-5120-5120-5120-bem-sol.fif
Using outer_skin.surf for head surface.
Getting helmet for system 306m

Followed by a pop up menu telling me my Kernel has died

Did you install MNE following the official installation instructions? Can you please provide the output of

import mne
mne.sys_info()

Thanks!