Skip to content

Fix corrupted figures in plot_background_freesurfer_mne #9007

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

Closed
drammock opened this issue Mar 6, 2021 · 7 comments · Fixed by #9010 or #9318
Closed

Fix corrupted figures in plot_background_freesurfer_mne #9007

drammock opened this issue Mar 6, 2021 · 7 comments · Fixed by #9010 or #9318
Assignees
Milestone

Comments

@drammock
Copy link
Member

drammock commented Mar 6, 2021

Several plots in tutorials/source-modeling/plot_background_freesurfer_mne.py are messed up (inverted, misaligned, or corrupted). See if you can fix them. Check with @larsoner or @GuillaumeFavelier before you start; some of them might be due to 3D viz bugs that aren't fixed yet.

@larsoner
Copy link
Member

larsoner commented Mar 8, 2021

I think this has to do with a change related to whether the camera's focal point is at 0, 0, 0 (new behavior) or center of the bounding box of all objects in the scene (old behavior). @GuillaumeFavelier I think we should make sure that there is some option like focalpoint='bounds' or so (and focalpoint=None should mean "use existing focal point"), and maybe set "bounds" (back) to the default. WDYT?

@GuillaumeFavelier
Copy link
Contributor

this has to do with a change related to whether the camera's focal point is at 0, 0, 0 (new behavior) or center of the bounding box of all objects in the scene (old behavior)

Agreed, the behaviour of the focal point should be clarified and maybe even tested (to avoid this out of focus brain regression) ?

@larsoner
Copy link
Member

larsoner commented Mar 8, 2021

A simple test would be to compute the center of mass based on non-background-color pixels. Do you want to try @GuillaumeFavelier ?

@GuillaumeFavelier
Copy link
Contributor

GuillaumeFavelier commented Mar 8, 2021

bounds are given by VTK's ComputeVisiblePropBounds right?
EDIT: I suggest we just re-use that to test the new default.

@larsoner
Copy link
Member

larsoner commented Mar 8, 2021

Looks like it, yeah.

@GuillaumeFavelier
Copy link
Contributor

I'm on it

@drammock
Copy link
Member Author

Just found another corrupted 3D plot: https://mne.tools/dev/auto_tutorials/evoked/plot_20_visualize_evoked.html#d-field-maps

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants