Author Topic: Gaussian vs Wavelets  (Read 6082 times)

Offline RBA

  • PixInsight Guru
  • ****
  • Posts: 511
    • DeepSkyColors
Gaussian vs Wavelets
« on: 2010 May 03 14:06:09 »
Understanding a Gaussian blur as a low-pass filter that attenuates high-frequency signal...
And understanding a wavelets operation that removes structures in the, say, 1-4 layers also as a low-pass filter that in this case removes small-scale structures ...

What are, especially in practical terms, the differences from using the wavelets method or the Gaussian blur method?

For example, using the example I mentioned in the thread about layers, I tried to apply it first using wavelets, then, out of curiosity, I did the same thing using a Gaussian filter instead. Everything else was the same...

Visually, the results were pretty much identical. However, I then took the three images (the original, the processed via wavelets and the one done with a Gaussian filter) and applied an aggressive stretch with an inverted b/w image, trying to make the histogram adjustment to produce images as similar as possible, and this is what I've got:



What I see up there is that the structures I'm interested in (the faint stuff above the arches) is almost identical in the original and multiscale images - which would lead me to think that the multiscale approach didn't invent anything. OTOH, the image processed with the Gaussian blur does present obvious differences.

This is most likely from having applied a Gaussian blur that is not an exact equivalent to the wavelet operation (meaning the high frequencies I suppressed with the Gaussian filter do not match the scales removed with the wavelets), so I cannot come to any conclusion. And that's where the above question comes to be. Any thoughts?
« Last Edit: 2010 May 03 15:18:19 by RBA »

Offline Carlos Milovic

  • PTeam Member
  • PixInsight Jedi Master
  • ******
  • Posts: 2172
  • Join the dark side... we have cookies
    • http://www.astrophoto.cl
Re: Gaussian vs Wavelets
« Reply #1 on: 2010 May 03 14:58:27 »
Wavelets may be understood as a series of low pass filters. You have the original image, now blur ir (whatever filter you want). The difference between both images is your first layer. Now, you have several options: downsample the image, and blur it with the same filter (again, the difference with the original, after upsampling, is the 2nd layer). Or, you may increase the filter size, without downsampling the image. The ÀTrousWavelets algorithm works following the second rule. Filters are expanded inserting holes between their coefficients.
So, If you use a gaussian filter as function in the wavelets tool, it is exactly the same as a gaussian filter for a first layer supression. Subsecuent layer remotions are more tricky to identify, but roughly is the same thing.
Regards,

Carlos Milovic F.
--------------------------------
PixInsight Project Developer
http://www.pixinsight.com

Offline Silvercup

  • PixInsight Addict
  • ***
  • Posts: 187
Re: Gaussian vs Wavelets
« Reply #2 on: 2010 May 05 14:09:59 »
Hi Rogelio:

I'll bet for wavelets. Anyway I'm learning about Retinex algorithm that is like wavelets transformation.

could you upload this crop in FIT to try a few things?

A greeting. Silvercup.


Offline vicent_peris

  • PTeam Member
  • PixInsight Padawan
  • ****
  • Posts: 988
    • http://www.astrofoto.es/
Re: Gaussian vs Wavelets
« Reply #3 on: 2010 May 05 14:19:38 »
Hi,

One major advantage of the À trous algorithm is that if you add all the layers plus the residual layer you get the original image. This can be a real advantage under some circumstances.


V.

Offline RBA

  • PixInsight Guru
  • ****
  • Posts: 511
    • DeepSkyColors
Re: Gaussian vs Wavelets
« Reply #4 on: 2010 May 05 15:42:13 »
Thanks everyone.

I understand the strength and flexibility of working with wavelets versus a much simpler Gaussian filter (of course, some things might be just easier using a Gaussian filter, say, blurring a mask). My question was more of practical terms in one particular example:

Eliminating layers 1-4 via wavelets
vs
Using a Gaussian filter adjusted so that it filters out the equivalent frequencies/scales as the above wavelets operation.

What differences should I expect in the result?

Silver, I don't have a FIT/TIFF of that particular jpg (I saved as jpg and discarded it), but I can either replicate it (not hard), or give you the raw master file of the mosaic that covers that part of the sky so you can play with it anyway you want. Or something in between. Let me know.

Offline Silvercup

  • PixInsight Addict
  • ***
  • Posts: 187
Re: Gaussian vs Wavelets
« Reply #5 on: 2010 May 05 16:47:44 »
Hi Rogelio:

I guess that if Gaussian filter is 100% equivalent to removing layers 1-4 the result will be identical. All the proofs I have done in multiscale processing indicate that this type of procedure is not "inventing" anything.

What I don't know is where do you want to go. What do you want to do?

Best. Silvercup

Offline RBA

  • PixInsight Guru
  • ****
  • Posts: 511
    • DeepSkyColors
Re: Gaussian vs Wavelets
« Reply #6 on: 2010 May 07 08:56:59 »
What I don't know is where do you want to go. What do you want to do?

I don't really want to do anything, I just want to know whether a situation like the one I presented can also be done with identical results just by using a simple Gaussian filter, that's all.