This module facilitates the conversion of Infer metadata into a format compatible with the overlay module. Metaconvert also accepts configuration parameters as JSON string, which provide further flexibility on configuring overlay information such as line thickness, font size, font type ., etc. Please check API documentation for more information. Additionally, if users have a custom meta data then they can integrate customized functions to convert them into a format suitable for processing by the overlay module by overriding base class.
More...
#include <vart_metaconvert.hpp>
This module facilitates the conversion of Infer metadata into a format compatible with the overlay module. Metaconvert also accepts configuration parameters as JSON string, which provide further flexibility on configuring overlay information such as line thickness, font size, font type ., etc. Please check API documentation for more information. Additionally, if users have a custom meta data then they can integrate customized functions to convert them into a format suitable for processing by the overlay module by overriding base class.
- See also
- MetaConvertImplBase
◆ MetaConvert() [1/3]
| vart::MetaConvert::MetaConvert |
( |
| ) |
|
|
delete |
◆ MetaConvert() [2/3]
| vart::MetaConvert::MetaConvert |
( |
InferResultType |
infer_res_type, |
|
|
std::string & |
json_data, |
|
|
std::shared_ptr< Device > |
device |
|
) |
| |
MetaConvert() - Constructor for using existing metaconvert implementations.
- Parameters
-
| [in] | infer_res_type | Enum class to specify which implementation to instantiate. The dispatcher currently accepts CLASSIFICATION, DETECTION and SEGMENTATION. Any other value throws std::invalid_argument. |
| [in] | json_data | JSON config string based on the implementation class |
| [in] | device | Device handle. Must be non-null. See vart::Device for more details. |
◆ MetaConvert() [3/3]
MetaConvert() - Constructor for using user defined implementation.
- Parameters
-
| [in] | ptr | Pointer to user's implementation instance. Must be non-null; the constructor stores it as the pimpl and subsequent method calls dereference it without an additional null check. |
◆ get_pimpl_handle()
get_pimpl_handle() - Gives pointer to implementation class.
- Returns
- Returns a constant reference of pointer to implementation class.
◆ prepare_overlay_meta()
prepare_overlay_meta() - Converts inference results to data structures needed for overlay Overlay
- Parameters
-
| [in] | root_infer_res | Root node of the inference-result tree to be interpreted and converted. Must be non-null; the implementation does not null-check the shared pointer before traversing its children, so a null or empty handle is undefined behavior. |
- Returns
- Shared pointer to an
OverlayShapeInfo describing the conversion result. The returned object carries a custom deleter that free()s each text param's disp_text before releasing the heap-allocated struct; lifetime is tied to the shared ownership.
The documentation for this class was generated from the following file: