NVIDIA Holoscan SDK v2.3.0
v2.3.0

Class GenerateBoxes

Base Type

class GenerateBoxes : public holoscan::inference::TransformBase

Generate boxes Transform Class.

Public Functions

inline GenerateBoxes()

Default Constructor.

inline explicit GenerateBoxes(const std::string &config_path)

Explicit Constructor.

~GenerateBoxes() override = default

Default Destructor.

virtual InferStatus initialize(const std::vector<std::string> &input_tensors)

Initializer. Parses the config file and populates all required variables to be used in the execution process.

Parameters

input_tensors – Input tensors from inference operator

Returns

InferStatus

InferStatus create_tensor_map(const std::vector<std::string> &input_tensors)

Create a tensor mapping of pre-defined tensors of the class to incoming tensors from inference operator.

Parameters

input_tensors – Input tensors from inference operator

Returns

InferStatus

virtual InferStatus execute(const std::map<std::string, void*> &indata, const std::map<std::string, std::vector<int>> &indim, DataMap &processed_data, DimType &processed_dims)

Core execution. Ingests input data with tensor names as “scores”, “labels” and “boxes”. Finds the valid boxes and text and populates the tensors and coordinates to be used in holoviz.

Parameters
  • indataMap with key as tensor name as value as raw data buffer

  • indimMap with key as tensor name as value as dimension of the input tensor

  • processed_data – Output data map, that will be populated

  • processed_dims – Dimension of the output tensor, is populated during the processing

Returns

InferStatus

InferStatus execute_mask(const std::map<std::string, void*> &indata, const std::map<std::string, std::vector<int>> &indim, DataMap &processed_data, DimType &processed_dims)

Ingests input data with tensor names as “scores”, “labels” and “masks”. Finds the object masks and prepares it for rendering in holoviz.

Parameters
  • indataMap with key as tensor name and value as raw data buffer

  • indimMap with key as tensor name and value as dimension of the input tensor

  • processed_data – Output data map, that will be populated

  • processed_dims – Dimension of the output tensor, is populated during the processing

Returns

InferStatus

Previous Class DeviceFree
Next Class HostBuffer
© Copyright 2022-2024, NVIDIA. Last updated on Sep 6, 2024.