vcmohan
23rd February 2006, 04:19
Some time back probably in FIZICK's defreq filter thread,some one suggested filtering in freq domain row by row with one dimensional transform instead of using 2d transform. Fizick replied that processing row by row introduces some artifacts. In oil exploration seismic data is routinely processed trace by trace with 1d fft equivalent to row by row process on the image. There artifacts cannot be tolerated. So I wanted to reply but clean forgot due to other work I was engaged in. Recently I came across kiss_fft by Mark Borgdering(and I am grateful for his source code ), and thought to try some ideas. I wrote a plugin FQuiver with two functions. One named 'FQ1Row' for processing row by row and the other 'FQ2d' to process 2d image data in freq domain. This was done so as to complement fizick's defreq. The FFT computation does not need any outside dll support.
I have processed an image which appeared in one of the threads and for which sometime back I developed FanFilter in time domain. The image below is the F1Row test output:
http://img84.imageshack.us/img84/5997/sg1fq1row09hh.th.jpg (http://img84.imageshack.us/my.php?image=sg1fq1row09hh.jpg)
In right top a gamma scaled freq spectrum and below an unscaled spectrum are present. The interfering freq is the sharp peak just a nick above the general freq level, but still clearly seen at 58 Hz. The grey line on top of the spectrum (barely visible as the filter is very gentle) is the filter profile. On left top is the filtered and below is unfiltered image which contains the first row used for spectral display. Using a gaussian notch reject filter ( seen in the right top of image above), gave the following output:
http://img99.imageshack.us/img99/3645/sg1fq1rowfiltered06ys.th.jpg (http://img99.imageshack.us/my.php?image=sg1fq1rowfiltered06ys.jpg)
Then I tried the same input in 2d fft using my new FQ2d filter function. The freq spectrum is on left and unfiltered image on right:
http://img99.imageshack.us/img99/5384/sg1fq2d05rp.th.jpg (http://img99.imageshack.us/my.php?image=sg1fq2d05rp.jpg)
The noise frequencies are overwhelmed by the spectral components of the logo, and can not be seen at all. After cropping the logo the following spectrum was obtained.:
http://img62.imageshack.us/img62/451/sg1fq2dcropped01as.th.jpg (http://img62.imageshack.us/my.php?image=sg1fq2dcropped01as.jpg)
Two specs symmetric at 58,-8 and -58,8 can be seen with some difficulty. Gauss notches at these points produced the following image:
http://img62.imageshack.us/img62/3153/sg1fq2dfiltered06bj.th.jpg (http://img62.imageshack.us/my.php?image=sg1fq2dfiltered06bj.jpg)
Filtering by these two proceedures gave almost equivalent images. As the logo is very strong, there are artifacts in both styles of process, but manifest differently. In case of row by row process the artifacts are seen strongly but only in the rows the logo appears, while in 2d case they are manifest as ghosting all over image. After Cropping out the logo, output of FQ1Row was sans artifacts while F2d processing still had ghosting artifacts. This may be as the vertical freq coordinate is close to the axis.
I tried another image, which has very strong overwhelming noise. FQ1Row worked well.
http://img51.imageshack.us/img51/6403/msintrofq1row00ie.th.jpg (http://img51.imageshack.us/my.php?image=msintrofq1row00ie.jpg)
In FQ2d the power spectrum for this image appears as:
http://img65.imageshack.us/img65/2792/msintrofq2d05fe.th.jpg (http://img65.imageshack.us/my.php?image=msintrofq2d05fe.jpg)
In FQ2d the power spectrum after filtering the vertical bars by notch filter (seen as black lines) is below:
http://img51.imageshack.us/img51/5001/msintrofq2dfiltered06tq.th.jpg (http://img51.imageshack.us/my.php?image=msintrofq2dfiltered06tq.jpg)
The vertical bars are the noise components. This required special filter design, which is included in dll.
Both the functions have the capability to effect homomorphic filtering.
A FQ2d Filter buffer display indicates some possible types of filters. All these operate simultaneously (cascaded).
http://img65.imageshack.us/img65/3136/fq2dfilterdisplay20gx.th.jpg (http://img65.imageshack.us/my.php?image=fq2dfilterdisplay20gx.jpg)
This plugin should be available for down loading in the warpenterprises page in a few days as I have uploaded it yesterday. The size of plugin zip file is a bit heavy at 500kb, due to the documentation. The dll unzipped will be about 104 kb only. This makes me to ask a question. Is it preferable to include illustrative images in documentation or provide links to online site such as imageshack?
I have processed an image which appeared in one of the threads and for which sometime back I developed FanFilter in time domain. The image below is the F1Row test output:
http://img84.imageshack.us/img84/5997/sg1fq1row09hh.th.jpg (http://img84.imageshack.us/my.php?image=sg1fq1row09hh.jpg)
In right top a gamma scaled freq spectrum and below an unscaled spectrum are present. The interfering freq is the sharp peak just a nick above the general freq level, but still clearly seen at 58 Hz. The grey line on top of the spectrum (barely visible as the filter is very gentle) is the filter profile. On left top is the filtered and below is unfiltered image which contains the first row used for spectral display. Using a gaussian notch reject filter ( seen in the right top of image above), gave the following output:
http://img99.imageshack.us/img99/3645/sg1fq1rowfiltered06ys.th.jpg (http://img99.imageshack.us/my.php?image=sg1fq1rowfiltered06ys.jpg)
Then I tried the same input in 2d fft using my new FQ2d filter function. The freq spectrum is on left and unfiltered image on right:
http://img99.imageshack.us/img99/5384/sg1fq2d05rp.th.jpg (http://img99.imageshack.us/my.php?image=sg1fq2d05rp.jpg)
The noise frequencies are overwhelmed by the spectral components of the logo, and can not be seen at all. After cropping the logo the following spectrum was obtained.:
http://img62.imageshack.us/img62/451/sg1fq2dcropped01as.th.jpg (http://img62.imageshack.us/my.php?image=sg1fq2dcropped01as.jpg)
Two specs symmetric at 58,-8 and -58,8 can be seen with some difficulty. Gauss notches at these points produced the following image:
http://img62.imageshack.us/img62/3153/sg1fq2dfiltered06bj.th.jpg (http://img62.imageshack.us/my.php?image=sg1fq2dfiltered06bj.jpg)
Filtering by these two proceedures gave almost equivalent images. As the logo is very strong, there are artifacts in both styles of process, but manifest differently. In case of row by row process the artifacts are seen strongly but only in the rows the logo appears, while in 2d case they are manifest as ghosting all over image. After Cropping out the logo, output of FQ1Row was sans artifacts while F2d processing still had ghosting artifacts. This may be as the vertical freq coordinate is close to the axis.
I tried another image, which has very strong overwhelming noise. FQ1Row worked well.
http://img51.imageshack.us/img51/6403/msintrofq1row00ie.th.jpg (http://img51.imageshack.us/my.php?image=msintrofq1row00ie.jpg)
In FQ2d the power spectrum for this image appears as:
http://img65.imageshack.us/img65/2792/msintrofq2d05fe.th.jpg (http://img65.imageshack.us/my.php?image=msintrofq2d05fe.jpg)
In FQ2d the power spectrum after filtering the vertical bars by notch filter (seen as black lines) is below:
http://img51.imageshack.us/img51/5001/msintrofq2dfiltered06tq.th.jpg (http://img51.imageshack.us/my.php?image=msintrofq2dfiltered06tq.jpg)
The vertical bars are the noise components. This required special filter design, which is included in dll.
Both the functions have the capability to effect homomorphic filtering.
A FQ2d Filter buffer display indicates some possible types of filters. All these operate simultaneously (cascaded).
http://img65.imageshack.us/img65/3136/fq2dfilterdisplay20gx.th.jpg (http://img65.imageshack.us/my.php?image=fq2dfilterdisplay20gx.jpg)
This plugin should be available for down loading in the warpenterprises page in a few days as I have uploaded it yesterday. The size of plugin zip file is a bit heavy at 500kb, due to the documentation. The dll unzipped will be about 104 kb only. This makes me to ask a question. Is it preferable to include illustrative images in documentation or provide links to online site such as imageshack?