Skip to content

Commit

Permalink
add plan variants to small scale commercial traffic
Browse files Browse the repository at this point in the history
  • Loading branch information
rewertvsp committed May 16, 2024
1 parent 35b9911 commit 58515aa
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/main/java/org/matsim/prepare/CreateCommercialDemand.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
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.population.Leg;
import org.matsim.api.core.v01.population.Person;
import org.matsim.api.core.v01.population.Population;
import org.matsim.application.MATSimAppCommand;
Expand Down Expand Up @@ -215,6 +216,7 @@ public Integer call() {
"--pathOutput", outputPathSmallScaleCommercial,
"--network", networkPath,
"--nameOutputPopulation", smallScaleCommercialPopulationName,
"--numberOfPlanVariantsPerAgent", "5",
"--includeExistingModels");

// TODO filter relevant agents for the small scale commercial traffic
Expand Down Expand Up @@ -266,6 +268,7 @@ public Integer call() {
Set<String> allNetworkModes = new HashSet<>(config.routing().getNetworkModes());
allNetworkModes.addAll(newModes);
config.routing().setNetworkModes(allNetworkModes);
//TODO add replanning strategy for small scale commercial traffic
newModes.forEach(mode -> {
ScoringConfigGroup.ModeParams thisModeParams = new ScoringConfigGroup.ModeParams(mode);
config.scoring().addModeParams(thisModeParams);
Expand Down

0 comments on commit 58515aa

Please sign in to comment.