-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
255 additions
and
0 deletions.
There are no files selected for viewing
Empty file.
1 change: 1 addition & 0 deletions
1
tests/complex/traci/vehicle/replaceStop/remove_teleport_once_stopDelay/errors.complex.meso
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Warning: Network contains internal links which are ignored. Vehicles will 'jump' across junctions and thus underestimate route lengths and travel times. |
9 changes: 9 additions & 0 deletions
9
tests/complex/traci/vehicle/replaceStop/remove_teleport_once_stopDelay/input_routes.rou.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
|
||
<routes xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/routes_file.xsd"> | ||
<trip id="ego" depart="0.00" from="A0A1" to="D2D3"> | ||
<stop busStop="busStop_A1B1" duration="60.00" arrival="5" until="25"/> | ||
<stop busStop="busStop_B1C1" duration="60.00" arrival="30" until="55"/> | ||
<stop busStop="busStop_C1D1" duration="60.00" arrival="60" until="85"/> | ||
</trip> | ||
</routes> |
1 change: 1 addition & 0 deletions
1
tests/complex/traci/vehicle/replaceStop/remove_teleport_once_stopDelay/options.complex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
tests/complex/traci/vehicle/replaceStop/remove_teleport_once_stopDelay/runner.py |
107 changes: 107 additions & 0 deletions
107
tests/complex/traci/vehicle/replaceStop/remove_teleport_once_stopDelay/output.complex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
Retrying in 1 seconds | ||
0.0 nextStop=busStop_A1B1 d=48.591 aD=9.590697486366548 | ||
1.0 nextStop=busStop_A1B1 d=49.244 aD=10.244310103017593 | ||
2.0 nextStop=busStop_A1B1 d=49.344 aD=10.343717788008815 | ||
3.0 nextStop=busStop_A1B1 d=49.311 aD=10.311170867923213 | ||
4.0 nextStop=busStop_A1B1 d=49.436 aD=10.436325247869219 | ||
5.0 nextStop=busStop_A1B1 d=49.458 aD=10.457948530156282 | ||
6.0 nextStop= d=-1.0 aD=-1073741824.0 | ||
7.0 nextStop= d=-1.0 aD=-1073741824.0 | ||
8.0 nextStop= d=-1.0 aD=-1073741824.0 | ||
9.0 nextStop= d=-1.0 aD=-1073741824.0 | ||
10.0 nextStop= d=-1.0 aD=-1073741824.0 | ||
11.0 nextStop= d=-1.0 aD=-1073741824.0 | ||
12.0 nextStop= d=-1.0 aD=-1073741824.0 | ||
13.0 nextStop=busStop_C1D1 d=0.0 aD=-41.626915711253986 | ||
14.0 nextStop=busStop_C1D1 d=0.0 aD=-41.580302405232615 | ||
15.0 nextStop=busStop_C1D1 d=0.0 aD=-41.5366697127942 | ||
16.0 nextStop=busStop_C1D1 d=0.0 aD=-41.60519996574518 | ||
17.0 nextStop=busStop_C1D1 d=0.0 aD=-41.70071260353277 | ||
18.0 nextStop=busStop_C1D1 d=0.0 aD=-41.49058931483599 | ||
19.0 nextStop=busStop_C1D1 d=0.0 aD=-40.948485985681245 | ||
20.0 nextStop=busStop_C1D1 d=0.0 aD=-39.98465108137609 | ||
21.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
22.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
23.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
24.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
25.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
26.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
27.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
28.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
29.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
30.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
31.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
32.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
33.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
34.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
35.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
36.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
37.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
38.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
39.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
40.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
41.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
42.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
43.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
44.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
45.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
46.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
47.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
48.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
49.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
50.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
51.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
52.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
53.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
54.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
55.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
56.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
57.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
58.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
59.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
60.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
61.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
62.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
63.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
64.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
65.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
66.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
67.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
68.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
69.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
70.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
71.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
72.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
73.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
74.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
75.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
76.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
77.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
78.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
79.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
80.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
81.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
82.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
83.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
84.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
85.0 nextStop=busStop_C1D1 d=0.0 aD=-40.0 | ||
86.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
87.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
88.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
89.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
90.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
91.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
92.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
93.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
94.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
95.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
96.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
97.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
98.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
99.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
100.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
101.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
102.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
103.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
104.0 nextStop=None d=-1.0 aD=-1073741824.0 | ||
105.0 nextStop=None d=-1.0 aD=-1073741824.0 |
55 changes: 55 additions & 0 deletions
55
tests/complex/traci/vehicle/replaceStop/remove_teleport_once_stopDelay/runner.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
#!/usr/bin/env python | ||
# -*- coding: utf-8 -*- | ||
# Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.dev/sumo | ||
# Copyright (C) 2008-2024 German Aerospace Center (DLR) and others. | ||
# This program and the accompanying materials are made available under the | ||
# terms of the Eclipse Public License 2.0 which is available at | ||
# https://www.eclipse.org/legal/epl-2.0/ | ||
# This Source Code may also be made available under the following Secondary | ||
# Licenses when the conditions for such availability set forth in the Eclipse | ||
# Public License 2.0 are satisfied: GNU General Public License, version 2 | ||
# or later which is available at | ||
# https://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html | ||
# SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later | ||
|
||
# @file runner.py | ||
# @author Jakob Erdmann | ||
# @date 2017-01-23 | ||
|
||
|
||
from __future__ import print_function | ||
from __future__ import absolute_import | ||
import os | ||
import sys | ||
|
||
if "SUMO_HOME" in os.environ: | ||
sys.path.append(os.path.join(os.environ["SUMO_HOME"], "tools")) | ||
|
||
import traci # noqa | ||
import sumolib # noqa | ||
import traci.constants as tc # noqa | ||
|
||
|
||
sumoBinary = sumolib.checkBinary('sumo') | ||
traci.start([sumoBinary, | ||
"-n", "input_net4.net.xml", | ||
"-a", "input_additional4.add.xml", | ||
"-r", "input_routes.rou.xml", | ||
"--no-step-log", | ||
"--vehroute-output", "vehroutes.xml", | ||
] + sys.argv[1:]) | ||
|
||
vehID = "ego" | ||
|
||
while traci.simulation.getMinExpectedNumber() > 0: | ||
nextStops = traci.vehicle.getStops(vehID) | ||
print("%s nextStop=%s d=%s aD=%s" % ( | ||
traci.simulation.getTime(), | ||
nextStops[0].stoppingPlaceID if nextStops else "None", | ||
traci.vehicle.getStopDelay(vehID), | ||
traci.vehicle.getStopArrivalDelay(vehID))) | ||
if traci.simulation.getTime() == 5: | ||
traci.vehicle.replaceStop(vehID, 1, "", teleport=0) | ||
traci.vehicle.replaceStop(vehID, 0, "", teleport=1) | ||
traci.simulationStep() | ||
traci.close() |
37 changes: 37 additions & 0 deletions
37
tests/complex/traci/vehicle/replaceStop/remove_teleport_once_stopDelay/vehroutes.complex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
|
||
<!-- generated on 2024-03-27 09:32:50 by Eclipse SUMO sumo Version v1_19_0+1554-e605c7d1feb | ||
<configuration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/sumoConfiguration.xsd"> | ||
<input> | ||
<net-file value="input_net4.net.xml"/> | ||
<route-files value="input_routes.rou.xml"/> | ||
<additional-files value="input_additional4.add.xml"/> | ||
</input> | ||
<output> | ||
<vehroute-output value="vehroutes.xml"/> | ||
</output> | ||
<report> | ||
<no-step-log value="true"/> | ||
</report> | ||
<traci_server> | ||
<remote-port value="51447"/> | ||
</traci_server> | ||
</configuration> | ||
--> | ||
|
||
<routes xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/routes_file.xsd"> | ||
<vehicle id="ego" depart="0.00" arrival="105.00"> | ||
<routeDistribution> | ||
<route replacedOnEdge="A0A1" reason="traci:replaceStop" replacedAtTime="5.00" probability="0" edges="A0A1 A1B1 B1C1 C1D1 D1D2 D2D3"/> | ||
<route edges="A0A1 C1D1 D1D2 D2D3"/> | ||
</routeDistribution> | ||
<stop edge="A0A1" speed="1000.00" jump="0.00"/> | ||
<stop busStop="busStop_C1D1" arrival="60.00" duration="60.00" until="85.00"/> | ||
</vehicle> | ||
|
||
</routes> |
42 changes: 42 additions & 0 deletions
42
...s/complex/traci/vehicle/replaceStop/remove_teleport_once_stopDelay/vehroutes.complex.meso
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
|
||
<!-- generated on 2023-06-28 08:44:33 by Eclipse SUMO sumo Version v1_17_0+1317-06f42fb | ||
<configuration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/sumoConfiguration.xsd"> | ||
<input> | ||
<net-file value="input_net4.net.xml"/> | ||
<route-files value="input_routes.rou.xml"/> | ||
<additional-files value="input_additional4.add.xml"/> | ||
</input> | ||
<output> | ||
<vehroute-output value="vehroutes.xml"/> | ||
</output> | ||
<report> | ||
<no-step-log value="true"/> | ||
</report> | ||
<traci_server> | ||
<remote-port value="57617"/> | ||
</traci_server> | ||
<mesoscopic> | ||
<mesosim value="true"/> | ||
<meso-junction-control value="true"/> | ||
</mesoscopic> | ||
</configuration> | ||
--> | ||
|
||
<routes xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/routes_file.xsd"> | ||
<vehicle id="ego" depart="0.00" arrival="13.00"> | ||
<routeDistribution> | ||
<route replacedOnEdge="A0A1" reason="traci:replaceStop" replacedAtTime="5.00" probability="0" edges="A0A1 A1B1 B1C1 C1D1 D1D2 D2D3"/> | ||
<route replacedOnEdge="A0A1" reason="traci:replaceStop" replacedAtTime="5.00" probability="0" edges="A0A1 A1B1 B1C1 D2D3"/> | ||
<route replacedOnEdge="A0A1" reason="traci:replaceStop" replacedAtTime="5.00" probability="0" edges="A0A1 A1B1 D2D3"/> | ||
<route edges="A0A1 D2D3"/> | ||
</routeDistribution> | ||
</vehicle> | ||
|
||
</routes> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters