Image Utils Nodes
  • 15 Aug 2024
  • Dark
    Light
  • PDF

Image Utils Nodes

  • Dark
    Light
  • PDF

Article summary

Image Utils Nodes

Crop Annotations

The Crop Out Box Annotations node crops out all box annotations from the image item and creates a new item from each cropped annotation in addition to the original item. The metadata of each new cropped annotation item will have a field linking it to the original item (metadata.system.parentItemId).

The following example demonstrates how to use the Crop Out Box Annotations in your pipeline:

  1. Create a pipeline.
  2. Add a Dataset node and set the trigger to Event of type Created.
  3. Add the following DQL filter in the Dataset node:
    {"dir":"/"}
    
  4. Connect the dataset node to a task node.
  5. Connect the task node to the Crop Out Box Annotations node.
  6. Connect the Crop Out Box Annotations node to a dataset node.

Now, when you add a new item to the first dataset, it will appear in the task. Once the item is given a status Completed in the task, it will flow to the Crop Out Box Annotations node, and a new item will be created for every box annotation. The new items will appear in the original dataset as well as in the dataset that receives the input from the Crop Out Box Annotations node.

Alternatively, you can use the Crop Out Box Annotations as an application from the Dataset Browser.

Simply select or filter the items with box annotations in the Dataset Browser, click the application Crop Box Annotations, and click Execute. An item will be created in your dataset for every box annotation.

Trigger (Optional): An Event/Cron trigger can be set on this node, enabling you to initiate the pipeline run from this specific point.