how to use viz.plot_alignment() on SEEG data?

To clarify, I have been using the data from the ECOG demo (https://martinos.org/mne/stable/auto_examples/visualization/plot_3d_to_2d.html#sphx-glr-auto-examples-visualization-plot-3d-to-2d-py) in my demo notebooks since other MNE users have easy access to that data.

To facilitate my attempts to use the Brainstorm demo, I have run the pre-implantation MRI from the Brainstorm demo (http://neuroimage.usc.edu/brainstorm/Tutorials/Epileptogenicity) through freesurfer as that seemed the path of least resistance to using the data in MNE. I'm not using that scan in these demos because it is not mine to share and I don't think anyone else wants to run it through freesurfer just to try my demo.

I think my issue is that I have electrode coordinates in the MRI coordinate system as suggested by the observation that they make sense when plotted using pysurfer. However MNE seems to use a different default coordinate system ('head'?) and I haven't figured out how to convert or make MNE recognize that the coordinates are not in the default system. I have created yet another demo notebook using the MRI from the ECOG demo ('sample') with some electrode coordinates in the MRI coordinate system. As shown, they can be plotted with pysurfer but viz.plot_alignment doesn't work.

https://gist.github.com/lneisenman/38ca9cf2e4075776f8476cebb114d2a1

How do I find/create the transform to convert the coordinates to the default system? The coordinates included in the ECOG demo clearly are not in the MRI coordinate system.

Larry

hi Larry,

indeed sEEG were ignored in plot_alignment.

This PR should fix it: https://github.com/mne-tools/mne-python/pull/4903

let us know directly on github if it does the job for you.

thanks for reporting the issue.

Best,
Alex

hi,

the PR is merged.

Here a tiny script I wrote that should get you started with these data:

https://gist.github.com/agramfort/3690a41529ffa9534701e6a330460f07

Note that I use neo to read the TRC file. We should have this reader
via neo in the next release.

HTH
Alex