smac.utils.io.output_writer module

class smac.utils.io.output_writer.OutputWriter[source]

Bases: object

Writing scenario to file.

write_inst_features_file(n_features: int, feat_dict, fn: str)[source]

Writes features to file.

Parameters:
  • n_features (int) – Number of features
  • feat_dict (dict) – Features to be written
  • fn (string) – File name of instance feature file
write_inst_file(insts: typing.List[str], fn: str)[source]

Writes instance-list to file.

Parameters:
  • insts (list<string>) – Instance list to be written
  • fn (string) – Output path
write_pcs_file(cs: ConfigSpace.configuration_space.ConfigurationSpace, fn: str)[source]

Writing ConfigSpace to file.

Parameters:
  • cs (ConfigurationSpace) – Config-space to be written
  • fn (string) – Output-file-path
write_scenario_file(scenario)[source]

Write scenario to a file (format is compatible with input_reader). Will overwrite if file exists. If you have arguments that need special parsing when saving, specify so in the _parse_argument-function. Creates output-dir if necessesary.

Parameters:scenario (Scenario) – Scenario to be written to file
Returns:status – False indicates that writing process failed
Return type:False or None