On Wed, Jul 2, 2008 at 17:14, Mike Sarahan <[EMAIL PROTECTED]> wrote:
> I agree that the components are very small, and in a numeric sense, I
> wouldn't worry at all about them, but the image result is simply noise,
> albeit periodic-looking noise.
>
> Here's a code snippet:
> ----------------------------------------
> import numpy,Image
>
> img=Image.open('LlamaTeeth.jpg')
> arr=numpy.asarray(img)
> fftarr=numpy.fft.fftn(arr)
> ifftarr=numpy.fft.ifftn(fftarr)
> img2=Image.fromarray(ifftarr)
>
> img2.show()
> ----------------------------------------
> Please try it on an image that you have lying around.Image.fromarray() does not know much about numpy dtypes other than uint8, bool_, uint32, and float32. Cast (the real component of) the array to a uint8 array and then use Image.fromarray(). -- Robert Kern "I have come to believe that the whole world is an enigma, a harmless enigma that is made terrible by our own mad attempt to interpret it as though it had an underlying truth." -- Umberto Eco _______________________________________________ Numpy-discussion mailing list [email protected] http://projects.scipy.org/mailman/listinfo/numpy-discussion
