realtwin.func_lib.TurnInflowCali

class realtwin.func_lib.TurnInflowCali(scenario_config: dict = None, turn_inflow_config: dict = None, verbose: bool = True)[source]

Turn and Inflow Optimization class for SUMO calibration.

Parameters:
  • scenario_config (dict) – the configuration for the scenario.

  • turn_inflow_config (dict) – the configuration for the turn and inflow.

  • verbose (bool) – whether to print the information. Defaults to True.

Note

We use the mealpy library for optimization. mealpy is a Python library for optimization algorithms.

https://mealpy.readthedocs.io/en/latest/index.html

  1. The scenario_config parameter is used and can be modified from the input_config.yaml file.

  2. The turn_inflow_config parameter is used and can be modified from the input_config.yaml file.

__init__(scenario_config: dict = None, turn_inflow_config: dict = None, verbose: bool = True)[source]

Initialize the TurnInflowCalib class with scenario and turn inflow configurations.

Methods

__init__([scenario_config, ...])

Initialize the TurnInflowCalib class with scenario and turn inflow configurations.

run_GA(**kwargs)

Run Genetic Algorithm (GA) for behavior optimization.

run_SA(**kwargs)

Run Simulated Annealing (SA) for behavior optimization.

run_TS(**kwargs)

Run Tabu Search (TS) for behavior optimization.

run_vis(output_dir, model)

Save the results of the optimization.