2 andcolumn2 thuswedonotneedtocomputedftfor

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: If M N 1024 1024 • Direct 2‐D DFT 1012 multiplication • FFT 2 107 multiplication ECE 6258 Fall 2012 Computing DFT of Real Images f [m, n] • If is real, its DFT is Hermitian‐Symmetric F [k , l ] F [(( k )) M , (( l )) N ] • Considering the columns of , this means that the F [k , l ] M 1 DFT values in Column are equal to the values in Column 1 ( reversal + conjugated ) • Similar relation exists between values in Column M 2 and Column 2 • Thus we do not need to compute DFT for Saving of 5 orders of magnitude! k Ghassan AlRegib © Georgia Tech ECE 6258 Fall 2012 33 Computing DFT of Real Images • We can further reduce the computation of each row by having two values at a time. • We start from the rows of the image. We process each two rows in one shot: f [ n] g[ n] • Let and be two rows, i.e. two real sequence of length N H [ n ] f [ n ] j g [ n] • Let complex Ghassan AlRegib © Georgia Tech ECE 6258 Fall 2012 34 Computing DFT of Real Images Continuing: H [k ] F [k ] jG[k ] ① linearity Property H [(( k )) N ] F [((k )) N ] jG[((k )) N ] DFT g[n] f [ n] But and are real their DFTs are Hermitian symmetric DFT H [((k )) N ] F [k ] jG[k ] ② 1 F [k ] 2 H [ k ] H [(( k ))]N These computation are needed for 0 k N G[ k ] 1 H [ k ] H [((k ))]N 2 2j real Ghassan AlRegib © Georgia Tech M M 1, 2, , M 1 2 2 35 Ghassan AlRegib © Georgia Tech 36 9 9/13/2012 Summary ECE 6258 Fall 2012 • Row‐Column Operator 1. For complex sequences, for each two rows h[n] f [n] jg[ n] N saving 2 DFT in Matrix Form ECE 6258 Fall 2012 • Q: How can we write the DFT in a matrix form? 2 nm j • A: We define the matrix U 1 e M (M N ) M • For , 44 rows 2 j 0 1 e 4 U 4 j 2 0 e 4 j 2 0 e 4 2. For the real rows, apply DFT to columns but to half of them M saving 2 Ghassan AlRegib © Georgia Tech 37 DFT in Matrix Form ECE 6258 Fall 2012 • Now, we can compute the DFT of image as F f F UfU • We could simplify as follows: U 44 1 1 j 1 1 e 2 U 4 1 e j 3 j 1 e 2 1 e j e j 2 e j 3 1 1 1 3 j j e 2 1 1 e 2 e j 3 4 1 e j 9 3 j j 1 e 2 e 2 Ghassan AlRegib © Georgia Tech j 2 0 e 4 1 e j 1 e j 1 3 j e 2 e j j e 2 39 Symmetric ( ) UT U 2 j 0 e4 e j 2 1 4 e j 2 2 4 j 2 3 4 e e e j 2 0 4 e j 2 2 4 e j 2 4 4 j 2 .6 4 e e Ghassan AlRegib © Georgia Tech e 2 0 4 j 2 3 4 j 2 6 4 j 2 9 4 38 DFT in Matrix Form ECE 6258 Fall 2012 • But e j e j 2 cos 2 j sin 2 j e j cos j sin 1 e 3 j 2 3 3 cos j sin j 2 2 1 1 1 1 1 1 j 1 j U 4 1 1 1 1 1 j 1 j Ghassan AlRegib © Georgia Tech 40 10 9/13/2012 DFT in Matrix Form ECE 6258 Fall 2012 • Now 0 0 f 0 0 0 0 0 0 1 1 1 1 0 1 0 fU 1 1 0 4 1 0 1 1 1 1 1 1 1 1 1 4 4 1 1 0 0 1 UfU 16 0 0 1 1 0 0 Rotation Example ECE 6258 Fall 2012 4 4 0 0 0 0 0 0 • Exercise: Use the DFT equation to verify the result above Ghassan AlRegib © Georgia Tech Proof of Rotation ECE 6258 Fall 2012 F [k , l ] 41 1 N2 f [m, n]e m n j 1 ˆ ˆ F [ , ] 2 N m r cos , n r sin k cos , l sin N2 f [r , ]e j 2 r cos( ) N Ghassan AlRegib © Georgia Tech Proof of Rotation ECE 6258 Fall 2012 ˆ mk nl r cos cos sin cos r cos( ) 1 42 ˆ • Rotate by to get f f 2 ( mk nl ) N • Polar Coordinator: ˆ F [ , ] Ghassan AlRegib © Georgia Tech 1 N2 f [r , 0 ]e j 2 r cos( ) N 0 2 j r cos( ( 0 )) f [ r , ]e N • DFT of rotated image by rotated DFT of by 43 Ghassan AlRegib © Georgia Tech 44 11 9/13/2012 ECE 6258 Fall 2012 Display of DFT F [k , l ] • Let be the DFT of f [m, n] • Let D[k , l ] log10 (1 | F [k , l ] |) Reduce the range between MIN and MAX • We display as a grey image as follows: D D[k , l ] Dmin 1 Dnear [k , l ] 255 2 Dmax Dmin To ensure nearest integer Ghassan AlRegib © Georgia Tech 45 12...
View Full Document

Ask a homework question - tutors are online