2/26/2008 1 4 – Image Pyramids Admin stuff • Change of office hours on Wed 4 th April – Mon 31 st March 9.30‐10.30pm (right after class) Ch f ti /d t fl t l • Change of time/dateoflast class – Currently Mon 5 th May – What about Thursday 8 th May? Projects • Time to pick! • Every group must come and see my in the l f kd i ffi h ! next coupleof weeks during office hours! Spatial Domain Basis functions: Tells you where things are…. ………….. … but no concept of what it is Fourier domain Basis functions: Tells you what is in the image…. … … but not where it is ……… ……… Fourier as a change of basis • Discrete Fourier Transform: just a big matrix • But a smart matrix! http://www.reindeergraphics.com
17
Embed
4 image pyramids - New York Universityfergus/teaching/comp_photo/4_image_pyramids.pdfget the next image by smoothing the image with a Gaussian with sigma 1 pixel, then sampling at
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
2/26/2008
1
4 – Image Pyramids
Admin stuff
• Change of office hours on Wed 4th April – Mon 31st March 9.30‐10.30pm (right after class)
Ch f ti /d t f l t l• Change of time/date of last class– Currently Mon 5th May
– What about Thursday 8th May?
Projects
• Time to pick!
• Every group must come and see my in the l f k d i ffi h !next couple of weeks during office hours!
Spatial Domain
Basis functions:
Tells you where things are….
…………..
… but no concept of what it is
Fourier domainBasis functions:
Tells you what is in the image….…
… but not where it is
………
………
Fourier as a change of basis
• Discrete Fourier Transform: just a big matrix
• But a smart matrix!
http://www.reindeergraphics.com
2/26/2008
2
Low pass filteringhttp://www.reindeergraphics.com High pass filteringhttp://www.reindeergraphics.com
Image Analysis
• Want representation that combines what and where.
idImage Pyramids
Why Pyramid?
….equivalent to….
Keep filters same size
• Change image size• Scale factor of 2
Total number of pixels in pyramid?1 + ¼ + 1/16 + 1/32…….. = 4/3
Over‐complete representation
Practical uses
• Compression– Capture important structures with fewer bytes
• Denoisingd l i i f id b b d– Model statistics of pyramid sub‐bands
Sampling without smoothing. Top row shows the images,sampled at every second pixel to get the next; bottom row shows the magnitude spectrum of these images.
Slide credit: W.T. Freeman
2/26/2008
4
Sampling with smoothing. Top row shows the images. Weget the next image by smoothing the image with a Gaussian with sigma 1 pixel,then sampling at every second pixel to get the next; bottom row shows the magnitude spectrum of these images.
Slide credit: W.T. Freeman
Sampling with more smoothing. Top row shows the images. Weget the next image by smoothing the image with a Gaussian with sigma 1.4 pixels,then sampling at every second pixel to get the next; bottom row shows the magnitude spectrum of these images.
• To avoid ghosting– window <= 2*size of smallest prominent feature
Natural to cast this in the Fourier domainl t f 2* i f ll t f• largest frequency <= 2*size of smallest frequency
• image frequency content should occupy one “octave” (power of two)
FFT
What if the Frequency Spread is Wide
FFT
Idea (Burt and Adelson)• Compute Fleft = FFT(Ileft), Fright = FFT(Iright)• Decompose Fourier image into octaves (bands)
– Fleft = Fleft1 + Fleft
2 + …• Feather corresponding octaves Fleft
i with Frighti
– Can compute inverse FFT and feather in spatial domain• Sum feathered octave images in frequency domain
Better implemented in spatial domain
2/26/2008
8
http://cs.haifa.ac.il/~dkeren/ip/lecture8.pdf
Pyramid Blending
0
1
1
0
0
1
Left pyramid Right pyramidblend
Pyramid Blending laplacianlevel
4
laplacianlevellevel
2
laplacianlevel
0
left pyramid right pyramid blended pyramid
Laplacian Pyramid: Region BlendingGeneral Approach:
1. Build Laplacian pyramids LA and LB from images A and B2. Build a Gaussian pyramid GR from selected region R3. Form a combined pyramid LS from LA and LB using nodes
of GR as weights:• LS(i,j) = GR(I,j,)*LA(I,j) + (1-GR(I,j))*LB(I,j)
4. Collapse the LS pyramid to get the final blended imageCo apse t e S py a d to get t e a b e ded age