|
From: Jay P. <pa...@gm...> - 2007-01-26 17:50:06
|
On 1/26/07, John Hunter <jdh...@ac...> wrote:
> >>>>> "Jay" == Jay Parlar <pa...@gm...> writes:
>
> Jay> That's the problem, I believe. 'imread' in mpl always reads
> Jay> images in as MxNx4, while Matlab will check if the image is
> Jay> B&W and just do MxN. Is there any way to force MxN behaviour
> Jay> in mpl?
>
> No way currently, but one could modify the png reader to do it....
> Probably easiest is to use PIL and get a grayscale numpy array out,
> then mpl's colormapping and normalization will work as advertised.
Beautiful, that worked like a charm.
from PIL import Image
im = Image.open("4kSnake.png")
a = scipy.asarray(im)
ft = fftpack.fftshift(fftpack.fft2(a))
...
Perfect!
Thanks so much,
Jay P.
|