mne.viz.set_3d_backend#

mne.viz.set_3d_backend(backend_name, verbose=None)[source]#

Set the 3D backend for MNE.

The backend will be set as specified and operations will use that backend.

Parameters:
backend_namestr

The 3d backend to select. See Notes for the capabilities of each backend ('pyvistaqt' and 'notebook').

Changed in version 0.24: The 'pyvista' backend was renamed 'pyvistaqt'.

verbosebool | str | int | None

Control verbosity of the logging output. If None, use the default verbosity level. See the logging documentation and mne.verbose() for details. Should only be passed as a keyword argument.

Returns:
old_backend_namestr | None

The old backend that was in use.

Notes

To use PyVista, set backend_name to pyvistaqt but the value pyvista is still supported for backward compatibility.

This table shows the capabilities of each backend (”✓” for full support, and “-” for partial support):

3D function:

pyvistaqt

notebook

plot_vector_source_estimates()

plot_source_estimates()

plot_alignment()

plot_sparse_source_estimates()

plot_evoked_field()

snapshot_brain_montage()

link_brains()

Feature:

Large data

Opacity/transparency

Support geometric glyph

Smooth shading

Subplotting

Inline plot in Jupyter Notebook

Inline plot in JupyterLab

Inline plot in Google Colab

Toolbar

Examples using mne.viz.set_3d_backend#

Locating intracranial electrode contacts

Locating intracranial electrode contacts

Locating intracranial electrode contacts