From d19b28af067feb787e6abe0765939d34c275172f Mon Sep 17 00:00:00 2001 From: "stefan.schirmeister" Date: Wed, 31 Jul 2024 13:12:04 +0200 Subject: [PATCH] add load_pickle to docs, minor doc fixes --- docs/source/modes.rst | 11 ++++++++++- docs/source/simulation_parameters.rst | 16 ++++++++++++++++ simba/schedule.py | 1 + 3 files changed, 27 insertions(+), 1 deletion(-) diff --git a/docs/source/modes.rst b/docs/source/modes.rst index 12640d35..6280e083 100644 --- a/docs/source/modes.rst +++ b/docs/source/modes.rst @@ -43,6 +43,15 @@ Simple Simulation The simple simulation case is the default mode. Its usage is explained in :ref:`Getting Started`. Every chain of modes starts with a simple simulation, even if it is not explicitly listed in the modes. The simulation takes the scenario as is. No parameters will be adjusted, optimized or changed in any way. The charging type for each vehicle is read from the rotation information from the trips.csv if this data is included. If the data is not included *preferred_charging_type* from the config file is used, as long as the provided vehicles data provides the preferred_charging_type for the specified vehicle type. +Load Pickle +----------- + +:: + + mode = ["load_pickle"] + +Instead of simulating given scenario, read in pickle file instead. Needs the `load_pickle` option to point to a pickle file. If the `load_pickle` option is set, `load_pickle` must be the first mode. However, this mode may come in later in the mode chain again, reloading schedule and scenario from file. Options in config file that are stored in schedule are ignored. + .. _neg_depb_to_oppb: Negative Depot to Opportunity Charger @@ -79,7 +88,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/docs/source/simulation_parameters.rst b/docs/source/simulation_parameters.rst index de8189c0..2c96fa18 100644 --- a/docs/source/simulation_parameters.rst +++ b/docs/source/simulation_parameters.rst @@ -80,6 +80,22 @@ The example (data/simba.cfg) contains parameter descriptions which are explained - false - Boolean - If activated, plots are displayed with every run of :ref:`report` mode + * - rotation_filter_variable + - null + - string + - How to filter rotations according to file 'rotation_filter': options are "include" (whitelist), "exclude" (blacklist), null (ignore) + * - create_trips_in_report + - false + - Boolean + - Write a new trips.csv during report mode to output directory? + * - create_pickle_in_report + - false + - Boolean + - Pickle current schedule and scenario during report mode + * - load_pickle + - Optional, no default given + - Path to pickle file + - Load schedule and scenario from this pickle file, expects load_pickle as first mode * - preferred_charging_type - depb diff --git a/simba/schedule.py b/simba/schedule.py index 98550307..17103650 100644 --- a/simba/schedule.py +++ b/simba/schedule.py @@ -921,6 +921,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