From ff1bb1f7ff2ba2b9982e13a604e2ef0b17dc89ca Mon Sep 17 00:00:00 2001 From: rakow Date: Tue, 13 Feb 2024 20:35:32 +0100 Subject: [PATCH] update matsim dependency and run script --- pom.xml | 7 +- .../dashboard/BerlinDashboardProvider.java | 4 +- .../matsim/prepare/ExtractFacilityShp.java | 4 +- .../matsim/prepare/FilterRelevantAgents.java | 6 +- .../prepare/RunOpenBerlinCalibration.java | 6 +- .../CreateCountsFromGeoPortalBerlin.java | 4 +- .../population/CreateBerlinPopulation.java | 4 +- .../CreateBrandenburgPopulation.java | 6 +- .../prepare/population/FacilityIndex.java | 4 +- .../org/matsim/run/OpenBerlinScenario.java | 140 ++++++++++++++++++ .../org/matsim/run/RunOpenBerlinScenario.java | 137 +---------------- .../matsim/run/RunOpenBerlinScenarioGUI.java | 38 ----- .../matsim/run/RunOpenBerlinScenarioTest.java | 2 +- 13 files changed, 172 insertions(+), 190 deletions(-) create mode 100644 src/main/java/org/matsim/run/OpenBerlinScenario.java delete mode 100644 src/main/java/org/matsim/run/RunOpenBerlinScenarioGUI.java diff --git a/pom.xml b/pom.xml index 937df8af..00cb1124 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ matsim-all - 16.0-PR3085 + 16.0-PR3108 @@ -149,6 +149,11 @@ roadpricing ${matsim.version} + + org.matsim.contrib + small-scale-traffic-generation + ${matsim.version} + com.github.matsim-vsp diff --git a/src/main/java/org/matsim/dashboard/BerlinDashboardProvider.java b/src/main/java/org/matsim/dashboard/BerlinDashboardProvider.java index e9d32a3a..b3c230aa 100644 --- a/src/main/java/org/matsim/dashboard/BerlinDashboardProvider.java +++ b/src/main/java/org/matsim/dashboard/BerlinDashboardProvider.java @@ -3,7 +3,7 @@ import org.matsim.api.core.v01.TransportMode; import org.matsim.application.ApplicationUtils; import org.matsim.core.config.Config; -import org.matsim.run.RunOpenBerlinScenario; +import org.matsim.run.OpenBerlinScenario; import org.matsim.simwrapper.Dashboard; import org.matsim.simwrapper.DashboardProvider; import org.matsim.simwrapper.SimWrapper; @@ -26,7 +26,7 @@ public List getDashboards(Config config, SimWrapper simWrapper) { return List.of( trips, - new TravelTimeComparisonDashboard(ApplicationUtils.resolve(config.getContext(), "berlin-v" + RunOpenBerlinScenario.VERSION + "-routes-ref.csv.gz")), + new TravelTimeComparisonDashboard(ApplicationUtils.resolve(config.getContext(), "berlin-v" + OpenBerlinScenario.VERSION + "-routes-ref.csv.gz")), new TrafficCountsDashboard() .withModes(TransportMode.car, Set.of(TransportMode.car)) .withModes(TransportMode.truck, Set.of(TransportMode.truck, "freight")) diff --git a/src/main/java/org/matsim/prepare/ExtractFacilityShp.java b/src/main/java/org/matsim/prepare/ExtractFacilityShp.java index 81eef8ef..de9e6b15 100644 --- a/src/main/java/org/matsim/prepare/ExtractFacilityShp.java +++ b/src/main/java/org/matsim/prepare/ExtractFacilityShp.java @@ -29,7 +29,7 @@ import org.locationtech.jts.index.strtree.STRtree; import org.matsim.application.MATSimAppCommand; import org.matsim.application.options.CrsOptions; -import org.matsim.run.RunOpenBerlinScenario; +import org.matsim.run.OpenBerlinScenario; import org.opengis.feature.simple.SimpleFeature; import org.opengis.feature.simple.SimpleFeatureType; import org.opengis.referencing.crs.CRSAuthorityFactory; @@ -68,7 +68,7 @@ public class ExtractFacilityShp implements MATSimAppCommand { @CommandLine.Option(names = "--activity-mapping", description = "Path to activity napping json", required = true) private Path mappingPath; @CommandLine.Mixin - private CrsOptions crs = new CrsOptions("EPSG:4326", RunOpenBerlinScenario.CRS); + private CrsOptions crs = new CrsOptions("EPSG:4326", OpenBerlinScenario.CRS); /** * Maps types to feature index. */ diff --git a/src/main/java/org/matsim/prepare/FilterRelevantAgents.java b/src/main/java/org/matsim/prepare/FilterRelevantAgents.java index 60b4d6bc..16aea35e 100644 --- a/src/main/java/org/matsim/prepare/FilterRelevantAgents.java +++ b/src/main/java/org/matsim/prepare/FilterRelevantAgents.java @@ -31,7 +31,7 @@ import org.matsim.facilities.ActivityFacilities; import org.matsim.facilities.FacilitiesUtils; import org.matsim.facilities.MatsimFacilitiesReader; -import org.matsim.run.RunOpenBerlinScenario; +import org.matsim.run.OpenBerlinScenario; import picocli.CommandLine; import java.nio.file.Path; @@ -89,10 +89,10 @@ public Integer call() throws Exception { filter.filter(network, Set.of(TransportMode.car)); geometry = shp.getGeometry(); - ct = shp.createTransformation(RunOpenBerlinScenario.CRS); + ct = shp.createTransformation(OpenBerlinScenario.CRS); facilities = FacilitiesUtils.createActivityFacilities(); - new MatsimFacilitiesReader(RunOpenBerlinScenario.CRS, RunOpenBerlinScenario.CRS, facilities) + new MatsimFacilitiesReader(OpenBerlinScenario.CRS, OpenBerlinScenario.CRS, facilities) .readFile(facilityPath.toString()); ctxs = ThreadLocal.withInitial(() -> this.createRouter(network)); diff --git a/src/main/java/org/matsim/prepare/RunOpenBerlinCalibration.java b/src/main/java/org/matsim/prepare/RunOpenBerlinCalibration.java index a45c6d64..e3a06c27 100644 --- a/src/main/java/org/matsim/prepare/RunOpenBerlinCalibration.java +++ b/src/main/java/org/matsim/prepare/RunOpenBerlinCalibration.java @@ -54,7 +54,7 @@ import org.matsim.prepare.opt.SelectPlansFromIndex; import org.matsim.prepare.population.*; import org.matsim.run.Activities; -import org.matsim.run.RunOpenBerlinScenario; +import org.matsim.run.OpenBerlinScenario; import org.matsim.run.scoring.VspScoringModule; import org.matsim.simwrapper.SimWrapperConfigGroup; import org.matsim.simwrapper.SimWrapperModule; @@ -72,7 +72,7 @@ /** * This scenario class is used for run a MATSim scenario in various stages of the calibration process. */ -@CommandLine.Command(header = ":: Open Berlin Calibration ::", version = RunOpenBerlinScenario.VERSION, mixinStandardHelpOptions = true) +@CommandLine.Command(header = ":: Open Berlin Calibration ::", version = OpenBerlinScenario.VERSION, mixinStandardHelpOptions = true) @MATSimApplication.Prepare({ CreateLandUseShp.class, CreateBerlinPopulation.class, CreateBrandenburgPopulation.class, MergePopulations.class, LookupRegioStaR.class, ExtractFacilityShp.class, DownSamplePopulation.class, DownloadCommuterStatistic.class, @@ -398,7 +398,7 @@ public void install() { } }); - controler.addOverridingModule(new RunOpenBerlinScenario.TravelTimeBinding()); + controler.addOverridingModule(new OpenBerlinScenario.TravelTimeBinding()); controler.addOverridingModule(new VspScoringModule()); controler.addOverridingModule(new SimWrapperModule()); } diff --git a/src/main/java/org/matsim/prepare/counts/CreateCountsFromGeoPortalBerlin.java b/src/main/java/org/matsim/prepare/counts/CreateCountsFromGeoPortalBerlin.java index 45275014..84fba525 100644 --- a/src/main/java/org/matsim/prepare/counts/CreateCountsFromGeoPortalBerlin.java +++ b/src/main/java/org/matsim/prepare/counts/CreateCountsFromGeoPortalBerlin.java @@ -25,7 +25,7 @@ import org.matsim.core.network.NetworkUtils; import org.matsim.core.network.filter.NetworkFilterManager; import org.matsim.core.utils.geometry.geotools.MGC; -import org.matsim.run.RunOpenBerlinScenario; +import org.matsim.run.OpenBerlinScenario; import org.opengis.feature.simple.SimpleFeature; import org.opengis.referencing.FactoryException; import org.opengis.referencing.operation.MathTransform; @@ -117,7 +117,7 @@ public Integer call() throws Exception { // Compare two line strings index.setDistanceCalculator(NetworkIndex::minHausdorffDistance); - MathTransform transformation = getCoordinateTransformation(shp.getShapeCrs(), RunOpenBerlinScenario.CRS); + MathTransform transformation = getCoordinateTransformation(shp.getShapeCrs(), OpenBerlinScenario.CRS); log.info("Processing features."); int counter = 0; diff --git a/src/main/java/org/matsim/prepare/population/CreateBerlinPopulation.java b/src/main/java/org/matsim/prepare/population/CreateBerlinPopulation.java index 3e98ff06..31f01f2a 100644 --- a/src/main/java/org/matsim/prepare/population/CreateBerlinPopulation.java +++ b/src/main/java/org/matsim/prepare/population/CreateBerlinPopulation.java @@ -24,7 +24,7 @@ import org.matsim.core.utils.geometry.geotools.MGC; import org.matsim.core.utils.geometry.transformations.GeotoolsTransformation; import org.matsim.prepare.RunOpenBerlinCalibration; -import org.matsim.run.RunOpenBerlinScenario; +import org.matsim.run.OpenBerlinScenario; import org.opengis.feature.simple.SimpleFeature; import picocli.CommandLine; @@ -155,7 +155,7 @@ public Integer call() throws Exception { PopulationUtils.sortPersons(population); - ProjectionUtils.putCRS(population, RunOpenBerlinScenario.CRS); + ProjectionUtils.putCRS(population, OpenBerlinScenario.CRS); PopulationUtils.writePopulation(population, output.toString()); return 0; diff --git a/src/main/java/org/matsim/prepare/population/CreateBrandenburgPopulation.java b/src/main/java/org/matsim/prepare/population/CreateBrandenburgPopulation.java index 28c28114..73fd3b54 100644 --- a/src/main/java/org/matsim/prepare/population/CreateBrandenburgPopulation.java +++ b/src/main/java/org/matsim/prepare/population/CreateBrandenburgPopulation.java @@ -21,7 +21,7 @@ import org.matsim.core.population.PersonUtils; import org.matsim.core.population.PopulationUtils; import org.matsim.core.scenario.ProjectionUtils; -import org.matsim.run.RunOpenBerlinScenario; +import org.matsim.run.OpenBerlinScenario; import org.opengis.feature.simple.SimpleFeature; import picocli.CommandLine; @@ -124,7 +124,7 @@ public Integer call() throws Exception { PopulationUtils.sortPersons(population); - ProjectionUtils.putCRS(population, RunOpenBerlinScenario.CRS); + ProjectionUtils.putCRS(population, OpenBerlinScenario.CRS); PopulationUtils.writePopulation(population, output.toString()); return 0; @@ -170,7 +170,7 @@ private void addPersons(CSVRecord r, String code, String ars, MultiPolygon geom) // All persons will be employed until employed population is empty. PersonUtils.setEmployed(person, employed.subtract(1 / sample, age)); - Coord coord = CreateBerlinPopulation.sampleHomeCoordinate(geom, RunOpenBerlinScenario.CRS, landuse, rnd); + Coord coord = CreateBerlinPopulation.sampleHomeCoordinate(geom, OpenBerlinScenario.CRS, landuse, rnd); person.getAttributes().putAttribute(Attributes.HOME_X, coord.getX()); person.getAttributes().putAttribute(Attributes.HOME_Y, coord.getY()); diff --git a/src/main/java/org/matsim/prepare/population/FacilityIndex.java b/src/main/java/org/matsim/prepare/population/FacilityIndex.java index f24908b1..1f239fbf 100644 --- a/src/main/java/org/matsim/prepare/population/FacilityIndex.java +++ b/src/main/java/org/matsim/prepare/population/FacilityIndex.java @@ -9,7 +9,7 @@ import org.matsim.facilities.ActivityFacility; import org.matsim.facilities.FacilitiesUtils; import org.matsim.facilities.MatsimFacilitiesReader; -import org.matsim.run.RunOpenBerlinScenario; +import org.matsim.run.OpenBerlinScenario; import java.util.HashMap; import java.util.Map; @@ -33,7 +33,7 @@ final class FacilityIndex { FacilityIndex(String facilityPath) { - new MatsimFacilitiesReader(RunOpenBerlinScenario.CRS, RunOpenBerlinScenario.CRS, all) + new MatsimFacilitiesReader(OpenBerlinScenario.CRS, OpenBerlinScenario.CRS, all) .readFile(facilityPath); Set activities = all.getFacilities().values().stream() diff --git a/src/main/java/org/matsim/run/OpenBerlinScenario.java b/src/main/java/org/matsim/run/OpenBerlinScenario.java new file mode 100644 index 00000000..fb7d7e96 --- /dev/null +++ b/src/main/java/org/matsim/run/OpenBerlinScenario.java @@ -0,0 +1,140 @@ +package org.matsim.run; + +import com.google.inject.Key; +import com.google.inject.name.Names; +import org.apache.logging.log4j.LogManager; +import org.apache.logging.log4j.Logger; +import org.matsim.api.core.v01.Scenario; +import org.matsim.api.core.v01.TransportMode; +import org.matsim.application.MATSimApplication; +import org.matsim.application.options.SampleOptions; +import org.matsim.core.config.Config; +import org.matsim.core.config.ConfigUtils; +import org.matsim.core.config.groups.ReplanningConfigGroup; +import org.matsim.core.controler.AbstractModule; +import org.matsim.core.controler.Controler; +import org.matsim.core.replanning.strategies.DefaultPlanStrategiesModule; +import org.matsim.core.router.costcalculators.TravelDisutilityFactory; +import org.matsim.core.router.util.TravelTime; +import org.matsim.core.scoring.functions.ScoringParametersForPerson; +import org.matsim.prepare.RunOpenBerlinCalibration; +import org.matsim.prepare.population.AssignIncome; +import org.matsim.simwrapper.SimWrapperConfigGroup; +import org.matsim.simwrapper.SimWrapperModule; +import picocli.CommandLine; +import playground.vsp.scoring.IncomeDependentUtilityOfMoneyPersonScoringParameters; +import java.util.List; +import org.matsim.run.scoring.VspScoringModule; + +@CommandLine.Command(header = ":: Open Berlin Scenario ::", version = OpenBerlinScenario.VERSION, mixinStandardHelpOptions = true) +public class OpenBerlinScenario extends MATSimApplication { + + private static final Logger log = LogManager.getLogger(RunOpenBerlinCalibration.class); + + public static final String VERSION = "6.1"; + public static final String CRS = "EPSG:25832"; + @CommandLine.Mixin + private final SampleOptions sample = new SampleOptions(10, 25, 3, 1); + + public OpenBerlinScenario() { + super(String.format("input/v%s/berlin-v%s.config.xml", VERSION, VERSION)); + } + + public static void main(String[] args) { + MATSimApplication.run(OpenBerlinScenario.class, args); + } + + @Override + protected Config prepareConfig(Config config) { + + SimWrapperConfigGroup sw = ConfigUtils.addOrGetModule(config, SimWrapperConfigGroup.class); + + if (sample.isSet()) { + double sampleSize = sample.getSample(); + + config.qsim().setFlowCapFactor(sampleSize); + config.qsim().setStorageCapFactor(sampleSize); + + // Counts can be scaled with sample size + config.counts().setCountsScaleFactor(sampleSize); + sw.sampleSize = sampleSize; + + config.controller().setRunId(sample.adjustName(config.controller().getRunId())); + config.controller().setOutputDirectory(sample.adjustName(config.controller().getOutputDirectory())); + config.plans().setInputFile(sample.adjustName(config.plans().getInputFile())); + } + + Activities.addScoringParams(config, true); + + // Required for all calibration strategies + for (String subpopulation : List.of("person", "freight", "goodsTraffic", "commercialPersonTraffic", "commercialPersonTraffic_service")) { + config.replanning().addStrategySettings( + new ReplanningConfigGroup.StrategySettings() + .setStrategyName(DefaultPlanStrategiesModule.DefaultSelector.ChangeExpBeta) + .setWeight(1.0) + .setSubpopulation(subpopulation) + ); + + config.replanning().addStrategySettings( + new ReplanningConfigGroup.StrategySettings() + .setStrategyName(DefaultPlanStrategiesModule.DefaultStrategy.ReRoute) + .setWeight(0.15) + .setSubpopulation(subpopulation) + ); + } + + config.replanning().addStrategySettings( + new ReplanningConfigGroup.StrategySettings() + .setStrategyName(DefaultPlanStrategiesModule.DefaultStrategy.TimeAllocationMutator) + .setWeight(0.15) + .setSubpopulation("person") + ); + + config.replanning().addStrategySettings( + new ReplanningConfigGroup.StrategySettings() + .setStrategyName(DefaultPlanStrategiesModule.DefaultStrategy.SubtourModeChoice) + .setWeight(0.15) + .setSubpopulation("person") + ); + + return config; + } + + @Override + protected void prepareScenario(Scenario scenario) { + + AssignIncome income = new AssignIncome(); + + // Calculate the income for each person, in next versions this might also be done during creation of the population + scenario.getPopulation().getPersons().values().forEach(income::run); + + } + + @Override + protected void prepareControler(Controler controler) { + + controler.addOverridingModule(new SimWrapperModule()); + + controler.addOverridingModule(new TravelTimeBinding()); + + controler.addOverridingModule(new VspScoringModule()); + + } + + /** + * Add travel time bindings for ride and freight modes, which are not actually network modes. + */ + public static final class TravelTimeBinding extends AbstractModule { + @Override + public void install() { + addTravelTimeBinding(TransportMode.ride).to(networkTravelTime()); + addTravelDisutilityFactoryBinding(TransportMode.ride).to(carTravelDisutilityFactoryKey()); + + addTravelTimeBinding("freight").to(Key.get(TravelTime.class, Names.named(TransportMode.truck))); + addTravelDisutilityFactoryBinding("freight").to(Key.get(TravelDisutilityFactory.class, Names.named(TransportMode.truck))); + + bind(ScoringParametersForPerson.class).to(IncomeDependentUtilityOfMoneyPersonScoringParameters.class).asEagerSingleton(); + } + } + +} diff --git a/src/main/java/org/matsim/run/RunOpenBerlinScenario.java b/src/main/java/org/matsim/run/RunOpenBerlinScenario.java index f28cb144..5b829d16 100644 --- a/src/main/java/org/matsim/run/RunOpenBerlinScenario.java +++ b/src/main/java/org/matsim/run/RunOpenBerlinScenario.java @@ -1,140 +1,15 @@ package org.matsim.run; -import com.google.inject.Key; -import com.google.inject.name.Names; -import org.apache.logging.log4j.LogManager; -import org.apache.logging.log4j.Logger; -import org.matsim.api.core.v01.Scenario; -import org.matsim.api.core.v01.TransportMode; -import org.matsim.application.MATSimApplication; -import org.matsim.application.options.SampleOptions; -import org.matsim.core.config.Config; -import org.matsim.core.config.ConfigUtils; -import org.matsim.core.config.groups.ReplanningConfigGroup; -import org.matsim.core.controler.AbstractModule; -import org.matsim.core.controler.Controler; -import org.matsim.core.replanning.strategies.DefaultPlanStrategiesModule; -import org.matsim.core.router.costcalculators.TravelDisutilityFactory; -import org.matsim.core.router.util.TravelTime; -import org.matsim.core.scoring.functions.ScoringParametersForPerson; -import org.matsim.prepare.RunOpenBerlinCalibration; -import org.matsim.prepare.population.AssignIncome; -import org.matsim.simwrapper.SimWrapperConfigGroup; -import org.matsim.simwrapper.SimWrapperModule; -import picocli.CommandLine; -import playground.vsp.scoring.IncomeDependentUtilityOfMoneyPersonScoringParameters; -import java.util.List; -import org.matsim.run.scoring.VspScoringModule; - -@CommandLine.Command(header = ":: Open Berlin Scenario ::", version = RunOpenBerlinScenario.VERSION, mixinStandardHelpOptions = true) -public class RunOpenBerlinScenario extends MATSimApplication { - - private static final Logger log = LogManager.getLogger(RunOpenBerlinCalibration.class); - public static final String VERSION = "6.1"; - public static final String CRS = "EPSG:25832"; - @CommandLine.Mixin - private final SampleOptions sample = new SampleOptions(10, 25, 3, 1); +import org.matsim.application.MATSimApplication; - public RunOpenBerlinScenario() { - super(String.format("input/v%s/berlin-v%s.config.xml", VERSION, VERSION)); - } +/** + * Run the {@link OpenBerlinScenario} with default configuration. + */ +public class RunOpenBerlinScenario { public static void main(String[] args) { - MATSimApplication.run(RunOpenBerlinScenario.class, args); - } - - @Override - protected Config prepareConfig(Config config) { - - SimWrapperConfigGroup sw = ConfigUtils.addOrGetModule(config, SimWrapperConfigGroup.class); - - if (sample.isSet()) { - double sampleSize = sample.getSample(); - - config.qsim().setFlowCapFactor(sampleSize); - config.qsim().setStorageCapFactor(sampleSize); - - // Counts can be scaled with sample size - config.counts().setCountsScaleFactor(sampleSize); - sw.sampleSize = sampleSize; - - config.controller().setRunId(sample.adjustName(config.controller().getRunId())); - config.controller().setOutputDirectory(sample.adjustName(config.controller().getOutputDirectory())); - config.plans().setInputFile(sample.adjustName(config.plans().getInputFile())); - } - - Activities.addScoringParams(config, true); - - // Required for all calibration strategies - for (String subpopulation : List.of("person", "freight", "goodsTraffic", "commercialPersonTraffic", "commercialPersonTraffic_service")) { - config.replanning().addStrategySettings( - new ReplanningConfigGroup.StrategySettings() - .setStrategyName(DefaultPlanStrategiesModule.DefaultSelector.ChangeExpBeta) - .setWeight(1.0) - .setSubpopulation(subpopulation) - ); - - config.replanning().addStrategySettings( - new ReplanningConfigGroup.StrategySettings() - .setStrategyName(DefaultPlanStrategiesModule.DefaultStrategy.ReRoute) - .setWeight(0.15) - .setSubpopulation(subpopulation) - ); - } - - config.replanning().addStrategySettings( - new ReplanningConfigGroup.StrategySettings() - .setStrategyName(DefaultPlanStrategiesModule.DefaultStrategy.TimeAllocationMutator) - .setWeight(0.15) - .setSubpopulation("person") - ); - - config.replanning().addStrategySettings( - new ReplanningConfigGroup.StrategySettings() - .setStrategyName(DefaultPlanStrategiesModule.DefaultStrategy.SubtourModeChoice) - .setWeight(0.15) - .setSubpopulation("person") - ); - - return config; - } - - @Override - protected void prepareScenario(Scenario scenario) { - - AssignIncome income = new AssignIncome(); - - // Calculate the income for each person, in next versions this might also be done during creation of the population - scenario.getPopulation().getPersons().values().forEach(income::run); - - } - - @Override - protected void prepareControler(Controler controler) { - - controler.addOverridingModule(new SimWrapperModule()); - - controler.addOverridingModule(new TravelTimeBinding()); - - controler.addOverridingModule(new VspScoringModule()); - - } - - /** - * Add travel time bindings for ride and freight modes, which are not actually network modes. - */ - public static final class TravelTimeBinding extends AbstractModule { - @Override - public void install() { - addTravelTimeBinding(TransportMode.ride).to(networkTravelTime()); - addTravelDisutilityFactoryBinding(TransportMode.ride).to(carTravelDisutilityFactoryKey()); - - addTravelTimeBinding("freight").to(Key.get(TravelTime.class, Names.named(TransportMode.truck))); - addTravelDisutilityFactoryBinding("freight").to(Key.get(TravelDisutilityFactory.class, Names.named(TransportMode.truck))); - - bind(ScoringParametersForPerson.class).to(IncomeDependentUtilityOfMoneyPersonScoringParameters.class).asEagerSingleton(); - } + MATSimApplication.runWithDefaults(OpenBerlinScenario.class, args); } } diff --git a/src/main/java/org/matsim/run/RunOpenBerlinScenarioGUI.java b/src/main/java/org/matsim/run/RunOpenBerlinScenarioGUI.java deleted file mode 100644 index 6c17bc92..00000000 --- a/src/main/java/org/matsim/run/RunOpenBerlinScenarioGUI.java +++ /dev/null @@ -1,38 +0,0 @@ -/* *********************************************************************** * - * project: org.matsim.* - * * - * *********************************************************************** * - * * - * copyright : (C) 2008 by the members listed in the COPYING, * - * LICENSE and WARRANTY file. * - * email : info at matsim dot org * - * * - * *********************************************************************** * - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * See also COPYING, LICENSE and WARRANTY file * - * * - * *********************************************************************** */ - -package org.matsim.run; - -import org.matsim.run.gui.Gui; - -/** - * Runs the MATSim GUI for the OpenBerlin scenario. - */ -public final class RunOpenBerlinScenarioGUI { - - private RunOpenBerlinScenarioGUI() { - } - - public static void main(String[] args) { - Gui.show("MATSim GUI for matsim-berlin", RunOpenBerlinScenario.class); - } - - // The jar file is generated by "mvn package". Note that the pom.xml refers at some point to this class here. - -} diff --git a/src/test/java/org/matsim/run/RunOpenBerlinScenarioTest.java b/src/test/java/org/matsim/run/RunOpenBerlinScenarioTest.java index e400d31e..43dadede 100644 --- a/src/test/java/org/matsim/run/RunOpenBerlinScenarioTest.java +++ b/src/test/java/org/matsim/run/RunOpenBerlinScenarioTest.java @@ -16,7 +16,7 @@ public class RunOpenBerlinScenarioTest { @Test public void pct1() { - int code = MATSimApplication.execute(RunOpenBerlinScenario.class, + int code = MATSimApplication.execute(OpenBerlinScenario.class, "--1pct", "--output", utils.getOutputDirectory(), "--iterations", "2",