pcg_gazebo.log

pcg_gazebo.log

Global logging methods.

update_log_dir

update_log_dir(add_timestamp=True)
Update the output folder for log files.

Input arguments

  • add_timestamp (type: bool, default: True): Add timestamp to folder name.
change_log_root_dir

change_log_root_dir(root_dir, update_log_dir=False, add_timestamp=True)
Change the directory for the output log files.

Input arguments

  • root_dir (type: str): New output log directory.
  • update_log_dir (type: bool, default: False): Update current global path for log directory.
  • add_timestamp (type: bool, default: True): Add timestamp to the directory folder name.
get_log_dir

get_log_dir()
Return the current output log directory.

create_logger

create_logger(name, log_filename=None, output_dir=None, log_level=20)
Create new instance of the logger.

Input arguments

  • name (type: str): Name of the instance.
  • log_filename (type: str, default: None): Name of the log filename, if None use name as filename.
  • output_dir (type: str, default: data): Output log directory. If None is provided, use the current log directory PCG_LOG_DIR.
  • log_level (type: int, default: logging.ERROR): Log level.

Returns

Logger object.