-
Notifications
You must be signed in to change notification settings - Fork 1.4k
MRG, ENH: make plot alignment use defaults for colors #8553
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
Conversation
@agramfort use transparent skin but filled colors for fiducials and digitized points so we get a sense of depth |
add centroid for the nasion and for the ear fiducials as those are typically recorded with good precision by the researchers |
I think these were originally large because @christianbrodbeck had the opposite sense, that there was some ambiguity in it (from a digitizer accuracy standpoint, probably). But I agree that with well behaved subjects you can more precise than we show here, and it shouldn't hurt to make them the same size as the MRI ones. I'd rather just shrink the markers rather than make a large translucent one and a small opaque one.
We tried this default in #8446 and decided against it. So I think if people want this they should use the new
Part of the reason the fids are translucent is because in theory the |
If I recall correctly the reason for making the digitizer fiducials large was mainly to be able to see them together with the MRI fiducials, and to see the even when, for example, they're sunk slightly under the MRI head surface. With template brains the expected alignment is less perfect. |
+1 for being consistent, and I think the yellowish head is more pleasant / easier to see than the gray one. Regarding fiducial size, etc, I think making them somewhat smaller would be OK, and I like the idea of MRI fids and digitizer fids being different geometric solids... actually I think a cube for one and a regular octahedron for the other would be ideal --- if you pick the relative sizes right it would make it really easy to tell if they line up: |
@drammock do you want to lead this following my gist above? |
+1 for cube plus something else. I'm not sure VTK has an octahedron glyph, if not then cube+sphere seems fine (cube for MRI, sphere for dig) and can also have a nice clean overlap if their volumes are identical. This is also consistent with how dig points show up as spheres anyway... I would start by trying to make them equal-volume, leading to a cube-side-to-sphere-radius ratio of:
This way perfect alignment means some parts of the sphere will protrude, and the corners of the cube will, too. |
how urgent is this? it might take me some time to get up to speed on vtk etc. |
Not that urgent, but I think I can probably do it quickly -- let me take a look |
Okay I took a try with the cube. I agree octahedron would be better but it will be a pain to implement.
Gives: And with "fit fid" you get a different alignment where the nasion is aligned, you can see they are on top of each other at least: And |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thx @larsoner ! |
* upstream/master: (42 commits) MRG, ENH: Add DICS bias tests (mne-tools#8610) MRG, BUG, ENH: Add window option (mne-tools#8662) BUG: Fix alpha for volumes (mne-tools#8663) MRG, BUG: Fix bugs with envcorr (mne-tools#8658) MRG, ENH: Progressbar for csd_morlet (mne-tools#8608) Render is necessary now (mne-tools#8657) VIZ: Fix head size (mne-tools#8651) MRG, MAINT: bump sphinxcontrib-bitex version (mne-tools#8653) MRG, MAINT: Improve server env (mne-tools#8656) BUG: Mayavi center (mne-tools#8644) VIZ, ENH: allow show/hide annotations by label (mne-tools#8624) Add regression test for EEGLAB data with a chanlocs struct (mne-tools#8647) FIX: scalar_bar (mne-tools#8643) MRG: Small fix to tutorial; rename plot_events ordinate label to "Event id"; improve some SSP docstrings (mne-tools#8612) MRG, ENH: make plot alignment use defaults for colors (mne-tools#8553) BUG: Fix passing of channel type (mne-tools#8638) FIX: fixed loop over norm PSF/CTF options (mne-tools#8636) MRG, BUG: Pass kwargs (mne-tools#8630) DOC: Clearer error message (mne-tools#8631) BUG: Fix number of labels (mne-tools#8629) ...
* upstream/master: (38 commits) MRG, ENH: Add DICS bias tests (mne-tools#8610) MRG, BUG, ENH: Add window option (mne-tools#8662) BUG: Fix alpha for volumes (mne-tools#8663) MRG, BUG: Fix bugs with envcorr (mne-tools#8658) MRG, ENH: Progressbar for csd_morlet (mne-tools#8608) Render is necessary now (mne-tools#8657) VIZ: Fix head size (mne-tools#8651) MRG, MAINT: bump sphinxcontrib-bitex version (mne-tools#8653) MRG, MAINT: Improve server env (mne-tools#8656) BUG: Mayavi center (mne-tools#8644) VIZ, ENH: allow show/hide annotations by label (mne-tools#8624) Add regression test for EEGLAB data with a chanlocs struct (mne-tools#8647) FIX: scalar_bar (mne-tools#8643) MRG: Small fix to tutorial; rename plot_events ordinate label to "Event id"; improve some SSP docstrings (mne-tools#8612) MRG, ENH: make plot alignment use defaults for colors (mne-tools#8553) BUG: Fix passing of channel type (mne-tools#8638) FIX: fixed loop over norm PSF/CTF options (mne-tools#8636) MRG, BUG: Pass kwargs (mne-tools#8630) DOC: Clearer error message (mne-tools#8631) BUG: Fix number of labels (mne-tools#8629) ...
plot_alignment does not use the colors used in coreg. It should be consistent. This is just an example that leads to something like this:
as opposed to master:
FYI this is obtained with this script:
thanks @GuillaumeFavelier for the help and the Neurospin group @virvw @SophieHerbst
this should be used to produce our automatic report on coregistration.
thoughts @larsoner @drammock @jasmainak @SherazKhan ?