raws = {
    'Neuromag':
    read_raw_fif(sample.data_path() + '/MEG/sample/sample_audvis_raw.fif'),
    'CTF 275':
    read_raw_ctf(spm_face.data_path() +
                 '/MEG/spm/SPM_CTF_MEG_example_faces1_3D.ds'),
    'Magnes 3600wh':
    read_raw_bti(op.join(bti_path, 'test_pdf_linux'),
                 op.join(bti_path, 'test_config_linux'),
                 op.join(bti_path, 'test_hs_linux')),
    'KIT':
    read_raw_kit(op.join(kit_path, 'test.sqd')),
    'Artemis123':
    read_raw_artemis123(
        op.join(testing.data_path(), 'ARTEMIS123',
                'Artemis_Data_2017-04-14-10h-38m-59s_Phantom_1k_HPI_1s.bin')),
}

for system, raw in sorted(raws.items()):
    meg = ['helmet', 'sensors']
    # We don't have coil definitions for KIT refs, so exclude them
    if system != 'KIT':
        meg.append('ref')
    fig = plot_alignment(raw.info,
                         eeg=False,
                         meg=('helmet', 'sensors'),
                         coord_frame='meg',
                         show_axes=True,
                         verbose=True)
    set_3d_title(figure=fig, title=system)
Beispiel #2
0
from mne.io import read_raw_fif, read_raw_ctf, read_raw_bti, read_raw_kit
from mne.io import read_raw_artemis123
from mne.datasets import sample, spm_face, testing
from mne.viz import plot_alignment, set_3d_title

print(__doc__)

###############################################################################
# Neuromag
# --------

kwargs = dict(eeg=False, coord_frame='meg', show_axes=True, verbose=True)

raw = read_raw_fif(sample.data_path() + '/MEG/sample/sample_audvis_raw.fif')
fig = plot_alignment(raw.info, meg=('helmet', 'sensors'), **kwargs)
set_3d_title(figure=fig, title='Neuromag')

###############################################################################
# CTF
# ---

raw = read_raw_ctf(spm_face.data_path() +
                   '/MEG/spm/SPM_CTF_MEG_example_faces1_3D.ds')
fig = plot_alignment(raw.info, meg=('helmet', 'sensors', 'ref'), **kwargs)
set_3d_title(figure=fig, title='CTF 275')

###############################################################################
# BTi
# ---

bti_path = op.abspath(op.dirname(mne.__file__)) + '/io/bti/tests/data/'
Beispiel #3
0
        # Plot options
        show_axes=True,
        dig=True,
        surfaces='head',
        bem=sphere,

        # Create dummy info
        info=mne.create_info(
            ch_names=montage.ch_names,
            sfreq=1,
            ch_types='eeg',
            montage=montage,
        ),
    )
    set_3d_view(figure=fig, azimuth=135, elevation=80)
    set_3d_title(figure=fig, title=current_montage)

###############################################################################
# Check all montages against fsaverage
#

subjects_dir = op.dirname(fetch_fsaverage())

for current_montage in get_builtin_montages():
    montage = mne.channels.make_standard_montage(current_montage)
    fig = mne.viz.plot_alignment(
        # Plot options
        show_axes=True,
        dig=True,
        surfaces='head',
        trans=None,
Beispiel #4
0
from mne.channels.montage import get_builtin_montages
from mne.datasets import fetch_fsaverage
from mne.viz import plot_alignment, set_3d_view, set_3d_title

subjects_dir = op.dirname(fetch_fsaverage())

###############################################################################
# check all montages
#

for current_montage in get_builtin_montages():

    montage = mne.channels.read_montage(current_montage,
                                        unit='auto',
                                        transform=False)

    info = mne.create_info(ch_names=montage.ch_names,
                           sfreq=1,
                           ch_types='eeg',
                           montage=montage)

    fig = plot_alignment(
        info,
        trans=None,
        subject='fsaverage',
        subjects_dir=subjects_dir,
        eeg=['projected'],
    )
    set_3d_view(figure=fig, azimuth=135, elevation=80)
    set_3d_title(figure=fig, title=montage.kind)