Skip to content

Commit

Permalink
check if temporary speeds file path is not None
Browse files Browse the repository at this point in the history
  • Loading branch information
Michailidu authored and paulo308 committed Oct 30, 2023
1 parent b946386 commit 9036153
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ruth/tools/simulator.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@ def prepare_simulator(common_args: CommonArgs, vehicles_path) -> SingleNodeSimul
count_vehicles_tolerance_s, seed, speeds_path=speeds_path)
vehicles = load_vehicles(vehicles_path)
simulation = Simulation(vehicles, ss)
vehicles[0].routing_map.init_temporary_max_speeds(speeds_path)
if speeds_path is not None:
vehicles[0].routing_map.init_temporary_max_speeds(speeds_path)
else:
simulation = sim_state

Expand Down

0 comments on commit 9036153

Please sign in to comment.