Re: [Matplotlib-users] Question about imshow

2009-05-18 Thread Andrew Straw
John Hunter wrote: > On Sun, May 17, 2009 at 11:07 PM, Jae-Joon Lee wrote: > >> I think one possible solution would be to simply deprecate the support >> for PIL image in imshow, and let users explicitly use array-interface >> via asarray function. >> >> Is there any other idea? >> I'll make this

Re: [Matplotlib-users] Question about imshow

2009-05-18 Thread John Hunter
On Sun, May 17, 2009 at 11:07 PM, Jae-Joon Lee wrote: > I think one possible solution would be to simply deprecate the support > for PIL image in imshow, and let users explicitly use array-interface > via asarray function. > > Is there any other idea? > I'll make this change unless someone come u

Re: [Matplotlib-users] Question about imshow

2009-05-17 Thread Jae-Joon Lee
> > I think the point here is that > >        img = Image('foo.png') >        imshow(img) > > and > >        img = Image('foo.png') >        imshow(asarray(img)) > > give different results, since matplotlib.image.pil_to_array functions > differently from what PIL exposes in __array_interface__ > >

Re: [Matplotlib-users] Question about imshow

2009-05-17 Thread Pauli Virtanen
Sun, 17 May 2009 00:15:48 -0400, Jae-Joon Lee wrote: > On Sat, May 16, 2009 at 6:58 PM, > wrote: >> >> Hi, >> I want to read images and do some processing with them. While learning >> how to do this, i.e. opening images, displaying them, transforming them >> tu numpy arrays, etc., I came across

Re: [Matplotlib-users] Question about imshow

2009-05-16 Thread Jae-Joon Lee
On Sat, May 16, 2009 at 6:58 PM, wrote: > > Hi, > I want to read images and do some processing with them. While learning how to > do this, i.e. opening images, displaying them, transforming them tu numpy > arrays, etc., I came across a strange behaviour. If I open an image and use > imshow() t

[Matplotlib-users] Question about imshow

2009-05-16 Thread jorgesmbox-ml
Hi, I want to read images and do some processing with them. While learning how to do this, i.e. opening images, displaying them, transforming them tu numpy arrays, etc., I came across a strange behaviour. If I open an image and use imshow() to display it, it comes upside down. See this thread i

Re: [Matplotlib-users] Question about imshow and matshow

2007-03-15 Thread Antonino Ingargiola
On 3/15/07, Pellegrini Eric <[EMAIL PROTECTED]> wrote: > Hello everybody, > > when using matplotlib, any plot I create is displayed separately from my > Tkinter application. Is there a direct way to embed the plot created by > matplotlib in a widget such as a canvas using something like "create_ima

[Matplotlib-users] Question about imshow and matshow

2007-03-15 Thread Pellegrini Eric
Hello everybody, when using matplotlib, any plot I create is displayed separately from my Tkinter application. Is there a direct way to embed the plot created by matplotlib in a widget such as a canvas using something like "create_image" or something else ? Currently, the only thing I managed

Re: [Matplotlib-users] question about imshow

2006-12-12 Thread Eric Firing
This slightly modified excerpt from the new version of spy may do what you want: nr, nc = Z.shape extent = [-0.5, nc-0.5, nr-0.5, -0.5] return self.imshow(Z, interpolation='nearest', extent=extent, origin='upper') Eric John Travers wrote: > Hi, I'm struggling to get an

Re: [Matplotlib-users] question about imshow

2006-12-12 Thread John Travers
On 12/12/06, Pierre GM <[EMAIL PROTECTED]> wrote: > On Tuesday 12 December 2006 06:57, John Travers wrote: > > Hi, I'm struggling to get an array plotted the way I want with imshow. > > I have an array A which i try to plot with > > > > e=(tdims[0], tdims[-1], wldims[-1], wldims[0]) > > imshow(A,ex

Re: [Matplotlib-users] question about imshow

2006-12-12 Thread Pierre GM
On Tuesday 12 December 2006 06:57, John Travers wrote: > Hi, I'm struggling to get an array plotted the way I want with imshow. > I have an array A which i try to plot with > > e=(tdims[0], tdims[-1], wldims[-1], wldims[0]) > imshow(A,extent=e) > > if I set extent correctly, the image is scaled >

[Matplotlib-users] question about imshow

2006-12-12 Thread John Travers
Hi, I'm struggling to get an array plotted the way I want with imshow. I have an array A which i try to plot with e=(tdims[0], tdims[-1], wldims[-1], wldims[0]) imshow(A,extent=e) The image displays fine in the x axis, with tdims marked correctly, but in the yaxis the dimensions are incorrect. An