Skip to content

Commit

Permalink
Merge branch 'refs/heads/6.x' into 6.x-next
Browse files Browse the repository at this point in the history
# Conflicts:
#	pom.xml
  • Loading branch information
rakow committed Jul 1, 2024
2 parents 2384b61 + 9287fc3 commit 2a25f9f
Show file tree
Hide file tree
Showing 10 changed files with 47 additions and 58 deletions.
6 changes: 0 additions & 6 deletions .gitlab-ci.yml

This file was deleted.

23 changes: 0 additions & 23 deletions .travis.yml

This file was deleted.

19 changes: 13 additions & 6 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,24 @@ All notable changes to this project will be documented in this file.

### 6.2 (2024-06)
- Updated network and gtfs schedule
- Network is now based on late 2022 osm data
- PT schedule is based in mid 2023, earlier data of this feed was not available
- The network conversion now uses a SUMO converter, a microscopic representation of the network will be available as well
- Free speed of the network has been calibrated as described in the paper "Road network free flow speed estimation using microscopic simulation and point-to-point travel times"
- Network is now based on late 2022 osm data
- PT schedule is based in mid 2023, earlier data of this feed was not available
- The network conversion now uses a SUMO converter, a microscopic representation of the network will be available as well
- Free speed of the network has been calibrated as described in the paper "Road network free flow speed estimation using microscopic simulation and point-to-point travel times"
- Walking speed increased to match reference data
- Recalibration of mode constants (ASCs)
- Updated commercial traffic, especially the trip duration should be more realistic
- Added a run class for DRT scenarios
- Please note that the 6.3 version is released nearly at the same time
- Because of that 6.2 was not calibrated to the same accuracy
- Rather use the newest version, which also includes all features of 6.2
- Because of that 6.2 was not calibrated to the same accuracy
- Rather use the newest version, which also includes all features of 6.2

### 6.1.1 (2024-06-11)

- Fix ASCs in tbe 6.1 config
- The calibrated ASCs have not been correctly copied to the 6.1 config, this is now fixed.
- All input files remain the same
- The existing output remains the same as well, because this run was using the correct ASC values

### 6.1 (2024-04-17)

Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ This repository provides an open MATSim transport model for Berlin, provided by

Currently, there are multiple versions of the MATSim Open Berlin model:

### 10pct scenario (`input/v6.1`)
### 10pct scenario (`input/v6.2`)

This scenario contains both 10pct and 1pct sample of the Greater Berlin population; road capacities are accordingly reduced. The scenario is calibrated taking into consideration the traffic counts, modal split and mode-specific trip distance distributions.

Expand All @@ -38,14 +38,14 @@ Handling of large files within git is not without problems (git lfs files are no

1. Open SimWrapper at https://simwrapper.github.io/site/ .
1. Select Explore Data Sources -> VSP Public-SVN .
1. Navigate to de -> berlin -> berlin-v6.1 (https://simwrapper.github.io/site/public/de/berlin/berlin-v6.1).
1. Navigate to de -> berlin -> berlin-v6.2 (https://simwrapper.github.io/site/public/de/berlin/berlin-v6.2).
1. Enjoy the dashboards and visualizations.

### Run VIA on output files

1. Get VIA from https://www.simunto.com/via/. (There is a free license for a small number of agents; that will probably work but only display a small number of vehicles/agents.)
1. Go to https://svn.vsp.tu-berlin.de/repos/public-svn/matsim/scenarios/countries/de/berlin/ .
1. Decide for a scenario that you find interesting (e.g. `berlin-v6.1`) and go into that directory.
1. Decide for a scenario that you find interesting (e.g. `berlin-v6.2`) and go into that directory.
1. Inside there, look for an `output-*` directory that you find interesting and go into that directory.
1. Download `*.output_network.xml.gz` and `*.output_events.xml.gz`. Best make sure that they do not uncompress, e.g. by "Download linked file as ...".
1. Get these files into VIA. This can be achieved in various ways; one is to open VIA and then drag the files from a file browser into VIA.
Expand Down
8 changes: 4 additions & 4 deletions input/v6.1/berlin-v6.1.config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@
<param name="performing" value="6.88"/>

<parameterset type="modeParams">
<param name="constant" value="-0.6269580844054548" />
<param name="constant" value="-0.7904891983040987" />
<!-- result of the calibration, lower than full vehicle ownership cost which gave too unattractive car mode in calibration -->
<param name="dailyMonetaryConstant" value="-3.0" />
<param name="dailyUtilityConstant" value="0" />
Expand All @@ -125,7 +125,7 @@
<param name="mode" value="car" />
</parameterset>
<parameterset type="modeParams">
<param name="constant" value="-1.3788242711735" />
<param name="constant" value="-1.0293490257513975" />
<param name="dailyMonetaryConstant" value="0.0" />
<param name="dailyUtilityConstant" value="0.0" />
<param name="marginalUtilityOfDistance_util_m" value="0.0" />
Expand All @@ -137,7 +137,7 @@
<param name="mode" value="ride" />
</parameterset>
<parameterset type="modeParams">
<param name="constant" value="-0.24909103628514367" />
<param name="constant" value="0.32909137835098523" />
<!-- 2022: 4-trips AB 10Euro -> 2.5 Eu/trip. yearly 761 Eu / 250 days = 3.04 Eu/day -->
<param name="dailyMonetaryConstant" value="-3.0" />
<param name="dailyUtilityConstant" value="0.0" />
Expand All @@ -147,7 +147,7 @@
<param name="mode" value="pt" />
</parameterset>
<parameterset type="modeParams">
<param name="constant" value="-2.2321797854695955" />
<param name="constant" value="-1.7377577082420756" />
<param name="dailyMonetaryConstant" value="0.0" />
<param name="dailyUtilityConstant" value="0.0" />
<param name="marginalUtilityOfDistance_util_m" value="0.0" />
Expand Down
20 changes: 10 additions & 10 deletions input/v6.2/berlin-v6.2.config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,24 +20,24 @@
<param name="numberOfThreads" value="16"/>
</module>
<module name="network">
<param name="inputNetworkFile" value="./berlin-v6.2-network-with-pt.xml.gz"/>
<param name="inputNetworkFile" value="https://svn.vsp.tu-berlin.de/repos/public-svn/matsim/scenarios/countries/de/berlin/berlin-v6.2/input/berlin-v6.2-network-with-pt.xml.gz"/>
</module>
<module name="plans">
<param name="inputPlansFile" value="./berlin-v6.2-25pct.plans-initial.xml.gz"/>
<param name="inputPlansFile" value="https://svn.vsp.tu-berlin.de/repos/public-svn/matsim/scenarios/countries/de/berlin/berlin-v6.2/input/berlin-v6.2-25pct.plans.xml.gz"/>
<param name="removingUnnecessaryPlanAttributes" value="true"/>
</module>
<module name="vehicles">
<param name="vehiclesFile"
value="./berlin-v6.2-vehicleTypes.xml"/>
</module>
<module name="transit">
<param name="transitScheduleFile" value="./berlin-v6.2-transitSchedule.xml.gz"/>
<param name="transitScheduleFile" value="https://svn.vsp.tu-berlin.de/repos/public-svn/matsim/scenarios/countries/de/berlin/berlin-v6.2/input/berlin-v6.2-transitSchedule.xml.gz"/>
<param name="useTransit" value="true"/>
<param name="vehiclesFile" value="./berlin-v6.2-transitVehicles.xml.gz"/>
<param name="vehiclesFile" value="https://svn.vsp.tu-berlin.de/repos/public-svn/matsim/scenarios/countries/de/berlin/berlin-v6.2/input/berlin-v6.2-transitVehicles.xml.gz"/>
</module>
<module name="facilities">
<param name="facilitiesSource" value="fromFile"/>
<param name="inputFacilitiesFile" value="./berlin-v6.2-facilities.xml.gz"/>
<param name="inputFacilitiesFile" value="https://svn.vsp.tu-berlin.de/repos/public-svn/matsim/scenarios/countries/de/berlin/berlin-v6.2/input/berlin-v6.2-facilities.xml.gz"/>
</module>
<module name="routing">
<param name="networkModes" value="car,truck,freight,ride"/>
Expand Down Expand Up @@ -115,7 +115,7 @@
<param name="performing" value="6.88"/>

<parameterset type="modeParams">
<param name="constant" value="-0.6269580844054548" />
<param name="constant" value="-0.5548739474201541" />
<!-- result of the calibration, lower than full vehicle ownership cost which gave too unattractive car mode in calibration -->
<param name="dailyMonetaryConstant" value="-5.0" />
<param name="dailyUtilityConstant" value="0" />
Expand All @@ -126,7 +126,7 @@
<param name="mode" value="car" />
</parameterset>
<parameterset type="modeParams">
<param name="constant" value="-1.3788242711735" />
<param name="constant" value="-1.2671246981315307" />
<param name="dailyMonetaryConstant" value="0.0" />
<param name="dailyUtilityConstant" value="0.0" />
<param name="marginalUtilityOfDistance_util_m" value="0.0" />
Expand All @@ -138,7 +138,7 @@
<param name="mode" value="ride" />
</parameterset>
<parameterset type="modeParams">
<param name="constant" value="-0.24909103628514367" />
<param name="constant" value="0.5457771595119154" />
<!-- 2022: 4-trips AB 10Euro -> 2.5 Eu/trip. yearly 761 Eu / 250 days = 3.04 Eu/day -->
<param name="dailyMonetaryConstant" value="-3.0" />
<param name="dailyUtilityConstant" value="0.0" />
Expand All @@ -148,7 +148,7 @@
<param name="mode" value="pt" />
</parameterset>
<parameterset type="modeParams">
<param name="constant" value="-2.2321797854695955" />
<param name="constant" value="-1.3346462869348628" />
<param name="dailyMonetaryConstant" value="0.0" />
<param name="dailyUtilityConstant" value="0.0" />
<param name="marginalUtilityOfDistance_util_m" value="0.0" />
Expand Down Expand Up @@ -187,7 +187,7 @@
</module>

<module name="counts">
<param name="inputCountsFile" value="./berlin-v6.2-counts-vmz.xml.gz"/>
<param name="inputCountsFile" value="https://svn.vsp.tu-berlin.de/repos/public-svn/matsim/scenarios/countries/de/berlin/berlin-v6.2/input/berlin-v6.2-counts-vmz.xml.gz"/>
<param name="countsScaleFactor" value="0.1"/>
</module>

Expand Down
11 changes: 11 additions & 0 deletions input/v6.2/berlin-v6.2.drt-config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,11 @@
<!-- drt fare per hour (fee = positive value) -->
<param name="timeFare_h" value="0.0"/>
</parameterset>
<parameterset type="zonalSystem">
<parameterset type="SquareGridZoneSystem">
<param name="cellSize" value="1000"/>
</parameterset>
</parameterset>
</parameterset>
</module>

Expand All @@ -66,6 +71,12 @@
<param name="travelTimeEstimationAlpha" value="0.05"/>
<!-- Used for ONLINE estimation of travel times for VrpOptimizer by combining WithinDayTravelTime and DvrpOfflineTravelTimeEstimator. The beta coefficient is provided in seconds and should be either 0 (no online estimation) or positive (mixed online-offline estimation). For 'beta = 0', only the offline estimate is used: 'onlineTT(t) = offlineTT(t)', where 'offlineTT(t)' in the offline estimate for TT at time 't', For 'beta > 0', estimating future TTs at time 't', uses the currently observed TT to correct the offline estimates is made: where 'currentTT' is the currently observed TT, and 'correction = min(1, max(0, 1 - (time - currentTime) / beta))' The rule is that correction decreases linearly from 1 (when 'time = currentTime') to 0 (when 'time = currentTime + beta' For 'time > currentTime + beta' correction is 0, whereas if 'time < currentTime' it is 1. If beta is sufficiently large, 'beta >> 0', only the currently observed TT is used. -->
<param name="travelTimeEstimationBeta" value="0.0"/>
<parameterset type="travelTimeMatrix">
<parameterset type="SquareGridZoneSystem">
<param name="cellSize" value="1000"/>
</parameterset>
<param name="maxNeighborDistance" value="10000"/>
</parameterset>
</module>

<module name="swissRailRaptor" >
Expand Down
6 changes: 3 additions & 3 deletions jitpack.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
jdk:
- openjdk17
- openjdk21
before_install:
- sdk install java 17.0.3-tem
- sdk use java 17.0.3-tem
- sdk install java 21.0.3-tem
- sdk use java 21.0.3-tem
- sdk install maven
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.8.8</version>
<version>0.8.12</version>
<executions>
<execution>
<goals>
Expand Down
4 changes: 2 additions & 2 deletions src/main/python/train_facility_attraction.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
visits = pd.read_csv(args.visitations)
mapping = pd.read_csv(args.mapping)

visits = pd.merge(visits, mapping, left_on="location", right_on="osm_id", how="inner")
visits = pd.merge(visits, mapping, left_on="location", right_on="osm_id", how="inner", validate="m:1")

# Aggregates all parent ids
visits = visits.groupby(["parent_id", "purpose"]).agg(n=("n", "sum")).reset_index().rename(
Expand All @@ -41,7 +41,7 @@

tf = visits[visits.purpose == purpose]

df = pd.merge(shp, tf, left_on="osm_id", right_on="location", how="inner")
df = pd.merge(shp, tf, left_on="osm_id", right_on="location", how="inner", validate="1:1")
df["target"] = df.n / df.area

# Drop outliers
Expand Down

0 comments on commit 2a25f9f

Please sign in to comment.