Skip to content

Support task-group-key and task-prefix-key annotations on the scheduler #5742

Open
@gjoseph92

Description

@gjoseph92

Allowing tasks to specify a custom TaskGroup and TaskPrefix key—via annotations—would give us an easy path to work around the fact that Blockwise fusion produces task names that aren't meaningful to users, and can be confusing: dask/dask#8635.

In update_graph:

  1. If a task-group-key annotation is set for a task, support passing it in as the group key instead of calling key_split_group on the task name.
  2. If a task-prefix-key annotation is set for a task, use its value as the prefix key instead of calling key_split on the task name.
  3. (Maybe?) if only task-group-key is given, but not task-prefix-key, calculate the prefix key from task-group-key (this would require a new function like key_split_from_group). Not really necessary, just nice to not have to pass the semi-redundant annotation.

In update_graph, if the TaskState is already in memory, the task-group-key and task-prefix-key annotations can be ignored, whether or not they match the group/prefix already associated with that task.

Once this is implemented, then we can have optimize_blockwise set these annotations accordingly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementImprove existing functionality or make things work bettergood second issueClearly described, educational, but less trivial than "good first issue".

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions