Logging

class fedot.core.log.SingletonMeta

Bases: type

This meta class can provide other classes with the Singleton pattern. It guarantees to create one and only class instance. Pass it to the metaclass parameter when defining your class as follows:

class YourClassName(metaclass=SingletonMeta)

class fedot.core.log.LogManager

Bases: object

get_logger(name, config_file, log_file=None)
Parameters
  • config_file (str) –

  • log_file (str) –

property debug

Returns the information about available loggers

clear_cache()
fedot.core.log.default_log(logger_name, log_file=None, verbose_level=2)
Parameters
  • logger_name (str) – string name for logger

  • log_file (Optional[str]) – path to the file where log messages will be recorded to

  • verbose_level (int) –

Return type

fedot.core.log.Log

:param verbose_level level of detalization :return Log: Log object

class fedot.core.log.Log(logger_name, config_json_file, output_verbosity_level=1, log_file=None)

Bases: object

This class provides with basic logging object

Parameters
  • logger_name (str) – name of the logger object

  • config_json_file (str) – json file with configuration for logger setup

  • log_file (str) – file where log messages are recorded to

message(message)

Record the message to user

info(message)

Record the INFO log message

debug(message)

Record the DEBUG log message

ext_debug(message)

Record the extended DEBUG log message

warn(message)

Record the WARN log message

error(message)

Record the ERROR log message

property handlers
release_handlers()

This function closes handlers of logger

fedot.core.log.start_end_log_decorator(start_msg='Starting...', end_msg='Finished')