Gains of efficiency through coordination in Distributed search - PowerPoint PPT Presentation

1 / 59
About This Presentation
Title:

Gains of efficiency through coordination in Distributed search

Description:

Unary: Aviva can't work between 8:00 9:00. Bila Can't work ... Aviva, Bila, Dina are Head' nurses. In every shift there should be at least one head nurse. ... – PowerPoint PPT presentation

Number of Views:20
Avg rating:3.0/5.0
Slides: 60
Provided by: am052
Category:

less

Transcript and Presenter's Notes

Title: Gains of efficiency through coordination in Distributed search


1
Gains of efficiency through coordination in
Distributed search
  • Roie Zivan and Amnon Meisels
  • Dept. of Computer Science
  • Ben-Gurion University

2
Constrained Satisfaction Problems (CSP)
  • NP-complete problem, relevant for real-world
    problems such as timetabling.
  • Structure V,D,R (Variables , Domains of
    Values, Constraints).

V1, V2, Vn
val1,val2,val3
val1,val2
val1,val2,val3
3
Constraints
  • Define under what circumstances a value cannot be
    assigned.
  • Unary constraints can be filtered in
    preprocessing.
  • Binary constraints are a subset of the Cartesian
    product of the domains of every two variables.

V1 2
V3 4
4
The Nurses example
Variables Shifts S1 800 1600, S2 1600
2400, S3 2400 800 Values Nurses
Aviva, Bila, Carmela Constraints Unary
Aviva cant work between 800 900
Bila Cant work between 1700 2000
Binary One nurse for every shift
(between each two variables there is a not equql
constraint)
5
Solving the CSP
  • Unary constraints can be filtered in
    preprocessing (Aviva is extracted from S1s
    domain and Bila from S2s).
  • Binary constraints are solved using some
    centralized backtrack algorithm.
  • The solution
  • S1,Bila,S2,Aviva,S3,Carmela

6
A Distributed Constraint Network
7
Distributed Constraints the Model
  • Every Agent runs the same algorithm.
  • Agents have no direct access to variables of
    other Agents.
  • Agents can solve there local network.
  • Agents send receive messages to check inter
    constraints.
  • Messages eventually arrive at their destination.
  • A FIFO order on messages in the same direction
    between two agents.

8
In our example
  • Another department.
  • Nurses Dina, Ela, Flora
  • Aviva, Bila, Dina are Head nurses.
  • In every shift there should be at least one head
    nurse.

Local Constraint
Inter Constraint
S1
S1
S2
S2
S3
S3
First Department
Second Department
9
Solving DisCSPs
A2
A1
V1 2
V2 ?
10
First Approach Synchronous
  • Inherited from centralized search.
  • A total order is defined among agents
  • Only one agent active at a time (other are idle).
  • An agent receives the assignments of all the
    agents with higher priority before it performers
    its own assignment.
  • An agent that cannot find a consistent
    assignment, backtracks.

11
Synchronous search
A1
A2
A3
An-1
An
V12,V21,V3?
Current Partial Assignment (CPA)
12
Second Approach Asynchronous
  • Motivation
  • Independency of agents.
  • Concurrent effort.
  • Principles
  • Agents always hold an assignment which is
    consistent with there view of the system.
  • On backtrack operations agents change there views
    by eliminating inconsistent values.

13
Asynchronous Backtrack (ABT)
A3
A2
A1
A4
A11
14
Backtrack in Asynchronous search
Agent view of Agent A4 A12, A31
Nogood
A3
A12, A31
15
ABT on Backtrack
A3
A2
A1
A4
A12, A31
16
Yokoos comparison ABT vs SBT
17
Advantages and drawbacks in AS
  • Advantages
  • Concurrent Computation.
  • Backjumping.
  • Forward-checking
  • Drawbacks
  • Computation is done against inconsistent partial
    assignments.
  • Dependency on quality of communication

18
Inconsistent computation in ABT
A3
A2
A1
A3,4
A4
A1,1,A3,1
A1,2
19
Yokoos comparison ABT vs SBT
20
Drawbacks in Yokoos experiment
  • n-Queens is a solvable easy problem.
  • Synchronous simulator (instantaneous messages)
    for an asynchronous algorithm.
  • Most trivial synchronous algorithm.
  • Synchronous backtrack can perform backjumping.
  • Only one measurement

21
Our experiments construction
  • Asynchronous simulator. Agents implemented as
    Java Threads
  • Measurement including
  • Time steps
  • Network load messages-sent
  • Range of difficulties (including phase transition
    problems)
  • The best algorithms among both families
  • Different forms of communication.
  • Instantaneous messages
  • Fix message delay
  • Random message delay

22
Comparing concurrent steps
23
Comparing message load
24
Conclusion
  • The basic assumption
  • Asynchronous Search pays in network load
    but increases efficiency
  • Back to the synchronous algorithms
  • One active agent at a time
  • One message at a time (low message load)

25
Increasing Efficiency
  • Two Ideas
  • Asynchronous Forward-Checking
  • Concurrent Backtrack Search

26
Asynchronous Forward-Checking
A2
A1
A3
An-1
An
CPA
FC_CPAs (copies of the original CPA)
V12,V21,V3?
27
A2
A1
A3
An-1
An
Not-OK Messages
V12,V22
Inconsistent partial assignment
28
The proposed algorithm
  • Keeps one Current Partial Assignment CPA
  • The CPA is always consistent
  • In every step, one agent holds the CPA and
    attempts to (consistently) extend the partial
    assignment on it
  • After adding their assignment to the CPA, agents
    send copies of the CPA, to all unassigned agents
  • All unassigned agents receive the FC_CPA and
    perform forward-checking asynchronously
  • When an empty domain occurs, a Not_OK message is
    sent to all unassigned agents
  • A CPA received after a Not_OK, generates a
    backtrack

29
Recovery from collisions
A2
A1
A3
An-1
An
V12,V22 5
V12,V22 3
30
Agent Dilemas
Mail Box
Current Message
A1,1,A2,2,A3,3 7
AgentView
A1,2,A2,1,A3,3 5
31
Agent Dilemas
Mail Box
Current Message
A1,1,A2,1 3
AgentView
A1,1,A2,2,A3,3 7
32
Agent Dilemas
Mail Box
Current Message
A1,1,A2,2 4
AgentView
A1,1,A2,2,A3,3 7
33
Experimental analysis (outline)
  • AFC is compared with the Asynchronous Backtrack
    algorithm (Yokoo2000).
  • Randomly generated problems, n10 k10 a range
    of tightness values
  • Algorithm performance is measured by the number
    of steps and the number of messages.
  • Both algorithms are implemented within a
    concurrent simulator with different forms of
    communication.

34
Number of Steps
35
Number of total MSGs sent
36
Concurrent Synchronous Backtrack
Local data structures
CPAs
37
Initial split of the search space
1,2,3,4
4
1
3
2
38
1
2
3
4
1
2
3
4
39
The ConcBT algorithm
  • The search space is initially split to a number
    of sub-search-spaces no larger than the first
    agent domain
  • One Current Partial Assignment CPA is kept for
    each sub-search-space
  • Each CPA represents a synchronic search process.
  • The assignments on the CPAs are always
    consistent.
  • Each CPA carries a unique ID. An agent holding it
    uses only the corresponding current-domain to
    assign it.
  • Dynamic re-split is used in order to increase the
    search on harder sub-search-spaces.
  • A simple heuristic is used to determine when
    dynamic split is necessary.

40
Agent actions
2,4
1,2,3,4
1,3
3,4
2,2
2,3,4
SP
A1,1,A2,2,A3,3 2,2
4,0
4
41
Agent actions
2,4
1,2,3,4
1,3
3,4
2,2
2,3,4
SP
A1,3,A2,1,A3,3 4,0
4,0
4
42
Dynamic split of the search space
1,2,3,4
_,_,_,_ 0
1
1,2,3,4
2
1,2,3,4
3
1,2,3,4
4
43
Dynamic split of the search space
2,3,4
1
1,2,3,4
1,_,_,_ 1
2
1,2,3,4
3
1,2,3,4
4
44
Dynamic split of the search space
2,3,4
1,_,_,_ 0
1
1,2,3,4
2
1,2,3,4
3
1,2,3,4
4
45
Dynamic split of the search space
3,4
1
1,2,3,4
2,_,_,_ 1
2
1,2,3,4
3
1,2,3,4
4
46
Dynamic split of the search space
3,4
1
2,3,4
2
1,2,3,4
2,1,_,_ 2
3
1,2,3,4
4
47
Dynamic split of the search space
3,4
1
2,3,4
2
2,3,4
3
1,2,3,4
2,1,1,_ 3
4
48
Dynamic split of the search space
3,4
1
2,3,4
2
2,3,4
2,1,1,_ 4
3
1,2,3,4
4
49
Dynamic split of the search space
3,4
1
2,3,4
2
3,4
3
1,2,3,4
2,1,2,_ 5
4
50
Dynamic split of the search space
3
4
0
1
2,3,4
1,2,3,4
2
3,4
2,1,2,_ 1
1,2,3,4
3
1,2,3,4
1,2,3,4
4
51
Why not do the same in asynchronous search?
  • IDIBT Interleaved Distributed Backtrack. Hammadi
    (2001,2002)
  • Asynchronous search is performed in parallel on
    split sub-search-spaces.
  • Drawbacks
  • No possibility for dynamic splitting.
  • The performance deteriorates for multiple
    splitting.

52
Hammadis results
53
The splitting effect
54
and in messages
55
Comparison to asynchronous search
56
Comparison to asynchronous search
57
Conclusion
  • The asynchronous approach for solving DisCSPs
    does not achieve its goals.
  • AFC, and ConcBT are two ideas representing a new
    approach some coordination in the concurrent
    effort can increase efficiency.
  • The improvements are in both measurements time
    and network-load.

58
Future work
  • Complete the picture ConcCBJ, AFC with DAC,
    Ordering and privacy issues.
  • Formal evaluating model. The cycle model is not
    compatible to an asynchronous system.
  • Generic representation for such algorithms (given
    a centralized algorithm, generating a distributed
    algorithm).

59
CBJ vs ConcCBJ (no re splits yet)
Write a Comment
User Comments (0)
About PowerShow.com