From 68e6ac7b59d11c8da4361f84df6448a86fc2bdcc Mon Sep 17 00:00:00 2001 From: "stefan.schirmeister" Date: Wed, 18 Sep 2024 16:51:31 +0200 Subject: [PATCH] fix documentation --- docs/source/modes.rst | 2 +- simba/schedule.py | 15 +++++++++------ 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/docs/source/modes.rst b/docs/source/modes.rst index 12640d35..85ed29dd 100644 --- a/docs/source/modes.rst +++ b/docs/source/modes.rst @@ -79,7 +79,7 @@ Now, only rotations are left that are non-negative when viewed alone, but might In the end, the largest number of rotations that produce a non-negative result when taken together is returned as the optimized scenario. Recombination: split negative depot rotations into smaller rotations -------------- +-------------------------------------------------------------------- :: mode = split_negative_depb diff --git a/simba/schedule.py b/simba/schedule.py index 341e3ba3..60dd8354 100644 --- a/simba/schedule.py +++ b/simba/schedule.py @@ -211,15 +211,16 @@ def check_consistency(cls, schedule): def run(self, args, mode="distributed"): """Runs a schedule without assigning vehicles. - For external usage the core run functionality is accessible through this function. It - allows for defining a custom-made assign_vehicles method for the schedule. + For external usage the core run functionality is accessible through this function. + It allows for defining a custom-made assign_vehicles method for the schedule. + :param args: used arguments are rotation_filter, path to rotation ids, and rotation_filter_variable that sets mode (options: include, exclude) :type args: argparse.Namespace - :param mode: option of "distributed" or "greedy" + :param mode: SpiceEV strategy name :type mode: str :return: scenario - :rtype spice_ev.Scenario + :rtype: spice_ev.Scenario """ # Make sure all rotations have an assigned vehicle assert all([rot.vehicle_id is not None for rot in self.rotations.values()]) @@ -350,8 +351,9 @@ def assign_vehicles_w_min_recharge_soc(self): def assign_vehicles_custom(self, vehicle_assigns: Iterable[dict]): """ Assign vehicles on a custom basis. - Assign vehicles based on a datasource, containing all rotations, their vehicle_ids and - desired start socs. + Assign vehicles based on a datasource, + containing all rotations, their vehicle_ids and desired start socs. + :param vehicle_assigns: Iterable of dict with keys rotation_id, vehicle_id and start_soc for each rotation :type vehicle_assigns: Iterable[dict] @@ -1127,6 +1129,7 @@ def update_csv_file_info(file_info, gc_name): - set grid_connector_id - update csv_file path - set start_time and step_duration_s from CSV information if not given + :param file_info: csv information from electrified station :type file_info: dict :param gc_name: station name