cooperative pathfinding david silver. overview the problem solution methods local repair a*...
TRANSCRIPT
Cooperative Pathfinding
David Silver
Overview The problem Solution methods
Local repair A* Cooperative A* Hierarchical, Cooperative A* Windowed, Hierarchical, Cooperative A*
Live demo (!?) Results
The Problem N agents N goals Find N paths Such that no two
paths overlap
The Problem with the Problem Search space is enormous
e.g. 100x100 gridworld ~(10,000)N states Branching factor of 5N
{N, E, S, W, wait} for each agent
Need to solve in real-time e.g. complete search within 1ms
Reformulating the Problem Err… isn’t this course called Single
Agent Search? So simplify the problem to a series
of single agent searches. Two approaches considered:
A* with local repair Cooperative A*
1. A* with Local Repair Search for route to goal Ignore other agents If collision is imminent, route again Increase agitation level with each
reroute Cross fingers and hope for the best
Problems with Local Repair Failure to reach goal Long solution lengths Frequent recalculation Appearance of ‘stupidity’
2. Cooperative A* Consider each agent in turn,
greedily Search for a route to goal, avoiding
reserved states Mark the agent’s route in a
reservation table Basic heuristic uses Manhattan
distance
Search Space The new search space has 3
dimensions 2 dimensional grid Time dimension
Reservation table marks illegal states Mark each state on any agent’s path Sparse data structure Implemented using hash table
Problems with Cooperative A* Poor heuristic, many nodes expanded
Need to improve heuristic Problems with agents at destination
Need to continue searching Sensitive to agent order
Dynamically rotate through agent orders
How to improve the heuristic? Pattern databases no good
Search space too large Goal may be different each time Map may change dynamically
So use hierarchical A* (Holte) Search for goal at abstract level Use abstract distance as heuristic 3 ideas for reusing abstract search
3. Hierarchical, Cooperative A* Domain abstraction
Ignore time dimension Ignore reservation table Basic gridworld search
Cooperative A* as before But using abstract distance as heuristic Abstract distance computed on
demand
Reverse, Resumable A* Search backwards from Goal Search towards Start But only terminate when requested
node is reached Keep Open, Closed lists Resume search whenever a new
node is requested Consistent heuristic required
4. Windowed, Hierarchical, Cooperative A* Break up search into manageable
pieces Like an intermediate abstraction layer
Full search up to N steps Ignore time/reservations after N steps
After N steps this is the same as abstract layer
So use abstract distance to complete search
Windowing
S
G
N
window
abstract edged(N,G) = h(N,G)
Continuing the search Continue search after reaching
destination May need to get out of the way Use edge costs:
0 if sitting on destination 1 for other edges Abstract distance to goal for final
edge
Using Windows Compute window for all agents
initially Then recompute each agent when
half way through window Stagger computation to spread out
processing time Can keep abstract distances until
destination changes
Demo I hope this works!
Results: nodes expanded
0200400600800
100012001400160018002000
A* LRA* CA* HCA* W-32 W-16 W-8
BaseAbstract
Results: path length
0102030405060708090
100
A* LRA* CA* CHA* W-32 W-16 W-8
Length
Further ideas Additional layers in the hierarchy
e.g. ignore half the reservations Prioritising agents
Overriding low priority agents Abstracting in space as well as
time e.g. Using N-cliques