On Tue, Oct 5, 2010 at 6:48 AM, Ensitof <ensieta.le...@gmail.com> wrote:
>
> Dear all,
>
> Please find here a really really stupid script for example purpose..
>
> I was developping some Image processing steps using matplotlib 0.99 and
> everything worked find... However, I upgraded my tools yesterday, and
> installed the 1.0.0 version.
>
> The "imshow" still work fine and gives me the expected figure. BUT the same
> matrix saved in a png file via the "imsave" method is leading to surprising
> results... Looks like the colums and lines are shifted when the png is
> beeing filled. (Clearly visible when comparing the result of imshow and
> opening the produced "test.png" file).
>
> Am I missing something stupid? Did something change between v0.99 and
> v.1.00? I don't think so by looking the doc...
>
> -----------------------------------------
> import numpy as np
> import matplotlib.pyplot as plt
>
>
> test=np.array([[0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,3],[0,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3]])
> plt.figure()
> plt.imshow(test)
>
> plt.imsave("test.png",test)
> ------------------------------------------
> Thanks a lot for your help, this is really a problem for my application.
>
> Christophe
>
Christophe,
I do recall an off-by-one-pixel error being fixed at some point, but I don't
remember if that was before or after the version 1.0 release. Have you
tried the latest matplotlib from SVN to see if the problem still persists?
Ben Root
------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 & L3.
Spend less time writing and rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users