deepcave.runs.converters.dataframe¶
# DataFrameRun
This module provides utilities to create a Run object based on a DataFrame representation.
- ## Classes
DataFrameRun: Define a Run object based on a DataFrame representation.
Classes
|
Define a Run object based on a DataFrame representation. |
- class deepcave.runs.converters.dataframe.DataFrameRun(name, configspace=None, objectives=None, meta=None, path=None)[source]¶
Bases:
Run
Define a Run object based on a DataFrame representation.
Properties¶
- pathPath
The path to the run.
- classmethod from_path(path)[source]¶
Based on working_dir/run_name/*, return a new trials object.
- Parameters:
path (Union[Path, str]) – The path to base the trial object on.
- Return type:
The DataFrame run.
- property hash: str¶
Hash of the current run.
If the hash changes, the cache has to be cleared. This ensures that the cache always holds the latest results of the run.
- Returns:
The hash of the run.
- Return type:
str
- property latest_change: float | int¶
Get the timestamp of the latest change.
- Returns:
The latest change.
- Return type:
Union[float, int]
- static load_configspace(path)[source]¶
Load the configspace of the run.
- Returns:
The configspace of the run.
- Return type:
pd.DataFrame
- static load_objectives(path)[source]¶
Load the objectives of the run from the trials.csv file.
This method reads the trials.csv file and extracts the objectives from the column names. The objectives are expected in format metric:<name> [<lower>; <upper>] (<maximize>).
- Returns:
The metadata of the run.
- Return type:
pd.DataFrame