Probabilistic Inference Lecture 4 – Part 2
description
Transcript of Probabilistic Inference Lecture 4 – Part 2
![Page 1: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/1.jpg)
Probabilistic InferenceLecture 4 – Part 2
M. Pawan [email protected]
Slides available online http://cvc.centrale-ponts.fr/personnel/pawan/
![Page 2: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/2.jpg)
• Integer Programming Formulation
• LP Relaxation and its Dual
• Convergent Solution for Dual
• Properties and Computational Issues
Outline
![Page 3: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/3.jpg)
Things to Remember
• Forward-pass computes min-marginals of root
• BP is exact for trees
• Every iteration provides a reparameterization
![Page 4: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/4.jpg)
Integer Programming Formulation
Va Vb
Label l0
Label l12
5
4
2
0
1 1
0
2Unary Potentials
a;0 = 5
a;1 = 2
b;0 = 2
b;1 = 4
Labellingf(a) = 1
f(b) = 0
ya;0 = 0 ya;1 = 1
yb;0 = 1 yb;1 = 0
Any f(.) has equivalent boolean variables ya;i
![Page 5: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/5.jpg)
Integer Programming Formulation
Va Vb
2
5
4
2
0
1 1
0
2Unary Potentials
a;0 = 5
a;1 = 2
b;0 = 2
b;1 = 4
Labellingf(a) = 1
f(b) = 0
ya;0 = 0 ya;1 = 1
yb;0 = 1 yb;1 = 0
Find the optimal variables ya;i
Label l0
Label l1
![Page 6: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/6.jpg)
Integer Programming Formulation
Va Vb
2
5
4
2
0
1 1
0
2Unary Potentials
a;0 = 5
a;1 = 2
b;0 = 2
b;1 = 4
Sum of Unary Potentials
∑a ∑i a;i ya;i
ya;i {0,1}, for all Va, li∑i ya;i = 1, for all Va
Label l0
Label l1
![Page 7: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/7.jpg)
Integer Programming Formulation
Va Vb
2
5
4
2
0
1 1
0
2Pairwise Potentials
ab;00 = 0
ab;10 = 1
ab;01 = 1
ab;11 = 0
Sum of Pairwise Potentials
∑(a,b) ∑ik ab;ik ya;iyb;k
ya;i {0,1}
∑i ya;i = 1
Label l0
Label l1
![Page 8: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/8.jpg)
Integer Programming Formulation
Va Vb
2
5
4
2
0
1 1
0
2Pairwise Potentials
ab;00 = 0
ab;10 = 1
ab;01 = 1
ab;11 = 0
Sum of Pairwise Potentials
∑(a,b) ∑ik ab;ik yab;ik
ya;i {0,1}
∑i ya;i = 1
yab;ik = ya;i yb;k
Label l0
Label l1
![Page 9: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/9.jpg)
Integer Programming Formulation
min ∑a ∑i a;i ya;i + ∑(a,b) ∑ik ab;ik yab;ik
ya;i {0,1}
∑i ya;i = 1
yab;ik = ya;i yb;k
![Page 10: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/10.jpg)
Integer Programming Formulation
min Ty
ya;i {0,1}
∑i ya;i = 1
yab;ik = ya;i yb;k
= [ … a;i …. ; … ab;ik ….]y = [ … ya;i …. ; … yab;ik ….]
![Page 11: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/11.jpg)
One variable, two labels
ya;0
ya;1
ya;0 {0,1} ya;1 {0,1} ya;0 + ya;1 = 1
y = [ ya;0 ya;1] = [ a;0 a;1]
![Page 12: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/12.jpg)
Two variables, two labels
= [ a;0 a;1 b;0 b;1
ab;00 ab;01 ab;10 ab;11]y = [ ya;0 ya;1 yb;0 yb;1
yab;00 yab;01 yab;10 yab;11]
ya;0 {0,1} ya;1 {0,1} ya;0 + ya;1 = 1
yb;0 {0,1} yb;1 {0,1} yb;0 + yb;1 = 1
yab;00 = ya;0 yb;0 yab;01 = ya;0 yb;1
yab;10 = ya;1 yb;0 yab;11 = ya;1 yb;1
![Page 13: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/13.jpg)
In General
Marginal Polytope
![Page 14: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/14.jpg)
In General
R(|V||L| + |E||L|2)
y {0,1}(|V||L| + |E||L|2)
Number of constraints
|V||L| + |V| + |E||L|2
ya;i {0,1} ∑i ya;i = 1 yab;ik = ya;i yb;k
![Page 15: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/15.jpg)
Integer Programming Formulation
min Ty
ya;i {0,1}
∑i ya;i = 1
yab;ik = ya;i yb;k
= [ … a;i …. ; … ab;ik ….]y = [ … ya;i …. ; … yab;ik ….]
![Page 16: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/16.jpg)
Integer Programming Formulation
min Ty
ya;i {0,1}
∑i ya;i = 1
yab;ik = ya;i yb;k
Solve to obtain MAP labelling y*
![Page 17: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/17.jpg)
Integer Programming Formulation
min Ty
ya;i {0,1}
∑i ya;i = 1
yab;ik = ya;i yb;k
But we can’t solve it in general
![Page 18: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/18.jpg)
• Integer Programming Formulation
• LP Relaxation and its Dual
• Convergent Solution for Dual
• Properties and Computational Issues
Outline
![Page 19: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/19.jpg)
Linear Programming Relaxation
min Ty
ya;i {0,1}
∑i ya;i = 1
yab;ik = ya;i yb;k
Two reasons why we can’t solve this
![Page 20: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/20.jpg)
Linear Programming Relaxation
min Ty
ya;i [0,1]
∑i ya;i = 1
yab;ik = ya;i yb;k
One reason why we can’t solve this
![Page 21: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/21.jpg)
Linear Programming Relaxation
min Ty
ya;i [0,1]
∑i ya;i = 1
∑k yab;ik = ∑kya;i yb;k
One reason why we can’t solve this
![Page 22: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/22.jpg)
Linear Programming Relaxation
min Ty
ya;i [0,1]
∑i ya;i = 1
One reason why we can’t solve this
= 1∑k yab;ik = ya;i∑k yb;k
![Page 23: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/23.jpg)
Linear Programming Relaxation
min Ty
ya;i [0,1]
∑i ya;i = 1
∑k yab;ik = ya;i
One reason why we can’t solve this
![Page 24: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/24.jpg)
Linear Programming Relaxation
min Ty
ya;i [0,1]
∑i ya;i = 1
∑k yab;ik = ya;i
No reason why we can’t solve this *
*memory requirements, time complexity
![Page 25: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/25.jpg)
One variable, two labels
ya;0
ya;1
ya;0 {0,1} ya;1 {0,1} ya;0 + ya;1 = 1
y = [ ya;0 ya;1] = [ a;0 a;1]
![Page 26: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/26.jpg)
One variable, two labels
ya;0
ya;1
ya;0 [0,1] ya;1 [0,1] ya;0 + ya;1 = 1
y = [ ya;0 ya;1] = [ a;0 a;1]
![Page 27: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/27.jpg)
Two variables, two labels
= [ a;0 a;1 b;0 b;1
ab;00 ab;01 ab;10 ab;11]y = [ ya;0 ya;1 yb;0 yb;1
yab;00 yab;01 yab;10 yab;11]
ya;0 {0,1} ya;1 {0,1} ya;0 + ya;1 = 1
yb;0 {0,1} yb;1 {0,1} yb;0 + yb;1 = 1
yab;00 = ya;0 yb;0 yab;01 = ya;0 yb;1
yab;10 = ya;1 yb;0 yab;11 = ya;1 yb;1
![Page 28: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/28.jpg)
Two variables, two labels
= [ a;0 a;1 b;0 b;1
ab;00 ab;01 ab;10 ab;11]y = [ ya;0 ya;1 yb;0 yb;1
yab;00 yab;01 yab;10 yab;11]
ya;0 [0,1] ya;1 [0,1] ya;0 + ya;1 = 1
yb;0 [0,1] yb;1 [0,1] yb;0 + yb;1 = 1
yab;00 = ya;0 yb;0 yab;01 = ya;0 yb;1
yab;10 = ya;1 yb;0 yab;11 = ya;1 yb;1
![Page 29: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/29.jpg)
Two variables, two labels
= [ a;0 a;1 b;0 b;1
ab;00 ab;01 ab;10 ab;11]y = [ ya;0 ya;1 yb;0 yb;1
yab;00 yab;01 yab;10 yab;11]
ya;0 [0,1] ya;1 [0,1] ya;0 + ya;1 = 1
yb;0 [0,1] yb;1 [0,1] yb;0 + yb;1 = 1
yab;00 + yab;01 = ya;0
yab;10 = ya;1 yb;0 yab;11 = ya;1 yb;1
![Page 30: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/30.jpg)
Two variables, two labels
= [ a;0 a;1 b;0 b;1
ab;00 ab;01 ab;10 ab;11]y = [ ya;0 ya;1 yb;0 yb;1
yab;00 yab;01 yab;10 yab;11]
ya;0 [0,1] ya;1 [0,1] ya;0 + ya;1 = 1
yb;0 [0,1] yb;1 [0,1] yb;0 + yb;1 = 1
yab;00 + yab;01 = ya;0
yab;10 + yab;11 = ya;1
![Page 31: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/31.jpg)
In General
Marginal Polytope
LocalPolytope
![Page 32: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/32.jpg)
In General
R(|V||L| + |E||L|2)
y [0,1](|V||L| + |E||L|2)
Number of constraints
|V||L| + |V| + |E||L|
![Page 33: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/33.jpg)
Linear Programming Relaxation
min Ty
ya;i [0,1]
∑i ya;i = 1
∑k yab;ik = ya;i
No reason why we can’t solve this
![Page 34: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/34.jpg)
Linear Programming Relaxation
Extensively studied
Optimization
Schlesinger, 1976
Koster, van Hoesel and Kolen, 1998
Theory
Chekuri et al, 2001 Archer et al, 2004
Machine Learning
Wainwright et al., 2001
![Page 35: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/35.jpg)
Linear Programming Relaxation
Many interesting properties
• Global optimal MAP for trees
Wainwright et al., 2001
But we are interested in NP-hard cases
• Preserves solution for reparameterization
• Global optimal MAP for submodular energy
Chekuri et al., 2001
![Page 36: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/36.jpg)
Linear Programming Relaxation
• Large class of problems
• Metric Labelling• Semi-metric Labelling
Many interesting properties - Integrality Gap
Manokaran et al., 2008
• Most likely, provides best possible integrality gap
![Page 37: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/37.jpg)
Linear Programming Relaxation
• A computationally useful dual
Many interesting properties - Dual
Optimal value of dual = Optimal value of primal
![Page 38: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/38.jpg)
Dual of the LP RelaxationWainwright et al., 2001
Va Vb Vc
Vd Ve Vf
Vg Vh Vi
min Ty
ya;i [0,1]
∑i ya;i = 1
∑k yab;ik = ya;i
![Page 39: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/39.jpg)
Dual of the LP RelaxationWainwright et al., 2001
Va Vb Vc
Vd Ve Vf
Vg Vh Vi
Va Vb Vc
Vd Ve Vf
Vg Vh Vi
Va Vb Vc
Vd Ve Vf
Vg Vh Vi
1
2
3
4 5 6
1
2
3
4 5 6
ii =
i ≥ 0
![Page 40: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/40.jpg)
Dual of the LP RelaxationWainwright et al., 2001
1
2
3
4 5 6
q*(1)
ii =
q*(2)
q*(3)
q*(4) q*(5) q*(6)
i q*(i)
Dual of LP
Va Vb Vc
Vd Ve Vf
Vg Vh Vi
Va Vb Vc
Vd Ve Vf
Vg Vh Vi
Va Vb Vc
Vd Ve Vf
Vg Vh Vi
i ≥ 0
max
![Page 41: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/41.jpg)
Dual of the LP RelaxationWainwright et al., 2001
1
2
3
4 5 6
q*(1)
ii
q*(2)
q*(3)
q*(4) q*(5) q*(6)
Dual of LP
Va Vb Vc
Vd Ve Vf
Vg Vh Vi
Va Vb Vc
Vd Ve Vf
Vg Vh Vi
Va Vb Vc
Vd Ve Vf
Vg Vh Vi
i ≥ 0
i q*(i)max
![Page 42: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/42.jpg)
Dual of the LP RelaxationWainwright et al., 2001
ii
max i q*(i)
I can easily compute q*(i)
I can easily maintain reparam constraint
So can I easily solve the dual?
![Page 43: Probabilistic Inference Lecture 4 – Part 2](https://reader036.fdocuments.net/reader036/viewer/2022062222/568161b9550346895dd18b12/html5/thumbnails/43.jpg)
Continued in Lecture 5 …