Comment on page
Distance Transform
The
Distance Transformation
node in AugeLab Studio transforms an input grayscale image into continuous distance values from white to black pixels based on the chosen distance metric.The
Distance Transformation
node applies the distance transform algorithm to an input grayscale image. It calculates the distance of each pixel to the nearest zero (background) pixel and assigns the corresponding distance value to that pixel. This transformation can be useful for applications such as shape analysis, object detection, and segmentation.- Node Title: Distance Transformation
- Node ID: OP_NODE_DIST_TRANS
The
Distance Transformation
node has the following input socket:- Image: The input grayscale image to be transformed. Connect a grayscale image to this socket.
The
Distance Transformation
node has the following output socket:- Image: The transformed image with continuous distance values assigned to each pixel.
The
Distance Transformation
node has a configuration option:- Transformation Type: Select the type of distance transformation to apply. The available options are:
- DIST_L2: Euclidean distance
- DIST_L1: Manhattan distance
- DIST_C: Chebyshev distance
- 1.Drag and drop the
Distance Transformation
node from the node library onto the canvas in AugeLab Studio. - 2.Connect the input grayscale image to the Image input socket of the
Distance Transformation
node. - 3.Select the desired Transformation Type from the available options.
- 4.Run the pipeline.
- 5.The
Distance Transformation
node will apply the distance transformation to the input grayscale image and produce the transformed image at the Image output socket.
- The
Distance Transformation
node uses thecv2.distanceTransform
function to calculate the distance transform of the input image. - The distance transformation assigns continuous distance values to each pixel based on the chosen distance metric.
- The output of the
Distance Transformation
node will have higher intensity values in regions closer to the background and lower intensity values in regions farther away from the background. - Connect the output of the
Distance Transformation
node to other nodes in the pipeline for further processing or analysis.
That concludes the documentation for the
Distance Transformation
node in AugeLab Studio. This node allows you to apply distance transformation to grayscale images, assigning continuous distance values to each pixel based on the chosen distance metric.