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

[Bug]: Cut-off rotated x-tick label when using imshow and constrained layout #30117

Open
@oscargus

Description

@oscargus

Bug summary

I'll try to come up with a smaller reproducer, but thought I'd just report it now. The full script is athttps://github.com/apytypes/apytypes/tree/main/comparison (run comparison.py while standing in that directory, no need to install any of the dependencies, there will just be red pixels instead...)

Code for reproduction

# Plotting partsfig,ax=plt.subplots(layout="constrained",figsize=(8,5))ax.imshow(working)ax.set_xticks(x,benchmarks.keys(),rotation=90,)ax.set_yticks(range(len(libraries)),libraries.keys())fig.savefig("comparison_matrix.png")

Actual outcome

Image

Expected outcome

The very long label should not be clipped (it says "Elementwise ...". There is plenty of white space at the top to avoid this.

Additional information

My guess is that it related to imshow and therefore the equal aspect ratio as I have done similar things for bar plots and then the full label is shown, seehttps://apytypes.github.io/apytypes/comparison.html

Operating system

Ubuntu 24, both WSL and GitHub CI

Matplotlib Version

main:4f26d9a (WSL) and 3.10.3 (GitHub CI)

Matplotlib Backend

No response

Python version

3.12.3 (WSL) and 3.11 (GitHub CI)

Jupyter version

No response

Installation

None

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp