View
222
Download
0
Category
Preview:
Citation preview
2
Restarts
SAT solvers use a "restart" policy• Following various criteria, the solver is forced to
backtrack to level 0.
Restarts have crucial impact on performance.
Motivation: avoid spending too much time in ‘bad’ branches:• no easy-to-find satisfying assignment • no opportunity for fast learning of strong clauses.
3
Restarts Motivation Best time to restart:
• When algorithm spends too much time under a “wrong” branch
No solution
Perform restart
solution
decision level kdecision level k
decision level 1decision level 1
decision level 0decision level 0
4
The basic measure for restarts
All existing techniques use the number of conflicts learned as of the previous restart.
The difference is only in the method of calculating the threshold.
5
Restarts strategies
1. Arithmetic (or fixed) series. • Parameters: x, y. • Init(t) = x• Next(t)=t+y
Used in: • Berkmin (550, 0)• Eureka (2000, 0)• Zchaff 2004 (700, 0)• Siege (16000, 0)
Arithm(2000, 0) , Arithm(1000, 10)
0
500
1000
1500
2000
2500
3000
3500
1 21 41 61 81 101 121 141 161 181 201
Restart NumberT
hre
sh
old
6
Restarts Strategies (cont.)
2. Geometric series.• Parameters: x, y. • Init(t) = x• Next(t)=t*y
Used in• Minisat 2007 (100, 1.5)
Geo(100, 1.5)
0
200000
400000
600000
800000
1000000
1200000
1 3 5 7 9 11 13 15 17 19 21 23
Restart NumberTh
resh
old
7
Restarts Strategies (cont.)
3. Inner-Outer Geometric series. • Parameters: x, y, z. • Init(t) = x• if (t*y < z)
- Next(t) = t*y• else
- Next(t) = x- Next(z) = z*y
Used in:• Picosat (100, 1.1, 1000)
Inner-Outer (100, 1.1, 100)
0
500
1000
1500
2000
1 17 33 49 65 81 97 113 129 145 161 177 193
Restart NumberTh
resh
old
8
Restarts Strategies (cont.)
4. Luby et al. series. • Parameter: x.• Init(t) = x
• Next(t) = ti*x
Used in:• RSat (512)• Tinisat (512)
Luby(512)
0
5000
10000
15000
20000
1 7 13 19 25 31 37 43 49 55 61 67 73 79 85 91 97
Restart NumberTh
resh
old
ti =1 1 2 1 1 2 4 1 1 2 1 1 2 4 8 1 1 2 1 1 2 4 1 1 2 1 1 2 4 8 16 1 1 2 1 1 2 4 1 1 2 1 1 2 4 8 …
9
Global vs. Local
Recall: all techniques measure the number of conflicts as of the previous restart.
This is a global criterion.
Somewhat disregards the original motivation of focusing on ‘bad’ branches.
Local criteria: measure difficulty of branches.
10
Global Restarts
Perform restart
Explored sub tree
No solution solutionNo solution solution
decision level kdecision level k
decision level 1decision level 1
decision level 0decision level 0
11
Local Restarts
Perform restart
Explored sub tree
No solution solution
decision level k
decision level 1
decision level 0
12
Calculating the number of conflicts under a branch
We worked with the following local measure:• Number of conflicts above each level.
For each decision level d maintain a counter c(d): • When making a decision at level d,
- c(d) = #global conflicts.• When backtracking to level d:
- res = #global conflicts - c(d).• If res > threshold, restart.
All the presented strategies can be local.
13
Dynamic Criteria
A new dimension for the restart strategy: the decision level d. • The restart threshold is a function of d.
Higher decision level smaller threshold.
Each of the local strategies can be made dynamic.
14
Dynamic(1000, 10, 2, 50) - Current x =1000
0
200
400
600
800
1000
1200
1 79 157 235 313 391 469 547 625 703 781 859 937
Decision Level
Th
resh
old
Dynamic Criteria
Dynamic-fix. • d – decision level, • i – iteration • Parameters:
x, y, c.
• Init(t) = x• Next(t) = x + y * i – (c * d)
min
Constant
Need a minimum !
15
Dynamic(1000, 10, 2, 50) - Current x =1000
0
200
400
600
800
1000
1200
1 79 157 235 313 391 469 547 625 703 781 859 937
Decision Level
Th
resh
old
Dynamic Criteria
Dynamic-fix. • d – decision level, • i – iteration • Parameters:
x, y, c, min > 0.
• Init(t) = x• Next(t) = max(x + y * i – (c * d), min)
min
Constant
Not a restart number
16
Experimental Results
Solvers: Minisat 2007 and Eureka Benchmarks: 100 instances from SAT-race 2006
(the TS1,TS2 test sets). Timeout: 30 minutes.
• Instances that timed-out are included and contribute 30 minutes
Restart configurations: 40• Chosen dynamically following ‘hill climbing’• Looked also for best parameters for global restarts
Experimental Results - Minisat
Restart Strategy
Local Global Speedup
Arithmetic 7.93 9.52 x1.16
Geometric 9.55 10.64 x1.11
Inner-Outer 7.37 8.86 x1.2
Luby 7.89 8.98 x1.13
Original vs. Best Local
7.37 10.64 x1.44
Experimental Results (fails) – Minisat
Restart Strategy
Local Global improvement
Arithmetic 10 10 1
Geometric 11 14 x1.27
Inner-Outer 8 10 x1.25
Luby 9 11 x1.22
Original vs. Best Local
8 14 x1.75
19
Dynamic Restart Unsat improvement:
• x1.19 speedup (4.09h vs. 4.90h)• x1.75 in unsolved instances (4 vs. 7).
0
300
600
900
1200
1500
1800
0 300 600 900 1200 1500 1800
Arithm. 1000 0.1
Dyn
amic
Ari
thm
. 10
00 0
.1 2
0 10
Zoom in
0
100
200
300
0 100 200 300
Arithm. 1000 0.1
Dyn
amic
Ari
thm
. 10
00 0
.1 2
0 10
20
Dynamic Restart Unsat improvement:
• x1.19 speedup (4.09h vs. 4.90h)• x1.75 in unsolved instances (4 vs. 7).
Recommended