NVIDIA Holoscan SDK v0.6
Holoscan v0.6

Function holoscan::set_log_pattern

void holoscan::set_log_pattern(std::string pattern = "")

Set global log format string.

If the environment variable HOLOSCAN_LOG_FORMAT is set, the log pattern will be overridden by the value of the environment variable.

If the user has not set the log pattern explicitly before Application::Application() is called and no environment variable (HOLOSCAN_LOG_FORMAT) is set, the default log pattern will be used.

HOLOSCAN_LOG_FORMAT can be set to one of the following values:

  • SHORT: prints message severity level, and message

  • DEFAULT: prints message severity level, filename:linenumber, and message

  • LONG: prints timestamp, application, message severity level, filename:linenumber, and message

  • FULL: prints timestamp, thread id, application, message severity level, filename:linenumber, and message

Or, a custom format string can be specified. Please refer to the spdlog documentation for the format string syntax.

Parameters

pattern – The format string.

© Copyright 2022-2023, NVIDIA. Last updated on Feb 9, 2024.