experiments.experiments.Experiment

class Experiment(model_name, results_dir)

Bases: object

__init__(model_name, results_dir)

Base class for running experiments

Parameters:
  • model_name (str) – The string name of the baseline model, e.g ‘logistic_regression’

  • results_dir (str) – Parent directory for saving any experimental results

__repr__()

Return repr(self).

Methods

aggregate_results(**kwargs)

Group together the data in each trial file into a single CSV file.

write_trial_result(data, colnames, trial_dir, verbose=False)

Write out the results from a single trial to a file.

Parameters:
  • data (List) – The information to save

  • colnames (List(str)) – Names of the items in the data list. These will comprise the header of the saved file

  • trial_dir (str) – The directory in which to save the file

  • verbose (bool) – if True, prints out saved filename