What can I help you with?
NVIDIA Holoscan SDK v3.4.0

Class SimpleTextSerializer

Base Type

class SimpleTextSerializer : public holoscan::Resource

Public Functions

HOLOSCAN_RESOURCE_FORWARD_ARGS_SUPER (SimpleTextSerializer, Resource) SimpleTextSerializer()=default
~SimpleTextSerializer() override = default
virtual void setup(ComponentSpec &spec) override

Define the resource specification.

Parameters

spec – The reference to the component specification.

bool can_handle_message(const std::type_info &message_type) const
std::string serialize_to_string(std::any data)

Serialize data to a simple text string.

std::string serialize_tensor_to_string(const std::shared_ptr<Tensor> &tensor, bool log_data_content = false)

Serialize tensor data to a simple text string.

std::string serialize_tensormap_to_string(const TensorMap &tensor_map, bool log_data_content = false)

Serialize tensor map data to a simple text string.

std::string serialize_metadata_to_string(const std::shared_ptr<MetadataDictionary> &metadata)

Serialize metadata to a simple text string.

template<typename T>
inline void register_encoder(std::function<std::string(const std::any&)> encoder)

Register a custom encoder for a specific type.

Template Parameters

T – The type to register an encoder for

Parameters

encoder – Function that takes const std::any& and returns std::string

Previous Class BasicConsoleLogger
Next Class DataExporter
© Copyright 2022-2025, NVIDIA. Last updated on Jul 1, 2025.