Lecture 10 Unit2
Lecture 10 Unit2
(Code: 455)
• Unitary transform
• Separable transform
• Kronecker Product
• 1D and 2D
• Separable DFT
𝑎0,1 𝐵 … 𝑎0,𝑀2 𝐵
𝐴⨂𝐵 = ⋮ ⋱ ⋮
𝑎𝑀1−1,0 𝐵 … 𝑎𝑀1−1,𝑀2−1 𝐵
If 𝑀1 = 𝑀2 = 𝑁1 = 𝑁2 = 𝑁
Computational complexity?? Fast image transforms
Validation using Basis images
𝑢 1,0 = 𝑎∗ 0,1 𝑣 0,0 𝑎∗ 0,0 + 𝑎∗ 0,1 𝑣 0,1 𝑎∗ 1,0 + 𝑎∗ 1,1 𝑣 1,0 𝑎∗ 0,0 +
𝑎∗ 1,1 𝑣 1,1 𝑎∗ 1,0
1 3
= 2+ 3 +⋯
2 2
𝑁−1 𝑁−1
∗
Verification using: 𝑢 𝑚, 𝑛 = 𝑣 𝑘, 𝑙 𝑎𝑘,𝑙 𝑚, 𝑛
𝑘=0 𝑙=0
Basis images
• Energy Conservation
𝑣 = 𝐴𝑢
𝑁−1
𝑣 2 = 𝑣(𝑘) 2 = 𝑣Ԧ ∗𝑇 𝑣Ԧ
𝑘=0
• Energy compaction
• Decorrelation
Introduction
• 1-D Unitary transform
𝑁−1
𝑣 𝑘 = 𝑢 𝑛 𝑎(𝑘, 𝑛) 0 ≤ 𝑘 ≤ 𝑁 − 1
𝑛=0
Transformation matrix Forward transformation
to be chosen
appropriately 𝑁−1
𝑣 𝑘 = 𝑢 𝑛 𝑊𝑁𝑘𝑛
𝑛=0
−𝑗2𝜋
where, 𝑒𝑥𝑝 = 𝑊𝑁
𝑁
Inverse DFT
• Then the inverse DFT will be defined as:
𝑁−1
𝑢 𝑛 = 𝑣 𝑘 𝑊𝑁−𝑘𝑛
𝑘=0
𝑣 𝑘 = 𝑢 𝑛 𝑊𝑁𝑘𝑛
𝑛=0
𝑁−1
1
𝑢 𝑛 = 𝑣 𝑘 𝑊𝑁−𝑘𝑛
𝑁
𝑘=0
Unitary DFT
• Unitary forward and reverse DFT equations are defined as
𝑁−1
1
𝑣 𝑘 = 𝑢 𝑛 𝑊𝑁𝑘𝑛
√𝑁 𝑛=0
𝑁−1
1
𝑢 𝑛 = 𝑣 𝑘 𝑊𝑁−𝑘𝑛
√𝑁 𝑘=0
Using matrix notation
1
𝑣Ԧ = F𝑢 where, F = 𝑊𝑁𝑘𝑛
√𝑁
Is matrix used for DFT Unitary?
1 1 … 1
𝑣(0) 2𝜋 2𝜋 𝑢(0)
−𝑗 𝑁 ×1 −𝑗 𝑁 ×(𝑁−1)
⋮ 1 𝑒 … 𝑒 ⋮
1 2𝜋 2𝜋
𝑣(𝑘) = 1 𝑒 −𝑗 𝑁 ×2
… 𝑒 −𝑗 𝑁 ×2(𝑁−1) 𝑢(𝑛)
⋮ √𝑁 ⋮
⋮ ⋮ ⋱ ⋮
𝑣(𝑁 − 1) 2𝜋
−𝑗 𝑁 ×(𝑁−1)
2𝜋
−𝑗 𝑁 × 𝑁−1 2
𝑢(𝑁 − 1)
1 𝑒 … 𝑒
𝑣 𝑘, 𝑙 = 𝑢 𝑚, 𝑛 𝑊𝑁𝑘𝑚+𝑙𝑛
𝑚=0 𝑛=0
where, 0 ≤ 𝑘, 𝑙 ≤ 𝑁 − 1
Reverse transformation
𝑁−1 𝑁−1
− 𝑘𝑚+𝑙𝑛
𝑢 𝑚, 𝑛 = 𝑣 𝑘, 𝑙 𝑊𝑁
𝑘=0 𝑙=0
where, 0 ≤ 𝑚, 𝑛 ≤ 𝑁 − 1
Separable 2-D DFT
𝑁−1 𝑁−1
1
𝑣 𝑘, 𝑙 = 𝑢 𝑚, 𝑛 𝑊𝑁𝑘𝑚+𝑙𝑛
𝑁
𝑚=0 𝑛=0
𝑁−1 𝑁−1
1
𝑣 𝑘, 𝑙 = 𝑢 𝑚, 𝑛 𝑊𝑁𝑘𝑚 𝑊𝑁𝑙𝑛
𝑁
𝑚=0 𝑛=0
𝑁−1 𝑁−1
1
𝑣 𝑘, 𝑙 = 𝑊𝑁𝑘𝑚 𝑢 𝑚, 𝑛 𝑊𝑁𝑙𝑛
𝑁
𝑚=0 𝑛=0
Significance of Separability
𝑁−1 𝑁−1
1
𝑣 𝑘, 𝑙 = 𝑊𝑁𝑘𝑚 𝑢 𝑚, 𝑛 𝑊𝑁𝑙𝑛
𝑁
𝑚=0 𝑛=0
𝑁−1
1-D case: 𝑣 𝑘 = 𝑢 𝑛 𝑊𝑁𝑘𝑛
𝑛=0
Using the 1D analogy
𝑁−1
𝑣 𝑚, 𝑙 = 𝑢 𝑚, 𝑛 𝑊𝑁𝑙𝑛
𝑛=0
𝑁−1
1
𝑣 𝑘, 𝑙 = 𝑣 𝑚, 𝑙 𝑊𝑁𝑘𝑚
𝑁
𝑚=0
Visualization of separability
(0,0) (0,0)
Transform over 𝑙
𝑛
column for
each row
𝒖(𝒎, 𝒏) 𝒗(𝒎, 𝒍)
𝑚 Input image 𝑚
(0,0) Transform
𝑙 over rows
for each
𝒗(𝒌, 𝒍) columns
𝑘 DFT image
Magnitude and Phase of DFT
Matrix of Complex values: a + 𝑗𝑏
Magnitude:
Phase:
Reconstructed only
using the
magnitude
Image Transforms