Intelligent Systems
Exercise 3: Energy Minimization techniques
Energy Minimization techniques
Outline:
1. Energy Minimization (example – segmentation) 2. Iterated Conditional Modes
3. Dynamic Programming 4. Block-ICM
5. MinCut
6. Equivalent transformations + 𝛼-expansion
Energy Minimization (Segmentation)
Energy Minimization
Iterated Conditional Modes
Idea: choose (locally) the best label for the fixed rest [Besag, 1986]
Repeat:
extremely simple, parallelizable
coordinate-wise optimization, does not converge to the global optimum even for very simple energies
Dynamic Programming
Suppose that the image is one pixel high → a chain
The goal is to compute
Dynamic Programming – example
Dynamic Programming
General idea – propagate Bellman functions by
The Bellman functions represent the quality of the best expansion onto the processed part.
Dynamic Programming (algorithm)
is the best predecessor for -th label in the -th node Time complexity –
Iterated Conditional Modes (again, but now 2D)
Fix labels in all nodes but for a chain (e.g. an image row) Before (simple)
→
The “auxiliary” task is solvable exactly and efficiently by DP
MinCut
MinCut for Binary Energy Minimization
Search techniques
𝛼-expansion
𝛼-expansion
After 𝛼-expansion we have ↓ but we need ↓
in order to transform it further to MinCut.
What to do ?
Equivalent Transformation (re-parameterization)
Two tasks and are equivalent if
holds for all labelings .
− equivalence class (all tasks equivalent to ).
Equivalent transformation:
Equivalent Transformation
Equivalent transformation can be seen as “vectors”, that satisfy certain conditions:
Back to 𝛼 -expansion
Remember out goal:
It can be done by equivalent transformations – below is the sketch how to transform it to the “canonical form”
𝑔 𝑦𝑟, 𝑦𝑟′ = 𝜃𝑟𝑦𝑟 + 𝜃𝑟𝑟′𝑦𝑟𝑦𝑟′ + 𝜃𝑟′𝑦𝑟′
For MinCut it should be transformed (similarly) to
Some example tasks
A (simple) Energy Minimization problem on a chain is given. Solve it using Dynamic Programming – write down the Bellman functions, find the best labelling (see solution draft on the next slide).
An (simple) multi-label Energy Minimization problem is given together with a labelling which should be improved using 𝛼-
expansion. Consider a particular label 𝛼. Draft the corresponding binary Energy Minimization problem as well as the corresponding MinCut graph.
A pairwise function 𝑔(𝑦𝑟, 𝑦𝑟′) over binary variables 𝑦𝑟 ∈ {0,1} and 𝑦𝑟′ ∈ {0,1} is given. Use re-parameterization in order to write it in the canonical form 𝑔 𝑦𝑟, 𝑦𝑟′ = 𝜃𝑟𝑦𝑟 + 𝜃𝑟𝑟′𝑦𝑟𝑦𝑟′ + 𝜃𝑟′𝑦𝑟′ (see the previous slide).
Solution draft for the Dynamic Programming task
3 nodes, 2 edges (a chain), 2 labels.
White – original values for 𝑞 and 𝑔,
Yellow – Bellman functions, the best labelling At labels: “𝑎 + 𝑏 = 𝑐” means:
𝑎 – the original 𝑞-values
𝑏 – the quality for the best labelling so far