Skip to content

Notebook plotting regression in 3.4.0rc* #19701

Closed
@ericpre

Description

@ericpre

Bug report

Bug summary

Blitting support have been added in the notebook backend, however, it is fully working, see #19633 and in particular #19633 (comment).

This breaks plotting for libraries using the supports_blit property of the canvas to know if blitting should be used.

Even if I am really looking forward using blitting in the notebook/ipympl backend, in 3.4.0rc, it seems that this is not ready to be fully used and it breaks plotting in the notebook of hyperspy.
Would it be make sense to have supports_blit returns False for the notebook backend until blitting is working fine?

Code for reproduction

It is difficult to provide a minimum example because of #19633 (comment) but it can be reproduce using hyperspy:

# Paste your code here
%matplotlib notebook
import hyperspy.api as hs

s = hs.datasets.artificial_data.get_core_loss_eels_line_scan_signal()
s.plot()

Actual outcome

notebook_blitting

Similarly ss reported in by @ianhi in #19633, this will use 100% of a CPU. Also, the width of the figure is not correct and the axes disappear when changing the size of the figure:
notebook_blitting-resize

Expected outcome

Using blitting should work as with other backend, until then, blitting should not be defined as supported for the notebook/ipympl backend.

Matplotlib version

  • Operating system:
  • Matplotlib version (import matplotlib; print(matplotlib.__version__)):
  • Matplotlib backend (print(matplotlib.get_backend())):
  • Python version:
  • Jupyter version (if applicable):
  • Other libraries:

Metadata

Metadata

Assignees

No one assigned

    Labels

    Release criticalFor bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions