Page 1 of 1

possible bugs with PNG and/or FFT IM 6.6.7.0

Posted: 2011-01-14T19:58:56-07:00
by fmw42
IM 6.6.7.0 Q16 (hdri) Mac OSX Tiger (G4 processor)

Please see viewtopic.php?f=1&t=17826#p67577


I can confirm this issue:


time convert logo: -fft logo_fft.png

real 0m25.119s
user 0m22.371s
sys 0m0.724s

The above only creates one image (the phase) with no numbers appended as -0, -1

time convert logo: -fft logo_fft_%d.png

real 0m25.188s
user 0m22.121s
sys 0m0.744s

The above produces two images - one magnitude and one phase


time convert logo_fft_0.png logo_fft_1.png -ift logo_rt.png

The above cancelled after 6+ minutes

real 6m44.251s
user 6m6.444s
sys 0m3.074s


time convert logo: -fft -ift logo_rt2.png

real 0m37.813s
user 0m34.333s
sys 0m0.628s

Seems to produce a reasonable result, though padded due to not being square dimensions (as to be expected)



time convert logo: -fft logo_fft.tiff

real 0m3.110s
user 0m1.781s
sys 0m0.384s


The above produces two frames but both are the phase.



time convert logo: -fft logo_fft_%d.tiff

real 0m2.784s
user 0m1.777s
sys 0m0.376s


The above produces two frames but both are the phase.


time convert logo: -fft logo_fft.pfm

real 0m2.523s
user 0m1.459s
sys 0m0.337s

the above produces two frames (one magnitude and one phase)


time convert logo_fft.pfm[0] logo_fft.pfm[1] -ift logo_rt3.pfm

real 0m1.905s
user 0m0.963s
sys 0m0.364s


The above seems to work in reasonable time and produces a reasonable result



Glenn and/or Magick,

If you need a better test image, I would use the square31.png image.

Image

If you need further help testing, let me know. I can produce the magnitude and phase images from the square31.png image, but need to switch from HDRI to normal Q16 first.

Fred

Re: possible bugs with PNG and/or FFT IM 6.6.7.0

Posted: 2011-01-15T10:34:43-07:00
by magick
We can reproduce the problem you posted and have a fix in ImageMagick 6.6.7-1 Beta by sometime tomorrow. Thanks.

Re: possible bugs with PNG and/or FFT IM 6.6.7.0

Posted: 2011-01-21T13:46:56-07:00
by fmw42
IM 6.6.7.1 Q16 Mac OSX Tiger

The problem with the creation of the magnitude and phase images above seems to be fixed.

However, the timings have doubled since IM 6.6.7.0 and ift from pngs is still taking an incredibly long time and had to be cancelled after about 6 minutes.


PNG:
time convert logo: -fft logo_fft.png
real 0m50.607s
user 0m45.016s
sys 0m0.689s

time convert logo: -fft logo_fft_%d.png
real 0m48.490s
user 0m45.050s
sys 0m0.646s


time convert logo_fft_0.png logo_fft_1.png -ift logo_rt.png
Cancelled after about 6 minutes
real 5m57.028s

user 5m26.467s
sys 0m2.257s


Note that this works quickly:

time convert logo: logo.png
real 0m0.810s
user 0m0.545s
sys 0m0.061s




TIFF:
time convert logo: -fft logo_fft.tiff
real 0m2.385s
user 0m1.654s
sys 0m0.309s


time convert logo_fft.tiff -ift logo_fft_ift.tiff
real 0m1.864s
user 0m1.300s
sys 0m0.320s


So it seems to be an oddity with doing -fft and -ift with PNG images only.

Re: possible bugs with PNG and/or FFT IM 6.6.7.0

Posted: 2011-01-25T11:18:56-07:00
by fmw42
Moved to new bug at viewtopic.php?f=3&t=17925