Dependent Tasks

Some tasks cannot be created until a root task they depend on has been completed (see 2D/3D Lidar Linking). Rather than waiting for the root task to complete before manually creating the dependent tasks, we can declare dependent tasks when creating the root task itself. In particular, this is currently supported for creating lidarlinking or lidarsegmentation tasks based off a Lidar Annotation task.

Currently, this relationship is defined either via the dependents field when creating a lidarannotation task or by specifying a lidar_task when creating a lidarlinking or lidarsegmentation task (see Start From Completed LIDAR Task.

To enable dependent tasks, you must include a dependents object when creating your lidarannotation task.

Definition: Dependents

{
  "annotation_attributes": {
    ...
  },
  "dependents": {
    "defs": [
      {
        "type": "lidarlinking",
        "annotation_type": "imageannotation",
        "instruction": "Adjust the annotations around the cars.",
        "callback_url": "https://www.example.com/callback",
      },
    ],
    "require_audit": true
  },
}

The dependents object describes what dependent tasks to create upon completion of this task.

ParameterOptional?TypeDescription
defsnoArray<DependentDef>Definitions of the tasks that will be created once this task is complete.
require_audityesbooleanWhether or not to wait for a customer audit to fix/approve a task before creating the dependent tasks.

Definition: DependentDef

"defs": [
    {
      "type": "lidarlinking",
      "annotation_type": "imageannotation",
      "instruction": "Adjust the annotations around the cars.",
      "callback_url": "http://www.example.com/callback2"
    }
  ]

DependentDef objects are used to describe the dependent task to be created, the properties of which are the same as the properties of a regular request to the corresponding endpoint, without the params that refer to the base task (e.g. lidar_task for lidarlinking tasks). These params will be added to the dependent task when it is created. In addition, a type parameter must be specified to identify the type of task to create. For example, if we were to create a dependent Lidar linking task based off a Lidar task, a sample DependentDef is shown above.

To learn more about lidarlinking params and tasks, see 2D/3D Linking.
To learn more about lidarsegmentation params and tasks, see Lidar Segmentation.

ParameterOptional?TypeDescription
typenostringType of task that will be created as a dependent task (lidarlinking or lidarsegmentation).
instructionnostringA markdown-enabled string explaining how to draw the annotations. You can use markdown to show example images, give structure to your instructions, and more.
callback_urlnostringThe full url (including the scheme http:// or https://) of the callback when the task is completed. See the Callbacks section for more details about callbacks.
annotation_typelidarlinking onlystringThe 2D annotation type to return, either imageannotation, annotation, cuboidannotation, or polygonannotation.
labelslidarsegmentation onlyarrayAn array of strings describing the different types of objects you’d like to be used to segment the image. You may include at most 50 objects.