fast::VertexTensorToSegmentation class

Convert a tensor of vertex positions (graph) to a segmentation.

A vertex tensor is assumed to have the shape (2, N) consisting of N points with x, y positions. If multiple objects are present, they are drawn in the order specified.

Inputs:

Outputs:

  • 0: Segmentation Image
  • 1: Mesh with vertices and lines

Base classes

class ProcessObject
Abstract base class for all process objects.

Constructors, destructors, conversion operators

VertexTensorToSegmentation() protected

Public functions

auto create(std::vector<std::vector<fast::MeshLine>> connections, int width, int height) -> std::shared_ptr<VertexTensorToSegmentation>
Create instance.

Protected functions

void execute() override

Protected variables

Connections m_connections
int m_width
int m_height

Function documentation

std::shared_ptr<VertexTensorToSegmentation> fast::VertexTensorToSegmentation::create(std::vector<std::vector<fast::MeshLine>> connections, int width, int height)

Create instance.

Parameters
connections List of connections for each object
width specify width of output segmentation. If not specified width of network input that created the tensor is used instead.
height specify height of output segmentation. If not specified, height of network input that created the tensor is used instead.
Returns instance

If multiple objects are provided to the connections param, they are drawn in the order the they are specified.