Table of Contents¶
- t3co.cli.sweep
 - load_vehicle_scenario_energy
 - generate_ledger
 - create_results_filepath
 - export_results_to_csv
 - run_t3co
 
t3co.cli.sweep¶
load_vehicle_scenario_energy¶
Python
def load_vehicle_scenario_energy(
        selection: Union[int, str],
        config: Config,
        vehicle: Vehicle = None,
        scenario: Scenario = None,
        energy: Energy = None) -> Tuple[Vehicle, Scenario, Energy]
Loads the vehicle, scenario, and energy models based on the selection and config.
Arguments:
selectionUnion[int, str] - The selection index or string.configConfig - The configuration instance.
Returns:
Tuple[Vehicle, Scenario, Energy]: The vehicle, scenario, and energy models.
generate_ledger¶
Generates the ledger for the given selection and config.
Arguments:
selectionint - The selection index.configConfig - The configuration instance.
Returns:
Dict- The ledger as a dictionary.
create_results_filepath¶
Creates the results file path based on the config.
Arguments:
configConfig - The configuration instance.
Returns:
Path- The path to the results file.
export_results_to_csv¶
Python
def export_results_to_csv(
    reports_list: List[Dict],
    config: Config,
    output_path: Union[str, Path] = None,
    return_filepath: bool = True,
    return_df: bool = False,
    sort_values: bool = False
) -> Tuple[Union[Path, None], Union[pd.DataFrame, None]]
Exports the results to a CSV file.
Arguments:
reports_listList[Dict] - The list of reports.configConfig - The configuration instance.output_pathUnion[str, Path], optional - The output path for the CSV file. Defaults to None.return_filepathbool, optional - Whether to return the file path. Defaults to True.return_dfbool, optional - Whether to return the DataFrame. Defaults to False.sort_valuesbool, optional - Whether to sort the values by selection. Defaults to False.
Returns:
Tuple[Union[Path, None], Union[pd.DataFrame, None]]: The output path and DataFrame if specified.
run_t3co¶
Runs the T3CO analysis.
Arguments:
configConfig - The configuration instance.save_resultsbool, optional - Whether to save the results. Defaults to True.