Multi-Scale/Multi-Resolution: Wavelet Transfor
Proble with Fourier Fourier analysis -- breaks down a signal into constituent sinusoids of different frequencies. A serious drawback in transforing to the frequency doain, tie inforation is lost. When looking at a Fourier transfor of a signal, it is ipossible to tell when a particular event took place.
Gabor s Proposal: Short Tie Fourier Transfor STFT x ' ' πft ' ' t, f [ x t g t t] e dt Requireents: Signal in tie doain: requires short tie window to depict features of signal. Signal in frequency doain: requires short frequency window long tie window to depict features of signal. 3
Fourier Gabor Wavelet 4
What are Wavelets? Wavelets are atheatical functions that cut up data into different frequency coponents, and then study each coponent with a resolution atched to its scale. They have advantages over traditional Fourier ethods in analyzing physical situations where the signal contains discontinuities and sharp spikes. 5
Wavelets were developed independently in the fields of atheatics, quantu physics, electrical engineering, and seisic geology. Interchanges between these fields during the last ten years have led to any new wavelet applications such as iage copression, turbulence, huan vision, radar, and earthquake prediction. 6
Wavelet algoriths process data at different scales or resolutions. If we look at a signal with a large window, we would notice gross features. Siilarly, if we look at a signal with a sall window, we would notice sall features. 7
The wavelet analysis procedure is to adopt a wavelet prototype function, called an analyzing wavelet or other wavelet. Teporal analysis is perfored with a contracted, highfrequency version of the prototype wavelet, while frequency analysis is perfored with a dilated, low-frequency version of the sae wavelet. 8
Because the original signal or function can be represented in ters of a wavelet expansion using coefficients in a linear cobination of the wavelet functions, data operations can be perfored using ust the corresponding wavelet coefficients. And if we further choose the best wavelets adapted to the data, or truncate the coefficients below a threshold, the data is sparsely represented. This sparse coding akes wavelets an excellent tool in the field of data copression. 9
Another View: Wavelets are functions defined over a finite interval and having an average value of zero. Haar wavelet The first ention of wavelets appeared in an appendix of the thesis of A. Haar 909. One property of the Haar wavelet is that it has copact support, which eans that it vanishes outside of a finite interval. Unfortunately, Haar wavelets are not continuously differentiable which soewhat liits their applications. 0
What is wavelet transfor? The wavelet transfor is a tool for carving up functions, operators, or data into coponents of different frequency, allowing one to study each coponent separately. The basic idea of the wavelet transfor is to represent any arbitrary function ƒt as a superposition of a set of such wavelets or basis functions. These basis functions or baby wavelets are obtained fro a single prototype wavelet called the other wavelet, by dilations or contractions scaling and translations shifts.
The continuous wavelet transfor CWT Fourier Transfor + F ω f t e ωt FT is the su over all the tie of signal ft ultiplied by a coplex exponential. dt
Continuous Wavelet transfor for each Scale for each Position Coefficient S,P Signal x Wavelet S,P all tie end end Coefficient Scale 3
Siilarly, the Continuous Wavelet Transfor CWT is defined as the su over all tie of the signal ultiplied by a scaled and shifted version of the wavelet function Ψ s, τ t : * γ s, τ f t Ψs t dt,τ where * denotes coplex conugation. This equation shows how a function ƒt is decoposed into a set of basis functions Ψ s, τ t, called the wavelets. The variables s and τ are the new diensions, scale and translation position, after the wavelet transfor. 4
The results of the CWT are any wavelet coefficients, which are a function of scale and position 5
The wavelets are generated fro a single basic wavelet Ψt, the so-called other wavelet, by scaling and translation: Ψ s, τ t t τ ψ s s s is the scale factor, τ is the translation factor and the factor s -/ is for energy noralization across the different scales. It is iportant to note that in the above transfors the wavelet basis functions are not specified. This is one of the differences between the wavelet transfor and the Fourier transfor, or other transfors. 6
Scale Scaling a wavelet siply eans stretching or copressing it. 7
Scale and Frequency Low scale a Copressed wavelet Rapidly changing details High frequency ω High scale a stretched wavelet slowly changing details low frequency ω Translation shift Translating a wavelet siply eans delaying its onset. 8
Wavelet Properties ψ ω ω < ω adissibility condition: d + ψ ω stands for the Fourier transfor of ψ t The adissibility condition iplies that the Fourier transfor of ω vanishes at the zero frequency, i.e. ψ ψ ω 0 This eans that wavelets ust have a band-pass like spectru. This is a very iportant observation, which can be used to build an efficient wavelet transfor. A zero at the zero frequency DC coponent also eans that the average value of the wavelet in the tie doain ust be zero, ψ t dt 0 ψ t ust be a wave. ω 0 9
0
3
4
Discrete Wavelets Discrete wavelet is written as ψ, k t t kτ 0s ψ s0 s0 and k are integers and s 0 > is a fixed dilation step. The translation factor τ 0 depends on the dilation step. The effect of discretizing the wavelet is that the tie-scale space is now sapled at discrete intervals. We often choose s 0 0 * ψ, t ψ, t dt k n 0 If and kn others 5
A band-pass filter The wavelet has a band-pass like spectru Fro Fourier theory we know that copression in tie is equivalent to stretching the spectru and shifting it upwards: F a ω a { f at } F Suppose a This eans that a tie copression of the wavelet by a factor of will stretch the frequency spectru of the wavelet by a factor of and also shift all frequency coponents up by a factor of. 6
Scaling-- value of stretch Scaling a wavelet siply eans stretching or copressing it. ft sint scale factor ft sint scale factor ft sin3t scale factor 3 7
To get a good coverage of the signal spectru the stretched wavelet spectra should touch each other. Touching wavelet spectra resulting fro scaling of the other wavelet in the tie doain. Suarizing, if one wavelet can be seen as a band-pass filter, then a series of dilated wavelets can be seen as a bank of band-pass filters. 8
The scaling function Ηow to cover the spectru all the way down to zero? The solution is not to try to cover the spectru all the way down to zero with wavelet spectra, but to use a cork to plug the hole when it is sall enough. This cork then is a low-pass spectru and it belongs to the so-called scaling function. 9
If we look at the scaling function as being ust a signal with a lowpass spectru, then we can decopose it in wavelet coponents and express it like ϕ t γ, k ψ, k, k t adissibility condition for scaling functions ϕ t dt Suarizing once ore, if one wavelet can be seen as a bandpass filter and a scaling function is a low-pass filter, then a series of dilated wavelets together with a scaling function can be seen as a filter bank. 30
Results of wavelet transfor: approxiation and details Low frequency: approxiation a High frequency Details d Decoposition can be perfored iteratively 3
Levels of decoposition Successively decopose the approxiation Level 5 decoposition a5 + d5 + d4 + d3 + d + d No liit to the nuber of decopositions perfored 3
Wavelet synthesis Re-creates signal fro coefficients Up-sapling required 33
Multi-level Wavelet Analysis Multi-level wavelet decoposition tree Reassebling original signal 34
Discrete Wavelet transfor signal lowpass highpass filters Approxiation a Details d 35
Non-stationary Property of Natural Iage 36
The Discrete Wavelet Transfor Calculating wavelet coefficients at every possible scale is a fair aount of work, and it generates an awful lot of data. What if we choose only a subset of scales and positions at which to ake our calculations? It turns out, rather rearkably, that if we choose scales and positions based on powers of two -- so-called dyadic scales and positions -- then our analysis will be uch ore efficient and ust as accurate. We obtain ust such an analysis fro the discrete wavelet transfor DWT. 37
Approxiations and Details The approxiations are the high-scale, low-frequency coponents of the signal. The details are the low-scale, high-frequency coponents. The filtering process, at its ost basic level, looks like this: The original signal, S, passes through two copleentary filters and eerges as two signals. 38
Downsapling Unfortunately, if we actually perfor this operation on a real digital signal, we wind up with twice as uch data as we started with. Suppose, for instance, that the original signal S consists of 000 saples of data. Then the approxiation and the detail will each have 000 saples, for a total of 000. To correct this proble, we introduce the notion of downsapling. This siply eans throwing away every second data point. 39
An exaple: 40
Reconstructing Approxiation and Details Upsapling 4
Pyraidal Iage Structure 4
Iage Pyraids Original iage, the base of the pyraid, in the level J log N, Norally truncated to P+ levels. COMPONENTS: Approxiation pyraids, predication residual pyraids Steps:. Copute a reduced-resolution approxiation fro to - level by downsapling;. Upsaple the output of step, get predication iage; 3. Difference between the predication of step and the input of step. 43
Subband coding Here an iage is decoposed into a set of band liited Coponents, called subbands. Subbands are reassebled to reconstruct the original Iage without ERROR. 44
Subband Coding 45
Subband Coding Filters h n and h n are half-band digital filters, their transfer characteristics H 0 -low pass filter, output is an approxiation of xn and H -high pass filter, output is the high frequency or detail part of xn Criteria: h 0 n, h n, g 0 n, g n are selected to reconstruct the input perfectly. 46
Splitting the signal spectru with an iterated filter bank. 8B LP 4B HP 4B f f LP B HP B 4B f LP B HP B B 4B f Suarizing, if we ipleent the wavelet transfor as an iterated filter bank, we do not have to specify the wavelets explicitly! This is a rearkable result. 47
48 Scaling function two-scale relation k t k h t k + + ϕ ϕ Wavelet k t k g t k + + ϕ ψ The signal ft can be expressed as k t k k t k t f k k + ψ γ ϕ k h k DWT k g k γ
49 k h k k g k γ ] [ k k h k h k ] [ k k g k g k γ
How to calculate DWT given g, h and a signal f? Initialization: f Exaple: f{,4,-3,0}; h n {/,/ } g n { /,/ } f {,4, 3,0} h n {/,/ } g n {/, / } k h k γ k g k + 4 3 0 h h0 0 + h 0 3 h 0 h0 + h 3 3 + 0 5 3 γ γ 3 0 g 0 g0 0 + g + 4 3 g g0 + g 3 3 + 0 0 3 3 50
5 3 5 0 0 0 0 + + h h h 4 3 5 0 0 0 0 + + g g g γ
5 Wavelet Reconstruction Synthesis Perfect reconstruction : ' ' + H H G G ' ' n g n h n h n g n n + +
53 0 4 0 γ,0 4,0 x y 0 / 0 0 / 0 0 0 ' ' ' ' ' ' + x h h h x h h x k h k x { } 3/, 5/ { } 3/, 3/ γ 0 4 / 0 0 4 / 0 0 0 ' ' ' ' ' ' + y g g g y g g y k g k y γ γ γ γ γ γ
-D Discrete Wavelet Transfor A -D DWT can be done as follows: Step : Replace each row with its -D DWT; Step : Replace each colun with its -D DWT; Step 3: repeat steps and on the lowest subband for the next scale Step 4: repeat steps 3 until as any scales as desired have been copleted L H LL LH HL HH LH HL HH original One scale two scales 54
-D 4-band filter bank Approxiation Vertical detail Horizontal detail Diagonal details 55
Subband Exaple 56
Lossy Copression Based on spatial redundancy Measure of spatial redundancy: D covariance Cov X i, σ e -α i*i+* Vertical correlation ρ Horizontal correlation ρ E[Xi,Xi-,] E[X i,] E[Xi,Xi,-] E[X i,] For iages we assue equal correlations Typically e -α ρ ρ 0.95 Measure of loss or distortion: MSE between encoded and decoded iage 57
Rate-Distortion Function Tradeoff between bit rate R of copressed iage and distortion D R easured in its per encoder output sybol Copression ratio encoder input bits/r D noralized by the variance of the encoder input Possible SNR definition 0 log 0 D - For iages that can be odeled as uncorrelated Gaussian RD0.5log D - 58
Saple vs. Block-based Coding Saple-based In spatial or frequency doain Like the JPEG-LS Make a predictor function often weighted su Copute and quantize residual Encode Block-based Spatial: group pixels into blocks, copress blocks Transfor: group into blocks, transfor, encode 59
Copression and Subband Coding Pass an iage through an n-band filter bank Possibly subsaple each filtered output Encode each subband separately Copression ay be achieved by discarding uniportant bands Advantages Fewer artifacts than block-coded copression More robust under transission errors Selective encoding/decoding possible More expensive 60