Skip to content

Commit 9bccca2

Browse files
committedMay 25, 2024·
build: move to MATSim 2024.0
1 parent d3b1911 commit 9bccca2

File tree

17 files changed

+80
-75
lines changed

17 files changed

+80
-75
lines changed
 

‎ees/pom.xml

+23-12
Original file line numberDiff line numberDiff line change
@@ -74,13 +74,29 @@
7474
</profile>
7575
</profiles>
7676

77+
<!-- DS 24/05/24: All these repositories are required for finding MATSim dependencies -->
7778
<repositories>
7879
<repository>
79-
<!-- Geotools is not on Maven central -->
8080
<id>osgeo</id>
8181
<name>Geotools repository</name>
8282
<url>https://repo.osgeo.org/repository/release</url>
8383
</repository>
84+
<repository>
85+
<id>matsim</id>
86+
<url>https://repo.matsim.org/repository/matsim</url>
87+
</repository>
88+
<repository>
89+
<id>jogl</id>
90+
<url>https://jogamp.org/deployment/maven/</url>
91+
</repository>
92+
<repository>
93+
<id>topobyte</id>
94+
<url>https://mvn.topobyte.de</url>
95+
</repository>
96+
<repository>
97+
<id>slimjars</id>
98+
<url>https://mvn.slimjars.com</url>
99+
</repository>
84100
</repositories>
85101

86102
<dependencies>
@@ -98,6 +114,12 @@
98114
<groupId>io.github.agentsoz</groupId>
99115
<artifactId>bdi-matsim</artifactId>
100116
<version>3.0.1-SNAPSHOT</version>
117+
<exclusions>
118+
<exclusion>
119+
<artifactId>slf4j-api</artifactId>
120+
<groupId>org.slf4j</groupId>
121+
</exclusion>
122+
</exclusions>
101123
</dependency>
102124
<dependency>
103125
<groupId>io.github.agentsoz</groupId>
@@ -133,17 +155,6 @@
133155
<version>4.13.1</version>
134156
<!--<scope>test</scope>-->
135157
</dependency>
136-
<dependency>
137-
<groupId>com.google.inject</groupId>
138-
<artifactId>guice</artifactId>
139-
<version>5.1.0</version>
140-
</dependency>
141-
<!-- for easy CSV parsing -->
142-
<dependency>
143-
<groupId>org.apache.commons</groupId>
144-
<artifactId>commons-csv</artifactId>
145-
<version>1.6</version>
146-
</dependency>
147158
<!-- for easy EPSG transforms -->
148159
<dependency>
149160
<groupId>org.geotools</groupId>

‎ees/scenarios/grid/ar-1a-mat.xml

+6-6
Original file line numberDiff line numberDiff line change
@@ -39,16 +39,16 @@
3939
<param name="inputPlansFile" value="ar-1a-pop.xml" />
4040
</module>
4141

42-
<module name="controler">
42+
<module name="controller">
4343
<param name="outputDirectory" value="output" />
4444
<param name="firstIteration" value="0" />
4545
<param name="lastIteration" value="0" />
4646
<param name="mobsim" value="qsim" />
4747
<param name = "snapshotFormat" value="googleearth"/> <!-- enable KML output; also must enable snapshotperiod -->
4848
</module>
4949

50-
<module name="controler">
51-
<param name= "routingAlgorithmType" value="FastAStarLandmarks" />
50+
<module name="controller">
51+
<param name= "routingAlgorithmType" value="AStarLandmarks" />
5252
</module>
5353

5454
<module name="qsim">
@@ -63,9 +63,9 @@
6363

6464
</module>
6565

66-
<module name="planCalcScore">
66+
<module name="scoring">
6767
<param name="learningRate" value="1.0" />
68-
<param name="BrainExpBeta" value="2.0" />
68+
<param name="brainExpBeta" value="2.0" />
6969

7070
<parameterset type="scoringParameters">
7171
<param name="lateArrival" value="-18" />
@@ -100,7 +100,7 @@
100100
</parameterset>
101101
</module>
102102

103-
<module name="strategy">
103+
<module name="replanning">
104104
<param name="maxAgentPlanMemorySize" value="5" /> <!-- 0 means unlimited -->
105105

106106
<parameterset type="strategysettings">

‎ees/scenarios/grid/ar-2a-mat.xml

+6-6
Original file line numberDiff line numberDiff line change
@@ -39,16 +39,16 @@
3939
<param name="inputPlansFile" value="ar-2a-pop.xml" />
4040
</module>
4141

42-
<module name="controler">
42+
<module name="controller">
4343
<param name="outputDirectory" value="output" />
4444
<param name="firstIteration" value="0" />
4545
<param name="lastIteration" value="0" />
4646
<param name="mobsim" value="qsim" />
4747
<param name = "snapshotFormat" value="googleearth"/> <!-- enable KML output; also must enable snapshotperiod -->
4848
</module>
4949

50-
<module name="controler">
51-
<param name= "routingAlgorithmType" value="FastAStarLandmarks" />
50+
<module name="controller">
51+
<param name= "routingAlgorithmType" value="AStarLandmarks" />
5252
</module>
5353

5454
<module name="qsim">
@@ -63,9 +63,9 @@
6363

6464
</module>
6565

66-
<module name="planCalcScore">
66+
<module name="scoring">
6767
<param name="learningRate" value="1.0" />
68-
<param name="BrainExpBeta" value="2.0" />
68+
<param name="brainExpBeta" value="2.0" />
6969

7070
<parameterset type="scoringParameters">
7171
<param name="lateArrival" value="-18" />
@@ -100,7 +100,7 @@
100100
</parameterset>
101101
</module>
102102

103-
<module name="strategy">
103+
<module name="replanning">
104104
<param name="maxAgentPlanMemorySize" value="5" /> <!-- 0 means unlimited -->
105105

106106
<parameterset type="strategysettings">

‎ees/scenarios/grid/ar-2a-pop.xml

-5
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,6 @@
33

44
<population>
55

6-
<attributes>
7-
<attribute name="coordinateReferenceSystem" class="java.lang.String">Atlantis</attribute>
8-
</attributes>
9-
10-
116
<!-- ====================================================================== -->
127

138
<person id="0">

‎ees/scenarios/grid/ar-congestion-mat.xml

+7-7
Original file line numberDiff line numberDiff line change
@@ -40,16 +40,16 @@
4040
<param name="inputPlansFile" value="ar-20a-pop.xml" />
4141
</module>
4242

43-
<module name="controler">
43+
<module name="controller">
4444
<param name="outputDirectory" value="output" />
4545
<param name="firstIteration" value="0" />
4646
<param name="lastIteration" value="0" />
4747
<param name="mobsim" value="qsim" />
4848
<param name = "snapshotFormat" value="googleearth"/> <!-- enable KML output; also must enable snapshotperiod -->
4949
</module>
5050

51-
<module name="controler">
52-
<param name= "routingAlgorithmType" value="FastAStarLandmarks" />
51+
<module name="controller">
52+
<param name= "routingAlgorithmType" value="AStarLandmarks" />
5353
</module>
5454

5555
<module name="qsim">
@@ -65,17 +65,17 @@
6565
<param name = "numberOfThreads" value="4"/>
6666
</module>
6767

68-
<module name="parallelEventHandling">
68+
<module name="eventsManager">
6969
<param name="estimatedNumberOfEvents" value="null" />
7070
<!-- Null means let matsim decide -->
7171
<param name="numberOfThreads" value="null" />
7272
<!-- each handler will be assigned to a thread if enabled -->
7373
<param name="oneThreadPerHandler" value="false" />
7474
</module>
7575

76-
<module name="planCalcScore">
76+
<module name="scoring">
7777
<param name="learningRate" value="1.0" />
78-
<param name="BrainExpBeta" value="2.0" />
78+
<param name="brainExpBeta" value="2.0" />
7979

8080
<parameterset type="scoringParameters">
8181
<param name="lateArrival" value="-18" />
@@ -110,7 +110,7 @@
110110
</parameterset>
111111
</module>
112112

113-
<module name="strategy">
113+
<module name="replanning">
114114
<param name="maxAgentPlanMemorySize" value="5" /> <!-- 0 means unlimited -->
115115

116116
<parameterset type="strategysettings">

‎ees/scenarios/mount-alexander-shire/bradford-newstead-fire-crossing-400/matsim_config.xml

+6-6
Original file line numberDiff line numberDiff line change
@@ -41,16 +41,16 @@
4141
<param name="inputPlansFile" value="matsim_plans.xml" />
4242
</module>
4343

44-
<module name="controler">
44+
<module name="controller">
4545
<param name="outputDirectory" value="output" />
4646
<param name="firstIteration" value="0" />
4747
<param name="lastIteration" value="0" />
4848
<param name="mobsim" value="qsim" />
4949
<param name = "snapshotFormat" value="googleearth"/> <!-- enable KML output; also must enable snapshotperiod -->
5050
</module>
5151

52-
<module name="controler">
53-
<param name= "routingAlgorithmType" value="FastAStarLandmarks" />
52+
<module name="controller">
53+
<param name= "routingAlgorithmType" value="AStarLandmarks" />
5454
</module>
5555

5656
<module name="qsim">
@@ -68,9 +68,9 @@
6868

6969
</module>
7070

71-
<module name="planCalcScore">
71+
<module name="scoring">
7272
<param name="learningRate" value="1.0" />
73-
<param name="BrainExpBeta" value="2.0" />
73+
<param name="brainExpBeta" value="2.0" />
7474

7575
<parameterset type="scoringParameters">
7676
<param name="lateArrival" value="-18" />
@@ -105,7 +105,7 @@
105105
</parameterset>
106106
</module>
107107

108-
<module name="strategy">
108+
<module name="replanning">
109109
<param name="maxAgentPlanMemorySize" value="5" /> <!-- 0 means unlimited -->
110110

111111
<parameterset type="strategysettings">

‎ees/scenarios/mount-alexander-shire/campbells-creek-1/matsim_config.xml

+6-6
Original file line numberDiff line numberDiff line change
@@ -39,16 +39,16 @@
3939
<param name="inputPlansFile" value="matsim_plans.xml" />
4040
</module>
4141

42-
<module name="controler">
42+
<module name="controller">
4343
<param name="outputDirectory" value="output" />
4444
<param name="firstIteration" value="0" />
4545
<param name="lastIteration" value="0" />
4646
<param name="mobsim" value="qsim" />
4747
<param name = "snapshotFormat" value="googleearth"/> <!-- enable KML output; also must enable snapshotperiod -->
4848
</module>
4949

50-
<module name="controler">
51-
<param name= "routingAlgorithmType" value="FastAStarLandmarks" />
50+
<module name="controller">
51+
<param name= "routingAlgorithmType" value="AStarLandmarks" />
5252
</module>
5353

5454
<module name="qsim">
@@ -63,9 +63,9 @@
6363

6464
</module>
6565

66-
<module name="planCalcScore">
66+
<module name="scoring">
6767
<param name="learningRate" value="1.0" />
68-
<param name="BrainExpBeta" value="2.0" />
68+
<param name="brainExpBeta" value="2.0" />
6969

7070
<parameterset type="scoringParameters">
7171
<param name="lateArrival" value="-18" />
@@ -100,7 +100,7 @@
100100
</parameterset>
101101
</module>
102102

103-
<module name="strategy">
103+
<module name="replanning">
104104
<param name="maxAgentPlanMemorySize" value="5" /> <!-- 0 means unlimited -->
105105

106106
<parameterset type="strategysettings">

‎ees/scenarios/mount-alexander-shire/castlemaine-1000/scenario_matsim_main_reduced.xml

+6-6
Original file line numberDiff line numberDiff line change
@@ -39,16 +39,16 @@
3939
<param name="inputPlansFile" value="scenario_matsim_plans_reduced.xml" />
4040
</module>
4141

42-
<module name="controler">
42+
<module name="controller">
4343
<param name="outputDirectory" value="scenario_matsim_output" />
4444
<param name="firstIteration" value="0" />
4545
<param name="lastIteration" value="0" />
4646
<param name="mobsim" value="qsim" />
4747
<param name = "snapshotFormat" value="googleearth"/> <!-- enable KML output; also must enable snapshotperiod -->
4848
</module>
4949

50-
<module name="controler">
51-
<param name= "routingAlgorithmType" value="FastAStarLandmarks" />
50+
<module name="controller">
51+
<param name= "routingAlgorithmType" value="AStarLandmarks" />
5252
</module>
5353

5454
<module name="qsim">
@@ -63,9 +63,9 @@
6363

6464
</module>
6565

66-
<module name="planCalcScore">
66+
<module name="scoring">
6767
<param name="learningRate" value="1.0" />
68-
<param name="BrainExpBeta" value="2.0" />
68+
<param name="brainExpBeta" value="2.0" />
6969

7070
<parameterset type="scoringParameters">
7171
<param name="lateArrival" value="-18" />
@@ -100,7 +100,7 @@
100100
</parameterset>
101101
</module>
102102

103-
<module name="strategy">
103+
<module name="replanning">
104104
<param name="maxAgentPlanMemorySize" value="5" /> <!-- 0 means unlimited -->
105105

106106
<parameterset type="strategysettings">

‎ees/scenarios/mount-alexander-shire/maldon-100-with-emergency-vehicles/scenario_matsim_main.xml

+6-6
Original file line numberDiff line numberDiff line change
@@ -39,16 +39,16 @@
3939
<param name="inputPlansFile" value="scenario_matsim_plans_10.xml" />
4040
</module>
4141

42-
<module name="controler">
42+
<module name="controller">
4343
<param name="outputDirectory" value="output" />
4444
<param name="firstIteration" value="0" />
4545
<param name="lastIteration" value="0" />
4646
<param name="mobsim" value="qsim" />
4747
<param name = "snapshotFormat" value="googleearth"/> <!-- enable KML output; also must enable snapshotperiod -->
4848
</module>
4949

50-
<module name="controler">
51-
<param name= "routingAlgorithmType" value="FastAStarLandmarks" />
50+
<module name="controller">
51+
<param name= "routingAlgorithmType" value="AStarLandmarks" />
5252
</module>
5353

5454
<module name="qsim">
@@ -63,9 +63,9 @@
6363

6464
</module>
6565

66-
<module name="planCalcScore">
66+
<module name="scoring">
6767
<param name="learningRate" value="1.0" />
68-
<param name="BrainExpBeta" value="2.0" />
68+
<param name="brainExpBeta" value="2.0" />
6969

7070
<parameterset type="scoringParameters">
7171
<param name="lateArrival" value="-18" />
@@ -101,7 +101,7 @@
101101
</module>
102102

103103

104-
<module name="strategy">
104+
<module name="replanning">
105105
<param name="maxAgentPlanMemorySize" value="5" /> <!-- 0 means unlimited -->
106106

107107
<parameterset type="strategysettings">

‎ees/src/main/java/io/github/agentsoz/ees/matsim/DisruptionWriter.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ class DisruptionWriter {
5050
}
5151
void write(double time, Id<Link> linkId, Coord coord, double speed ) {
5252
if (writer == null) {
53-
final String filename = config.controler().getOutputDirectory() + "/output_disruptionCoords.txt.gz";
53+
final String filename = config.controller().getOutputDirectory() + "/output_disruptionCoords.txt.gz";
5454
log.warn("writing disruption data to " + filename);
5555
try {
5656
writer = IOUtils.getPrintStream(new File(filename).toURI().toURL());

‎ees/src/main/java/io/github/agentsoz/ees/matsim/EvacAgent.java

+1-2
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,7 @@
7070
import org.matsim.withinday.utils.EditTrips;
7171
import org.slf4j.Logger;
7272
import org.slf4j.LoggerFactory;
73-
74-
import javax.inject.Inject;
73+
import com.google.inject.Inject;
7574

7675
class EvacAgent implements MobsimDriverAgent, HasPerson, PlanAgent, HasModifiablePlan {
7776

0 commit comments

Comments
 (0)
Please sign in to comment.