Dear members, in order to convolve a greyscale image with a gaussian I used FFTW (release 3.1.1) to work in fourier domain. In detail my initial data is lying on a 1000x10000 point grid, correspondingly I've put the gaussian bell on a 1000x1000 grid too. The gaussian distribution is normalized (i.e. integration over complete 2D equals 1) and centered on the grid around (500.5, 500.5). After transforming both via complex-to-complex 2D dft to fourier domain, complex multiplication and subsequent backward trafo are performed. Since the input is real (data and gaussian), the output is real too. The output shows the favoured, low-pass filtered features like unsharpening, but two problems occur: - the image is cut in four congruent, quadratic sections each of them shifted to the opposite corner, i.e. if the quadrants of the initial image are numbered 1-2-3-4, the corresponding order in the output image is 3-4-1-2. - the absolute values of the output data is several orders of magnitude larger than in the input, even though I scaled the output with 1/N^2 (where N=1000 is the number of grid points per axis). I feel like this point has sth. to do with the variance of the chosen gaussian. Thanks in advance for any help on this. Greetings J.Norpoth
Low-pass filtering via FFTW: artefacts and wrong scaling
Started by ●May 2, 2006