carnegie mellon planning and scheduling stephen f. smith the robotics institute carnegie mellon...
TRANSCRIPT
Carnegie Mellon
Planning and Scheduling
Stephen F. Smith
The Robotics InstituteCarnegie Mellon University
Pittsburgh PA [email protected]
Carnegie Mellon
Outline
• What is Scheduling?
• Current State of the Art: Constraint-Based Scheduling Models
• Is Scheduling a Solved Problem?
Carnegie Mellon
What is Scheduling?
Allocation of resources to activities over time so that input demands are met in a timely and cost-effective manner
Most typically, this involves determining a set of activity start and end times, together with resource assignments, which• satisfy all temporal constraints on activity
execution (following from process considerations)• satisfy resource capacity constraints, and• optimize some set of performance objectives to
the extent possible
Carnegie Mellon
A Basic Scheduling Problem
op11
R2R1
rel1 dd1
rel2 dd2
op12 op1
3
op12 op2
2 i jR
i j st(i) + p(i) < st(j), where p(i)is the processing time of op i
st(i) + p(i) < st(j) st(j) + p(j) < st(i)
rel < st(i), for each op i of job jj
dd > st(i) + p(i), for each op i of job jj
Carnegie Mellon
A More Complex Scheduling Problem
Origin
Air-POE
Sea-POE
Sea-POD
Air-POD
Destination
Carnegie Mellon
Scheduling Research: The Last 10 Years
• Major advances in techniques for solving practical problems• Constraint solving frameworks• Incremental mathematical programming
models • Meta-heuristic search procedures
• Several significant success stories
• Commercial enterprises and tools
Carnegie Mellon
Constraint-Based Scheduling Models
Properties:•Modeling Generality/Expressiveness•Incrementality•Compositional
Active Data Base(Current Schedule)
Constraint Propagation
CommitmentStrategies/Heuristics
ConflictHandling
Components:
Carnegie Mellon
What is a CSP?
Given a triple {V,D,C}, where •V = set of decision variables•D = set of domains for variables in
V•C = set of constraints on the values
of variables in V
Find a consistent assignment of values to all variables in V
Carnegie Mellon
A Basic CSP Procedure
1. [Consistency Enforcement] - Propagate constraints to establish the current set vd of feasible values for each unassigned variable d
2. If vd = Ø for any variable d , backtrack
3. If no unassigned variables or no consistent assignments for all variables, quit; Otherwise
4. [Variable Ordering] - Select an unassigned variable d to assign
5. [Value Ordering] - Select a value from vd to assign to d.
6. Go to step 1
Carnegie Mellon
Formulating Scheduling Problems as CSPs
“Fixed times” model •Find a consistent assignment of start times to activities•Variables are activity start times
Disjunctive graph model• Post sufficient additional precedence constraints between pairs
of activities to eliminate resource contention•Variables are ordering decisions
Carnegie Mellon
A Simple Job Shop Scheduling CSP
Variables: start times (stj,i) - Domain: [0,12]
O1,1Job1:[0,12] [0,12] [0,12]
[0,12] [0,12]
[0,12] [0,12] [0,12]
R1
R2
R3
Job3 :
Job2 :
O1,3O1,2
O2,2O2,1
O3,3O3,2O3,1
Sti,j + Duri,j ≤ Sti,k
Oi,j Oi,kOi,j Ok,lRx
Sti,j + Duri,j ≤ Stk,l V Stk,l + Durk,l ≤ Sti,j
Carnegie Mellon
Constraint Propagation
Deductive process of inferring additional constraints from existing constraints as decisions are made
Two roles:• Early pruning of the search space by
eliminating infeasible assignments• Detection of constraint conflicts
Carnegie Mellon
Some Constraint Propagation Terminology
K-consistency guarantees that any locally consistent instantiation of (K-1) variables is extensible to any K-th variable
Example: 2-consistency (“arc-consistency”)
Complexity: Enforcing K-consistency is (in general) exponential in K•Forward Checking: partial arc-consistency only involving
constraints between an instantiated variable and a non-instantiated one
Carnegie Mellon
Temporal Constraint Propagation through
Precedence ConstraintsAssume dui,j = 3 for all Oi,j
• Before propagation:
• Forward propagation
• Backward propagation
O1,1[0,12] [0,12] [0,12]
O1,3O1,2
O1,1[0,12] [3,12] [6,12]
O1,3O1,2
O1,1[0,6] [0,9] [6,12]
O1,3O1,2
Carnegie Mellon
Capacity Constraint Propagation
Observation: Enforcing consistency with respect to capacity constraints is more difficult due to the disjunctive nature of these constraints
Forward Checking:O1,1
R1
O2,1Before propagation: [6,12]After propagation: [9,12]
Scheduled to start at time 6[6,6]
Carnegie Mellon
Pruning Operation Ordering Alternatives
Example: Erschler’s dominance conditions
Conclusion: Oi cannot precede Oj
In general: For any unordered pair of operations {Oi, Oj}, we have four possible cases:
1. LSTi < EFTj and LSTj ≥ EFTi: Oi is before Oj
2. LSTj < EFTi and LSTi ≥ EFTj : Oj is before Oi
3. LSTi < EFTj and LSTj < EFTi : inconsistency4. LSTi ≥ EFTj and LSTj ≥ EFTi: both options remain open
Carnegie Mellon
Edge Finding
• S - a set of operations competing for resource R• O - an operation not in S also requiring R
10 20 30
OPi
OPj
OPk
EST(O) ≥ EST(S) + Dur(S)((LFT(S) - EST(S) < Dur(O) + Dur(S)) (LFT(S) - EST(O) < Dur(O) + EST(O))
S = {OP ,OP }; O = OP Start Time OP ≥ 25kki j
Carnegie Mellon
More Complex Temporal Constraints
“Simple Temporal Problem” (STP) [Dechter91]• Edge-weighted graph of time points expressing
constraints of the form: atpjtpib• Assuming no disjunction, allows incorporation of
• Temporal relations:•finish-to-start <0, ∞> (precedence)•start-to-finish <t1,t2> (duration)•Start-to-start <0,0> (same-start)•...
• Metric bounds: offsets from time origin• Efficiently solved via all-pairs shortest path
Carnegie Mellon
Constraint-Posting Scheduling Models
•Conduct search in the space of ordering decisions
• variables - Ordering(i,j,R) for operations i and j contending for resource R
• values - i before j, j before i•Constraint posting and propagation
in the underlying temporal constraint network (time points and distances)
Carnegie Mellon
Search Heuristics (Variable and Value
Ordering)• Slack/Temporal Flexibility
• Choose pair of activities with least sequencing flexibility
• Post sequencing constraint that leaves the most slack
• Resource Demand/Contention• Identify bottleneck resource• Schedule (or sequence) those activities contributing
most to demand
• Minimal critical sets• Generalization to multi-capacity resources
Carnegie Mellon
Search Control
• Backtracking-based search
• Least-Discrepancy Search
• Iterative Re-starting with randomized heuristics
• Local search - Tabu, GAs, etc.
Carnegie Mellon
The Broader Picture
Constraint posting provides a framework for integrating planning and scheduling • contemporary temporal planners operate with analogous
representational assumptions• E.g., IXTET, HSTS/RAX, COMIREM, …• “Constraint-Based Interval Planning” [D. Smith 00]
Constraint posting is a relatively unexplored approach to scheduling with several advantages• more flexible solutions • simple heuristics can yield high performance solution
techniques under a wide variety of problem constraints
Carnegie Mellon
Technological Strengths
• Scalability
• Modeling flexibility
• Optimization
• Configurable
So, Is scheduling a solved problem?
Carnegie Mellon
What is Scheduling (Again)?
Classic view:• Scheduling is a puzzle solving activity-
• Given problem constraints and objective criterion, figure out how to best tile the capacity over time surface with operations
• Research agenda - specify new puzzles and/or provide new best solutions
OP1,1 OP1,2 OP1,3
OP2,1 OP2,2
R1 R2rd1 dd1
dd2rd2
i j
st(i) + p(i) ≤ st(j), where p(i)is the processing time of op i
i jR
st(i) + p(i) ≤ st(j) V st(j) + p(j) ≤ st(i)
rd(j) ≤ st(i) for each op i of job j
Minimize ∑ |c(j) - dd(j)|
OP1,1 OP2,2 OP1,3
OP1,2OP2,1
R2
R1
Carnegie Mellon
What’s Missing from the Classical View of
SchedulingPractical problems can rarely be
formulated as static optimization tasks• Ongoing iterative process • Situated in a larger problem-solving
context• Dynamic, unpredictable environment
Carnegie Mellon
Managing Change
“Scheduling” is really an ongoing process of responding to change
• Predictable, Stable Environment• Optimized plans
• Unpredictable, Dynamic Environment• Robust response
Manufacturing
Crisis ActionPlanning
ProjectManagement
Carnegie Mellon
Approaches to Managing Change
• Build schedules that retain flexibility• Produce schedules that promote
localized recovery• Incremental re-scheduling techniques
(e.g., that consider “continuity” as an objective criteria)
• Self-scheduling control systems
Carnegie Mellon
Incremental Schedule Repair
Several competing approaches to maintaining solution stability• Minimally disruptive schedule revision (temporal
delay, resource area, etc.)• Priority-based change• Regeneration with preference for same decisions
Little understanding of how these techniques stack up against each other
Even less understanding of how to trade stability concerns off against (re)optimization needs
Carnegie Mellon
Delayed-Commitment Scheduling Procedures
Identify a contention peak and post a leveling constraint
Carnegie Mellon
Activity 2
R1Activity 1
Activity 2
R1Activity 1
Advantages•Retain flexibility implied by problem
constraints (time and capacity)•Can establish conditions for guaranteed
executability
Carnegie Mellon
Building Robust Schedules
Some open questions:• Extended conditions for
“Dispatchability”• Robustness versus optimization• Use of knowledge about domain
uncertainties• Local search with robust
representations
Carnegie Mellon
Self-Scheduling Systems
•Distribute decision-making among individual entities (machines, tools, parts, operators; manufacturers, suppliers)
•Specify local behaviors and protocols for interaction
•Robust, emergent global behavior
Carnegie Mellon
Morley’s GM Paint Shop System
Dispatcher
PaintBooth
1
PaintBooth
2
Bid
Bid
Announcement(new truck)
Bid parameters:
- same color as last truck
- space in queue
- empty queue
“If bid for same color then award else if empty booth then award else if queue space then award”
Carnegie Mellon
Tradeoffs
Advantages:• Complexity reduction• Simple, configurable software systems• Robust to component failures• More stable computational load
Problems:• No understanding of global optima (or how to achieve
global behavior that attends to specific performance goals)
• Prediction only at aggregate level (can become unstable)
Carnegie Mellon
Adaptive Systems:“Routing Wasps” in the
Factory
Machine1
Machine2
MachineN
...
ST2
P(route|ST,ØT) = _________ ST
2 + ØT2
Response Thresholds:ØA, ØB, ØC, ...
AA
B
B
B
C
C
Stimulus:SB
R-WaspAgentN
R-WaspAgent2
R-WaspAgent1
Jobs
Carnegie Mellon
Updating Response Thresholds
ØT = ØT – ∆1 if next job is same type as current job
ØT = ØT + ∆2 if next job is a different type
ØT = ØT – ∆3 if the machine is currently idle
• Routing framework can be seen as an adaptive variant of Morley’s bidding rule
• Experimental results showing significant performance improvement
Carnegie Mellon
Some Open Issues in Multi-Agent Scheduling
• Self-scheduling approaches do not preclude the use of advance schedules• How to incorporate?
• Opportunistic optimization
• Cooperative, distributed scheduling is a fact of life in many domains (geographic constraints, autonomous business entities, etc.)• How to negotiate and compromise? • Can self-interest be compatible with global
performance objectives?
Carnegie Mellon
Integrating Planning &
Scheduling
Mixed-Initiative Model
Waterfall Model
Plan Schedule
Planner
Scheduler
Planner
SchedulerSchedule
Plan
“Planning & scheduling are rarely separable”
Carnegie Mellon
Design Issues
• Integrated search space versus separable sub-spaces
• Single solver versus interacting solvers
• Resource-driven versus strategy-driven
• Loose coupling versus tight coupling
Carnegie Mellon
JFACC Planner/Scheduler
Plan Server
ConstraintBased
Scheduler(CMU)
HTNPlanner
(SRI)
PLANSSCHEDULES
ANNOTATIONS
TRIGGERS
Experimental• Simple, low-cost info. exchanges
yield• Marked reduction in comp.
time• Comparable plan/schedule
quality• More complex models can improve
performance further
Technological• Interleaved generation &
repair of plans/schedules• Distributed architecture
to support remote collaboration
SRI International
Carnegie Mellon
Some Challenges that Remain
• Scheduling models that incorporate richer models of state
• Can integrated P & S problems really be solved as one big optimization task?• The limitations of SAT-style approaches
• How to achieve tighter interleaving of action selection and resource allocation processes
• Managing change in this larger arena
Carnegie Mellon
Requirements Analysis
“Scheduling is really a process of getting the constraints right”
Current tools designed around a “Specify and Solve” model of user/system interaction• Inefficient problem solving cycle
Mixed-Initiative solution models• Incremental solution of relaxed problems• Iterative adjustment of problem constraints,
preferences, priorities
Carnegie Mellon
Use of Relaxed Models to Identify Resource Capacity
Shortfalls
Carnegie Mellon
The AMC Barrel Allocator
Domain: Day-to-Day Management of Airlift & Tanker Assets at the USAF Air Mobility Command (AMC)
Technical Capabilities:• Efficient generation of airlift and tanker schedules • Incremental solution change to accommodate new
missions and changes in resource availability over time• Flexible control over degree of automation • Selective, user-controlled constraint relaxation and
option generation when constraints cannot be satisfied
Carnegie Mellon
Parameterizable Search Procedures
I1,305 I2,305 I1,437...
305thAMW
AssignMission:C141, [t1,t2]
Configuration
60thAW
62ndAW
437thAMW
...I2,437 I1,60 ... I1,62 ...I1,60
GenResources
GenIntervals
EvalCriteria
...
Feasible - <GenResources, GenIntervals, EvalMinCompletion>
Search ConfigurationsFeasible - <GenRequestedRes,GenIntervals,EvalMinCompletion >
Delay - <GenRequestedRes, GenDelayInts, EvalMinTardiness>
Over-Allocate - <GenRequestedRes, GenOverInts,
EvalMinOverUsage>
Bump – <GenRequestedRes, GenBumpInts, EvalMinDisruption>
Alternative-MDS - < GenAlternRes, GenIntervals,
EvalMinCompletion>
Composite Relaxations - …
Carnegie Mellon
Generate Relaxation
Options
Carnegie Mellon
Mixed-Initiative Scheduling Challenges
• Management of user context across decision cycles
• Explanation of scheduling decisions• Why did you do this? • Why didn’t you do that?
• Adjustable autonomy
Carnegie Mellon
Research Directions for the Next 10 Years
• Deeper integration of AI and OR techniques
• Robust schedules and scheduling
• Global coherence through local interaction
• Extension to larger-scoped problem-solving processes
• Rapid construction of high performance scheduling services