Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to "Group" Activities Linked via Scheduling #1073

Open
meganmjones opened this issue Aug 8, 2023 · 7 comments
Open

Ability to "Group" Activities Linked via Scheduling #1073

meganmjones opened this issue Aug 8, 2023 · 7 comments
Assignees
Labels
clipper Requests from the Europa Clipper project feature A new feature or feature request scheduling Anything related to the scheduling domain

Comments

@meganmjones
Copy link

Checked for duplicates

Yes - I've already checked

Alternatives considered

No - I haven't considered

Related problems

This is somewhat related to the issue found with the activityFinder (#1061). If the ability to group scheduled activity instances and space them out from other distinct groupings was available this activityFinder bug would be a more minor problem.

Describe the feature request

When scheduling groupings of activity instances together it would be helpful to have the option to prevent that "group" from overlapping with other "groups" (via group mutexes or a new global scheduling condition). There are many instances where one scheduling goal sets up GNC turns and array articulations surrounding a primary instrument activity instance. When setting these up in a larger plan, in many cases we want these groupings to not overlap with other goal's groupings that involved GNC/array articulations.

Currently, mutexes can be written to prevent overlap of the GNC and array activity types, but it would be beneficial to have the capability to write mutexes preventing overlap of scheduled groupings of activity instances relative to one another. Similarly, being able to set spacing preferences between scheduled groupings would aide significantly in planning (i.e. allow 30 minutes on either end of X grouping from other groupings). This could potentially be handled with a global scheduling condition and would help break up spacing of linked activities in the plan.

A workaround that was put in place to build Clipper's Thread Test 6 plan was to shift the applyWhen window for select anchor activity placements to X hrs after a notable event (in TT6 the >2AU transition) instead of leaving the goal with simply the true constraint (>2AU). This was to space out the scheduled activity groupings to fall in a more logical ordering along with buffer time in between groups.

@meganmjones meganmjones added the feature A new feature or feature request label Aug 8, 2023
@github-project-automation github-project-automation bot moved this to Todo in Aerie Aug 8, 2023
@camargo camargo added the clipper Requests from the Europa Clipper project label Aug 16, 2023
@mattdailis mattdailis added the scheduling Anything related to the scheduling domain label Oct 6, 2023
@jmdelfa
Copy link
Contributor

jmdelfa commented Nov 16, 2023

Slides with design approach for groups Grouping.pptx

Need to discuss:

  • How to store compound activities. Involvement from DB recommended
  • How to enable users to re-use compound activities. Involvement from user interface team recommended

@dandelany
Copy link
Collaborator

@jmdelfa and others met yesterday to discuss the details of this + HTNs, detailed notes in Slack here:

https://jpl.slack.com/archives/CJ07FGRPH/p1701910742191329

@dandelany
Copy link
Collaborator

This is related to #1364 and we'll discuss more next week to scope both of them together.

@dandelany dandelany moved this from Todo to In Progress in Aerie May 9, 2024
@dandelany
Copy link
Collaborator

Also related to older ticket: #870

@jmdelfa
Copy link
Contributor

jmdelfa commented Jun 11, 2024

Updated slides
Groupingv2.pptx

@jmdelfa
Copy link
Contributor

jmdelfa commented Jun 11, 2024

Here is a summary of the current design:

  1. Ordering: Partial order must be supported. Trivial case with full order might be deliver in a first MVP
  2. Planning expressiveness: No pre/post conditions. Notice that partial support to it is being developed via VIOLET
  3. Compound Activity role:
  • Abstract; hence compound activities don’t need to be executed
  • Scheduler can schedule them (via unary goals). A task network is a compound activity, with the difference that a compound activity is not decomposed, and a task network is
    •To be decided: Considering that a task network can be implemented as a compound task: Does the compound task remain on the plan, or is replaced by the task network? My current thinking is that a plan just have the compound task, which may not be decomposed or decomposed, in which case it also has a task network. In this way, all what the decomposer and scheduler see are goals containing activities upon which they have to act (plan or schedule).
  1. Scheduling approach: Early commitment
  2. Cycles: Not allowed. There is a maximum depth and child activities cannot decompose into parent activities. That is, the activity structure is a tree, not a graph
  3. Type of constraints: The task network should allow for Allen temporal constraints. Parameter constraints discarded for first MVP
  4. Goals: Inclusion of unary goal. Compound activities are encapsulated into unary goals.
  5. Task Nets: Align exclusively decompositions. Rest of divergences with task networks out of scope of this issue.
  6. Mission Model: Will be expanded to contain Task Networks (list of activities and constraints) and Methods (link each compound task to task networks that decompose it)

The new Aerie workflow would be:
1.User creates a (partial) plan potentially including compound activities.
2.To generate a valid plan, the user clicks in Plan&Schedule
3.The Decomposer proceeds to decompose compound activities, one at a time. Each subactivity is encapsulated as a unary goal. The resulting partial plan, including goals and constraints is sent to the scheduler
4. The scheduler then schedules all sub-activities (compound or primitive) while satisfying the constraints. There are three outcomes of the scheduling step:
4.1 The scheduler has found a solution and the decomposer decomposed all compound activities: A solution is returned to the user
4.2 The scheduler has found a solution but the decomposer didn’t decompose all activities: Partial plan is sent back to decomposer
4.3 The scheduler couldn’t find a solution: An error is returned to the user

@adrienmaillard
Copy link
Contributor

adrienmaillard commented Jun 13, 2024

Should we keep all design stuff in the discussion instead of this ticket ? I have added impl notes/questions there instead of here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clipper Requests from the Europa Clipper project feature A new feature or feature request scheduling Anything related to the scheduling domain
Projects
Status: In Progress
Development

No branches or pull requests

7 participants