FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Inverted imshow using Cairo backend · Issue #7156 · matplotlib/matplotlib · GitHub

Repository navigation

Inverted imshow using Cairo backend #7156

Description

In testing some stuff for #7151, I realized that the Cairo backend inverts images plotted using imshow.

import matplotlib as mpl
mpl.use('Cairo')
import numpy as np
import matplotlib.pyplot as plt

a = np.random.randn(3,3)

im1 = plt.imshow(a, extent = [0,1,0,1])
plt.xlim(0,2.2)
plt.ylim(0,2.2)

plt.savefig('test.png')

It doesn't really matter if saving as png or pdf, the outcome is the same. With Agg, the image appears in the lower left corner:

With Cairo, the image appears in the upper left corner:

It worked correctly with mpl 1.4.3 and is broken with 1.5.0, but bisection is next to impossible because the Cairo backend was broken for a very long time.

Activity

  1. QuLogic commented on Oct 10, 2016

    MemberAuthor

    I'm going to ping @jenshnielsen who seems to have last had contact with the cairo backend.

  2. added this to the milestone on Oct 11, 2016
  3. tacaswell commented on Oct 11, 2016

    Member

    I can not reproduce this on 2.x with py3.5 and cairocffi

    Please ping to have this re-opened if there is some combination of 2.x + py + cairo binding that fails.

  4. QuLogic commented on Oct 12, 2016

    MemberAuthor

    Oh, I thought I tested with v2.x at some point, but it looks like you're right. It appears to have been fixed with the ever-growing list of things from #5718.

  5. tacaswell commented on Oct 12, 2016

    Member

    The dragon infested rabbit holes are paying for them selves in recovered technical debt.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions


      Back | FazBrowse Home | New Git URL