NVIDIA NvNeural SDK
2022.2
GPU inference framework for NVIDIA Nsight Deep Learning Designer
|
Logger interface class. More...
#include <nvneural/CoreTypes.h>
Public Types | |
using | VerbosityLevel = std::int32_t |
Typedef for verbosity levels. More... | |
![]() | |
using | RefCount = std::uint32_t |
Typedef used to track the number of active references to an object. | |
using | TypeId = std::uint64_t |
Every interface must define a unique TypeId. This should be randomized. | |
Public Member Functions | |
virtual NeuralResult | log (VerbosityLevel verbosity, const char *format,...) noexcept=0 |
Logs an informational message. More... | |
virtual NeuralResult | logError (VerbosityLevel verbosity, const char *format,...) noexcept=0 |
Logs an error message. More... | |
virtual NeuralResult | logWarning (VerbosityLevel verbosity, const char *format,...) noexcept=0 |
Logs a warning message. More... | |
virtual VerbosityLevel | verbosity () const noexcept=0 |
Retrieves the current verbosity level. More... | |
![]() | |
virtual RefCount | addRef () const noexcept=0 |
Increments the object's reference count. More... | |
virtual const void * | queryInterface (TypeId interface) const noexcept=0 |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. | |
virtual void * | queryInterface (TypeId interface) noexcept=0 |
Retrieves a new object interface pointer. More... | |
virtual RefCount | release () const noexcept=0 |
Decrements the object's reference count and destroy the object if the reference count reaches zero. More... | |
Static Public Attributes | |
static const IRefObject::TypeId | typeID = 0xd74335d06aa1ba61ul |
Interface TypeId for InterfaceOf purposes. | |
![]() | |
static const TypeId | typeID = 0x14ecc3f9de638e1dul |
Interface TypeId for InterfaceOf purposes. | |
Additional Inherited Members | |
![]() | |
virtual | ~IRefObject ()=default |
A protected destructor prevents accidental stack-allocation of IRefObjects or use with other smart pointer classes like std::unique_ptr. | |
Logger interface class.
All plugins should log to this class instead of other destinations such as files or stdout.
Most logger parameters are set by the owning tool or application and are thus not changeable from this interface.
using nvneural::ILogger::VerbosityLevel = std::int32_t |
Typedef for verbosity levels.
Higher values indicate lower importance.
As a general rule, important messages should use 0, debugging messages should use 1, and verbose debugging messages (object ctor/dtor tracing, for example) should use 2 or higher.
|
pure virtualnoexcept |
Logs an informational message.
verbosity | Verbosity level of the message. |
format | Printf-style format string. |
Implemented in nvneural::BufferedLogger.
|
pure virtualnoexcept |
Logs an error message.
Error messages indicate a serious failure has occurred and the user's workflow must stop. Recoverable or expected failures should probably be warnings, not errors.
Under normal conditions, plugins should not emit error messages at verbosity level 0.
Error messages do not necessarily have to be fatal errors and result in application exit; a failure to export a model because of insufficient disk space is a legitimate error message but would not require the model editor to exit.
verbosity | Verbosity level of the message. |
format | Printf-style format string. |
Implemented in nvneural::BufferedLogger.
|
pure virtualnoexcept |
Logs a warning message.
Warning messages indicate transient failures that the user should be aware of, but which did not result in failure of a major operation.
Under normal conditions, plugins should not emit warning messages at verbosity level 0.
verbosity | Verbosity level of the message. |
format | Printf-style format string. |
Implemented in nvneural::BufferedLogger.
|
pure virtualnoexcept |
Retrieves the current verbosity level.
Implemented in nvneural::BufferedLogger.