dynode.utils.log.use_logging#
- dynode.utils.log.use_logging(level: Literal['none', 'debug', 'info', 'warn', 'error', 'critical'] = 'info', output: Literal['file', 'console', 'both'] = 'file', log_path: str = './logs') None #
Set or disable logging within the dynode package.
Uses standard python logging library to set up and customize a logger for DynODE. Logger instance can be retrieved from anywhere using logging.getLogger(“dynode”).
Parameters#
- levelstr, optional
Log level desired. Choices from “none”, “debug”, “info”, “warn”, “error” and “critical”. Defaults to “info”.
- outputstr, optional
Output for logs. Choices from “console”, “file”, and “both”. Defaults to “file”.
- log_pathstr, optional
folder path to store log files. Defaults to “./logs”.
Notes#
Log level of NONE is considered CRITICAL + 1 which you may see in various places such as in this function as logging.CRITICAL + 1