Skip to content

Commit

Permalink
added tests refs #21, #14718
Browse files Browse the repository at this point in the history
  • Loading branch information
namdre committed Dec 19, 2024
1 parent 48fa393 commit 0dbf85c
Show file tree
Hide file tree
Showing 10 changed files with 116 additions and 37 deletions.
Original file line number Diff line number Diff line change
@@ -1,12 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>

<!-- generated on Tue Jun 16 23:25:20 2020 by Eclipse SUMO Version v1_6_0+0773-161b41ac74
<!-- generated on 2024-12-19 17:12:59 by Eclipse SUMO sumo Version v1_21_0+1508-c45114015af
This data file and the accompanying materials
are made available under the terms of the Eclipse Public License v2.0
which accompanies this distribution, and is available at
http://www.eclipse.org/legal/epl-v20.html
SPDX-License-Identifier: EPL-2.0
<configuration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/sumoConfiguration.xsd">
This file 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
<sumoConfiguration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/sumoConfiguration.xsd">
<input>
<net-file value="net.net.xml"/>
Expand All @@ -29,12 +34,12 @@ SPDX-License-Identifier: EPL-2.0
<no-step-log value="true"/>
</report>
</configuration>
</sumoConfiguration>
-->

<lanechanges>
<change id="veh" type="t0" time="4.00" from="beg_2" to="beg_1" dir="-1" speed="10.40" pos="31.10" reason="strategic|urgent" leaderGap="None" leaderSecureGap="None" leaderSpeed="None" followerGap="None" followerSecureGap="None" followerSpeed="None" origLeaderGap="None" origLeaderSecureGap="None" origLeaderSpeed="None"/>
<change id="veh" type="t0" time="7.00" from="beg_1" to="beg_0" dir="-1" speed="18.20" pos="77.90" reason="strategic|urgent" leaderGap="None" leaderSecureGap="None" leaderSpeed="None" followerGap="None" followerSecureGap="None" followerSpeed="None" origLeaderGap="None" origLeaderSecureGap="None" origLeaderSpeed="None"/>
<change id="veh" type="t0" time="12.00" from="middle_2" to="middle_1" dir="-1" speed="25.35" pos="2.05" reason="strategic|urgent" leaderGap="None" leaderSecureGap="None" leaderSpeed="None" followerGap="None" followerSecureGap="None" followerSpeed="None" origLeaderGap="None" origLeaderSecureGap="None" origLeaderSpeed="None"/>
<change id="veh" type="t0" time="13.00" from="middle_1" to="middle_0" dir="-1" speed="20.85" pos="22.91" reason="strategic|urgent" leaderGap="None" leaderSecureGap="None" leaderSpeed="None" followerGap="None" followerSecureGap="None" followerSpeed="None" origLeaderGap="None" origLeaderSecureGap="None" origLeaderSpeed="None"/>
<change id="veh" type="t0" time="12.00" from="middle_2" to="middle_1" dir="-1" speed="24.88" pos="1.58" reason="strategic|urgent" leaderGap="None" leaderSecureGap="None" leaderSpeed="None" followerGap="None" followerSecureGap="None" followerSpeed="None" origLeaderGap="None" origLeaderSecureGap="None" origLeaderSpeed="None"/>
<change id="veh" type="t0" time="13.00" from="middle_1" to="middle_0" dir="-1" speed="20.38" pos="21.95" reason="strategic|urgent" leaderGap="None" leaderSecureGap="None" leaderSpeed="None" followerGap="None" followerSecureGap="None" followerSpeed="None" origLeaderGap="None" origLeaderSecureGap="None" origLeaderSpeed="None"/>
</lanechanges>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<routes>
<route id="r" edges="beg middle end"/>
<route id="r" edges="beg beg2 middle end"/>
<!--
the vehicle should start moving to the rightmost lane becausee the left lanes are all dead ends
-->
Expand Down
Empty file.
Empty file.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
<routes>
<vType id="t0" sigma="0" lcStrategicLookahead="50"/>
</routes>
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
<?xml version="1.0" encoding="UTF-8"?>

<!-- generated on 2024-12-19 17:13:20 by Eclipse SUMO sumo Version v1_21_0+1508-c45114015af
This data file and the accompanying materials
are made available under the terms of the Eclipse Public License v2.0
which accompanies this distribution, and is available at
http://www.eclipse.org/legal/epl-v20.html
This file 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
<sumoConfiguration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/sumoConfiguration.xsd">
<input>
<net-file value="net.net.xml"/>
<route-files value="input_routes.rou.xml"/>
<additional-files value="input_additional.add.xml"/>
</input>
<output>
<write-license value="true"/>
<lanechange-output value="lanechanges.xml"/>
</output>
<processing>
<default.speeddev value="0"/>
</processing>
<report>
<xml-validation value="never"/>
<duration-log.disable value="true"/>
<no-step-log value="true"/>
</report>
</sumoConfiguration>
-->

<lanechanges>
<change id="veh" type="t0" time="9.00" from="beg2_2" to="beg2_1" dir="-1" speed="23.40" pos="22.10" reason="strategic|urgent" leaderGap="None" leaderSecureGap="None" leaderSpeed="None" followerGap="None" followerSecureGap="None" followerSpeed="None" origLeaderGap="None" origLeaderSecureGap="None" origLeaderSpeed="None"/>
<change id="veh" type="t0" time="10.00" from="beg2_1" to="beg2_0" dir="-1" speed="26.00" pos="48.10" reason="strategic|urgent" leaderGap="None" leaderSecureGap="None" leaderSpeed="None" followerGap="None" followerSecureGap="None" followerSpeed="None" origLeaderGap="None" origLeaderSecureGap="None" origLeaderSpeed="None"/>
<change id="veh" type="t0" time="12.00" from="middle_2" to="middle_1" dir="-1" speed="24.88" pos="1.58" reason="strategic|urgent" leaderGap="None" leaderSecureGap="None" leaderSpeed="None" followerGap="None" followerSecureGap="None" followerSpeed="None" origLeaderGap="None" origLeaderSecureGap="None" origLeaderSpeed="None"/>
<change id="veh" type="t0" time="13.00" from="middle_1" to="middle_0" dir="-1" speed="20.38" pos="21.95" reason="strategic|urgent" leaderGap="None" leaderSecureGap="None" leaderSpeed="None" followerGap="None" followerSecureGap="None" followerSpeed="None" origLeaderGap="None" origLeaderSecureGap="None" origLeaderSpeed="None"/>
</lanechanges>
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
--no-step-log --no-duration-log --net-file=net.net.xml -r=input_routes.rou.xml -a input_additional.add.xml
--lanechange-output lanechanges.xml
Empty file.
81 changes: 51 additions & 30 deletions tests/sumo/lc_model/strategic/towards_right/net.net.xml
Original file line number Diff line number Diff line change
@@ -1,64 +1,85 @@
<?xml version="1.0" encoding="UTF-8"?>

<!-- generated on Fri 01 Nov 2013 09:35:18 AM CET by Netedit Version dev-SVN-r14990
This data file and the accompanying materials
are made available under the terms of the Eclipse Public License v2.0
which accompanies this distribution, and is available at
http://www.eclipse.org/legal/epl-v20.html
SPDX-License-Identifier: EPL-2.0
<configuration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/netedit.exeConfiguration.xsd">
<!-- generated on 2024-12-19 17:12:40 by Eclipse SUMO netedit Version v1_21_0+1508-c45114015af
<neteditConfiguration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/neteditConfiguration.xsd">
<input>
<sumo-net-file value="net2.net.xml"/>
<sumo-net-file value="net.net.xml"/>
</input>
<output>
<output-file value="net2.net.xml"/>
<output-file value="net.net.xml"/>
</output>
<processing>
<no-internal-links value="true"/>
<no-turnarounds value="true"/>
<geometry.min-radius.fix.railways value="false"/>
<geometry.max-grade.fix value="false"/>
<offset.disable-normalization value="true"/>
<lefthand value="0"/>
</processing>
</configuration>
<junctions>
<no-internal-links value="true"/>
<no-turnarounds value="true"/>
<junctions.corner-detail value="0"/>
<junctions.limit-turn-speed value="-1.00"/>
<rectangular-lane-cut value="0"/>
</junctions>
<pedestrian>
<walkingareas value="0"/>
</pedestrian>
</neteditConfiguration>
-->

<net version="0.13" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/net_file.xsd">
<net version="1.20" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/net_file.xsd">

<location netOffset="0.00,0.00" convBoundary="-200.00,-13.00,200.00,0.00" origBoundary="-10000000000.00,-10000000000.00,10000000000.00,10000000000.00" projParameter="!"/>

<edge id="beg" from="gneJ0" to="gneJ7" priority="1">
<lane id="beg_0" index="0" speed="36.00" length="200.00" shape="-200.00,-8.25 -1.50,-8.25"/>
<lane id="beg_1" index="1" speed="36.00" length="200.00" shape="-200.00,-4.95 -1.50,-4.95"/>
<lane id="beg_2" index="2" speed="36.00" length="200.00" shape="-200.00,-1.65 -1.50,-1.65"/>
<edge id="beg" from="gneJ0" to="J0" priority="1">
<lane id="beg_0" index="0" speed="36.00" length="100.00" shape="-200.00,-8.00 -100.00,-8.00"/>
<lane id="beg_1" index="1" speed="36.00" length="100.00" shape="-200.00,-4.80 -100.00,-4.80"/>
<lane id="beg_2" index="2" speed="36.00" length="100.00" shape="-200.00,-1.60 -100.00,-1.60"/>
</edge>
<edge id="beg2" from="J0" to="gneJ7" priority="1">
<lane id="beg2_0" index="0" speed="36.00" length="100.00" shape="-100.00,-8.00 -4.00,-8.00"/>
<lane id="beg2_1" index="1" speed="36.00" length="100.00" shape="-100.00,-4.80 -4.00,-4.80"/>
<lane id="beg2_2" index="2" speed="36.00" length="100.00" shape="-100.00,-1.60 -4.00,-1.60"/>
</edge>
<edge id="end" from="gneJ1" to="gneJ6" priority="1" shape="51.19,-12.73 200.00,-13.00">
<lane id="end_0" index="0" speed="36.00" length="150.35" shape="52.09,-14.38 200.00,-14.65"/>
<lane id="end_0" index="0" speed="36.00" length="149.71" shape="54.59,-14.34 200.00,-14.60"/>
</edge>
<edge id="middle" from="gneJ7" to="gneJ1" priority="1">
<lane id="middle_0" index="0" speed="36.00" length="61.33" shape="1.50,-14.85 49.09,-14.85"/>
<lane id="middle_1" index="1" speed="36.00" length="61.33" shape="1.50,-11.55 49.09,-11.55"/>
<lane id="middle_2" index="2" speed="36.00" length="61.33" shape="1.50,-8.25 49.09,-8.25"/>
<lane id="middle_3" index="3" speed="36.00" length="61.33" shape="1.50,-4.95 49.09,-4.95"/>
<lane id="middle_4" index="4" speed="36.00" length="61.33" shape="1.50,-1.65 49.09,-1.65"/>
<lane id="middle_0" index="0" speed="36.00" length="58.46" shape="4.00,-14.40 46.59,-14.40"/>
<lane id="middle_1" index="1" speed="36.00" length="58.46" shape="4.00,-11.20 46.59,-11.20"/>
<lane id="middle_2" index="2" speed="36.00" length="58.46" shape="4.00,-8.00 46.59,-8.00"/>
<lane id="middle_3" index="3" speed="36.00" length="58.46" shape="4.00,-4.80 46.59,-4.80"/>
<lane id="middle_4" index="4" speed="36.00" length="58.46" shape="4.00,-1.60 46.59,-1.60"/>
</edge>

<junction id="gneJ0" type="unregulated" x="-200.00" y="0.00" incLanes="" intLanes="" shape="-200.00,-0.05 -200.00,-9.85"/>
<junction id="gneJ1" type="priority" x="50.00" y="0.00" incLanes="middle_0 middle_1 middle_2 middle_3 middle_4" intLanes="" shape="52.09,-12.78 52.08,-15.98 49.09,-16.45 49.09,-0.05">
<junction id="J0" type="priority" x="-100.00" y="0.00" incLanes="beg_0 beg_1 beg_2" intLanes="" shape="-100.00,0.00 -100.00,-9.60 -100.00,0.00">
<request index="0" response="000" foes="000"/>
<request index="1" response="000" foes="000"/>
<request index="2" response="000" foes="000"/>
</junction>
<junction id="gneJ0" type="dead_end" x="-200.00" y="0.00" incLanes="" intLanes="" shape="-200.00,0.00 -200.00,-9.60"/>
<junction id="gneJ1" type="priority" x="50.00" y="0.00" incLanes="middle_0 middle_1 middle_2 middle_3 middle_4" intLanes="" shape="54.59,-12.74 54.58,-15.94 46.59,-16.00 46.59,0.00">
<request index="0" response="0" foes="0"/>
</junction>
<junction id="gneJ6" type="unregulated" x="200.00" y="-13.00" incLanes="end_0" intLanes="" shape="199.99,-16.25 200.00,-13.05"/>
<junction id="gneJ7" type="priority" x="0.00" y="0.00" incLanes="beg_0 beg_1 beg_2" intLanes="" shape="1.50,-0.05 1.50,-16.45 -1.50,-9.85 -1.50,-0.05">
<junction id="gneJ6" type="dead_end" x="200.00" y="-13.00" incLanes="end_0" intLanes="" shape="199.99,-16.20 200.00,-13.00"/>
<junction id="gneJ7" type="priority" x="0.00" y="0.00" incLanes="beg2_0 beg2_1 beg2_2" intLanes="" shape="4.00,0.00 4.00,-16.00 -4.00,-9.60 -4.00,0.00">
<request index="0" response="000" foes="000"/>
<request index="1" response="000" foes="000"/>
<request index="2" response="000" foes="000"/>
</junction>

<connection from="beg" to="middle" fromLane="0" toLane="2" dir="s" state="M"/>
<connection from="beg" to="middle" fromLane="1" toLane="3" dir="s" state="M"/>
<connection from="beg" to="middle" fromLane="2" toLane="4" dir="s" state="M"/>
<connection from="beg" to="beg2" fromLane="0" toLane="0" dir="s" state="M"/>
<connection from="beg" to="beg2" fromLane="1" toLane="1" dir="s" state="M"/>
<connection from="beg" to="beg2" fromLane="2" toLane="2" dir="s" state="M"/>
<connection from="beg2" to="middle" fromLane="0" toLane="2" dir="s" state="M"/>
<connection from="beg2" to="middle" fromLane="1" toLane="3" dir="s" state="M"/>
<connection from="beg2" to="middle" fromLane="2" toLane="4" dir="s" state="M"/>
<connection from="middle" to="end" fromLane="0" toLane="0" dir="s" state="M"/>

</net>
3 changes: 3 additions & 0 deletions tests/sumo/lc_model/strategic/towards_right/testsuite.sumo
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
default_model

# test changing later with reduced lookahead
lookahead

0 comments on commit 0dbf85c

Please sign in to comment.