Skip to content

ipympl changes MPL backend on import #623

@sappelhoff

Description

@sappelhoff

In mne-python (see above), we have a functionality called sys_info, which gives us (among other things) the versions of all sorts of installed packages.

For this reason, we also import ipympl.

At import time, ipympl actually changes the MPL backend.

Is this something that could be avoided? This change in backend was very surprising to us and it took an in-depth profiling to identify it as the cause of a massive memory leak in a pipeline that produced several plots on each iteration, never closing them due to the backend change.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions