Skip to content
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

MRG: Refactor plot_alignment #9714

Merged
merged 13 commits into from
Sep 6, 2021

Conversation

GuillaumeFavelier
Copy link
Contributor

@GuillaumeFavelier GuillaumeFavelier commented Sep 2, 2021

This PR refactors plot_alignment() following #9689 (comment). It fixes #9542. It fixes #9715.

It's still work in progress.

ToDO

  • _plot_head_surface
  • _plot_axes
  • _plot_head_shape_points
  • _plot_head_fiducials
  • _plot_mri_fiducials
  • _plot_forward

The functions should all receive an instance of _Renderer as first parameter and return a list of vtkActors as first output.

@larsoner
Copy link
Member

larsoner commented Sep 2, 2021

If possible could you also fix #9715 / #9585 (comment) ?

@GuillaumeFavelier
Copy link
Contributor Author

I updated the branch with main and I think I fixed it indirectly.

https://33649-1301584-gh.circle-artifacts.com/0/dev/auto_tutorials/forward/35_eeg_no_mri.html?highlight=eeg%20mri

Copy link
Member

@agramfort agramfort left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so far so good !

@GuillaumeFavelier tell me when it's good enough from your end.

mne/viz/_3d.py Outdated Show resolved Hide resolved
@GuillaumeFavelier GuillaumeFavelier changed the title WIP: Refactor plot_alignment MRG: Refactor plot_alignment Sep 6, 2021
@GuillaumeFavelier
Copy link
Contributor Author

It's now ready on my end @agramfort, what do you think?

@larsoner
Copy link
Member

larsoner commented Sep 6, 2021

Also @alexrockhill feel free to look if you have time

@alexrockhill
Copy link
Contributor

Didn't run it but looks like great fixes, thanks and sorry I didn't have the time to do the bug I made

@agramfort agramfort merged commit 3e7914e into mne-tools:main Sep 6, 2021
@agramfort
Copy link
Member

thx @GuillaumeFavelier

marsipu pushed a commit to marsipu/mne-python that referenced this pull request Sep 6, 2021
* start with _plot_head_surface

* refactor

* add _plot_axes

* update

* fix

* touch example

* fix

* update

* return actor

* add _plot_forward

* add _plot_mri_fiducials

* return actors
@GuillaumeFavelier GuillaumeFavelier deleted the refactor/plot_alignment branch September 7, 2021 07:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
4 participants