FlatFile#

class ioh.iohcpp.logger.FlatFile(self: ioh.iohcpp.logger.FlatFile, triggers: List[ioh.iohcpp.logger.trigger.Trigger], properties: List[ioh.iohcpp.logger.property.AbstractProperty], filename: str = 'IOH.dat', output_directory: ioh.iohcpp.logger.Path = './', separator: str = '\t', comment: str = '#', no_value: str = 'None', end_of_line: str = '\n', repeat_header: bool = False, store_positions: bool = False, common_header_titles: List[str] = ['suite_name', 'problem_name', 'problem_id', 'problem_instance', 'optimization_type', 'dimension', 'run'])#

Bases: AbstractLogger

A logger which stores all tracked properties to a file.

Parameters:
  • triggers (list[Trigger]) – List of triggers, i.e. when to trigger logging

  • properties (list[Property]) – The list of properties to keep track of

  • filename (str = "IOH.dat") – The file to log to

  • output_directory (str = "./") – The path to which to write the file

  • separator (str = "t") – The column seperator

  • comment (str = "#") – The comment character

  • no_value (str = "None") – The NaN character

  • end_of_line (str = "n") – The eol character

  • repeat_header (bool = false) – Boolean value which indicates whether to repeat the header for every new run.

  • store_positions (bool = false) – Boolean value which indicates whether to store the x-positions in the file

Attributes Summary

filename

output_directory

problem

Reference to the currently attached problem

Methods Summary

add_trigger(self, arg0)

Add a trigger to the logger

call(self, arg0)

Performs logging behaviour

reset(self)

Reset the state of the logger

watch(*args, **kwargs)

Overloaded function.

Attributes Documentation

filename#
output_directory#
problem#

Reference to the currently attached problem

Methods Documentation

add_trigger(self: ioh.iohcpp.logger.Logger, arg0: ioh.iohcpp.logger.trigger.Trigger) None#

Add a trigger to the logger

call(self: ioh.iohcpp.logger.Logger, arg0: ioh.iohcpp.LogInfo) None#

Performs logging behaviour

reset(self: ioh.iohcpp.logger.Logger) None#

Reset the state of the logger

watch(*args, **kwargs)#

Overloaded function.

  1. watch(self: ioh.iohcpp.logger.FlatFile, arg0: ioh.iohcpp.logger.property.AbstractProperty) -> None

  2. watch(self: ioh.iohcpp.logger.FlatFile, arg0: object, arg1: str) -> None

  3. watch(self: ioh.iohcpp.logger.FlatFile, arg0: object, arg1: List[str]) -> None