The Hamburg Base Model (HBM) is a base model for developing agent-based models and running simulations set in the city of Hamburg, Germany. As a base model, it provides georeferenced data spanning all of Hamburg (see below for a list of layer types). The HBM is builds on the SmartOpenHamburg (SOH) model designed by the MARS group, which is a traffic model and digital twin of Hamburg, Germany.
The following system requirements need to be met to build and run MARS models:
- .NET Core
- JetBrains Rider
- Installing the MARS NuGet package (see below)
- Clone the GitLab repository
- Open Rider
- Click on "Import Project from Solution"
- Select the HBM solution file
HamburgBaseModel.sln
- Once the project has loaded, click on "NuGet" (in the footer bar of Rider)
- Enter "Mars.Life.Simulations" in the search bar
- Install the NuGet packages "Mars.Life.Simulations" and "Mars.Life.SOH"
- The Rider IDE should now be able to resolve the project dependencies and imports
To run a simulation, follow these steps:
- In Rider, open the HBM's main file:
HamburgBaseModel/Program.cs
- Run
Main(string[] args)
Below is a list of some of the layer data provided along ith the HBM:
HamburgBaseModel/Resources/altona_mitte
: georeferenced environment data for the Hamburg districts Ottensen, Altona-Altstadt, St. Pauli, Altona-Nord, and SternschanzeHamburgBaseModel/Resources/hamburg
: georeferenced environment data for the Hamburg metropolitan area
Note
Due to file size restrictions, some of the input files are provided in ZIP archives. Such files need to be unzipped to become accessible to the model and usable for a simulation.
By default, simulations produce a file trips.geojson
in the directory bin
that is auto-generated when the project is compiled and run. This file contains the movement trajectories of all agents that moved during the simulation. To visualize the trajectories:
- In an internet browser, open kepler.gl
- Click on "Get Started"
- Drag-and-drop the GEOJSON file into the window
- Click the play button to start the visualization. You can make adjustments to the visualization in the left sidebar.