Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Jupyter "inline" backend seems to misinterpret "figsize" with Axes3D #16463

Closed
Labels
Release criticalFor bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions.topic: geometry managerLayoutEngine, Constrained layout, Tight layouttopic: mplot3d
Milestone
@mgeier

Description

@mgeier

I don't know if this is a bug in Jupyter/IPython or in Matplotlib ...

Bug report

Bug summary

When creating 3D plots (usingAxes3D) with the "inline" backend (which is the default) in a Jupyter notebook, the argumentfigsize doesn't seem to work as intended. It looks like the width is ignored when calculating the figure size (but it doesn't seem to be ignored when calculating the size of the "axes" object?).

Actual outcome

First, when usingfig.gca(projection='3d'), which is used in the official Matplotlib examples:

image

The same thing happens when usingfig.add_subplot(projection='3d'):

image

Interestingly, a slightly different thing happens when usingfig.add_axes([0, 0, 1, 1], projection='3d') andAxes3D(fig) (which is discouraged?):

image

Expected outcome

When using a "normal" 2DAxes, it looks as expected:

image

The output fromfig.add_axes([0, 0, 1, 1]) is also different in this case:

image

Matplotlib version

  • Operating system: Debian Linux
  • Matplotlib version:master
  • Matplotlib backend (print(matplotlib.get_backend())):module://ipykernel.pylab.backend_inline
  • Python version: 3.7.6
  • Jupyter version (if applicable): JupyterLabmaster

Metadata

Metadata

Assignees

No one assigned

    Labels

    Release criticalFor bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions.topic: geometry managerLayoutEngine, Constrained layout, Tight layouttopic: mplot3d

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp