Skip to content

ENH: (Optionally) modify the head shown in plot_topomap for MEG data #5471

@larsoner

Description

@larsoner

Currently plot_topomap always shows a head centered in the MEG layout, i.e., head centered relative to the sensor positions that have been 3d-to-2d projected device coordinate frame.

We should be able to improve the accuracy of this by translating + "rotating" this head by, according to the information in dev_head_t:

  • Show x/y translation by moving the x/y location of the head (in MRG, BUG: Fix M/EEG topomap plotting #7066)
  • Show z translation (depth) by shrinking the head (not doing it because it's going to get too confusing with flattening / ortho vs perspective projection)
  • EDIT: Not doing this either because it's a bit overkill: Show rotation of the head relative to the sensors by:
    1. Showing a (rotated) cross-hairs on the top of the head (in the center of the head iff the rotation part of dev_head_t is np.eye(3))
    2. Showing the ears and nose rotated properly (in gray if they are not visible because they are rotated downward)

I talked to @agramfort and this should be optional so that people can always get the "standard" plot back. But basically I think how we show things right now is essentially incorrect so I think we should add a parameter transform_head that moves from False(master) ->True (this proposal) via deprecation cycle (users only get a warning when showing MEG data).

This is of course contingent on this representation actually visually looking more informative.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions