Computing spatial trajectories largely relies on traces generated by a moving object in geographical spaces (e.g. taxis, public transport and some individuals). MATSim is a multi-agent transport simulation framework for large scale scenarios, which can generate data sets with specific properties for trajectory computing. This project aims at implementing MATSim scenarios to generate synthetic trajectory data and illustrate trajectory classification and trajectory clustering.
Therefore, this repository provides codes to rebuild and analyze synthetic trajectory data from the following MATSim scenarios:
To understand how to set up a simulation and run it, please refer to the respective repositories
Next, it will provide codes to illustrate trajectory clustering/classification using the synthetic trajectory data sets.
-
src
for source codes. Usually, jupyter notebooks end with*.ipynb
. -
input
for input data (typically MATSim output data by MATSim runs, or by postprocessing) to rebuild and analyze the synthetic trajectories. -
ouput
for ouput data, analysis data, and visualization (typically generated by the codes files or by postprocessing). -
scenarios
for MATSim scenarios, i.e. MATSim input and output data. A good way is the following:- One subdirectory for each scenario, e.g.
scenarios/mySpecialScenario01
. - This minimally contains a config file, a network file, and a population file.
- Output goes one level down, e.g.
scenarios/mySpecialScenario01/output-from-a-good-run/...
.
- One subdirectory for each scenario, e.g.
Handling of large files within git is not without problems. As a result, large files, both on the input and on the output side, reside at scenarios and original-data.
Alternative 1: use available raw trajectory data from trajectory-model repository
- Clone the trajectory-model: https://github.com/lubaso/trajectory-model
- Run the Jupyter Notebook
src/rebuild_trajectory.ipynb
Alternative 2: generate raw trajectory data from matsim-model repository
- Clone the matsim-model: https://github.com/lubaso/matsim-model
- Run the Java class
src/main/java/org/matsim/project/RunEventsSiouxFalls.java
orsrc/main/java/org/matsim/project/RunEventsBerlin.java
- Clone the trajectory-model: https://github.com/lubaso/trajectory-model
- Run the Jupyter Notebook
src/rebuild_trajectory.ipynb
TODO
TODO