Parametric generator of synthetic gps data.
Project description
SynthMob: A Framework for Generating Synthetic High Frequency Mobility Data
SynthMob is a framework designed to help the generation of synthetic mobility data with realistic distributions by combining publicly available geospatial data from multiple sources. The framework integrates population and building data, points of interest (POIs), and road network data to compute synthetic origin-destination pairs and simulate movement patterns.
No deep learning algorithm is involved, but it is highly customizable and origin and destination can be a direct expert user input derived from them.
Features
The expected usage is a pipeline shown in the example notebook. After setting the city, the CRS projection and the timezone:
-
Population and Building Height Data Integration
- Fetches population and building height rasters from Google Earth Engine.
- Population data is retreived from WorldPop
- Building height is retrieved from GHSL
- Assigns inhabitants from raster pixels to buildings using building volume as a disaggregating factor.
-
Buildings, POIs and Road Network Extraction
- Retrieves building footprints, POIs, and road network data from Overture Maps Foundation.
- Builds a proximity graph for POIs based on k-nearest neighbors (kNN) above a defined distance threshold (anything below is fully connected).
-
Centrality and Importance Computation
- Computes the betweenness centrality of POIs on the proximity graph.
- Determines POI importance using centrality, area, and category frequency.
-
Origin-Destination Mapping
- Connects computed origins (home locations) and destinations (important POIs) using paths on the road network.
-
Synthetic Mobility Data Generation
- Generates realistic synthetic pings:
- Power-law distributions for speed, spatial distance, temporal delta, number of pings per user.
- Highly customizable and parametric:
- Parametric control of movement peaks during morning and evening rush hours.
- Possibility of setting max pings per user to increase density or generate seasonality.
- Generates realistic synthetic pings:
Installation
-
Install from registry
pip install synthmob
-
Set Up Google Earth Engine
Authenticate on Google Earth Engine and create a project name (required by Google Earth Engine quota policy) -
Run!
Future Developments
- A simpler Colab notebook and a Dockerfile will be available soon.
- There may be some updates on POI importance computation and graph compression.
- I will make seasonality a parameter and compress the pipeline further.
- I will start generating some large scale synthetic dataset for areas I am interested in (in case I will share them on huggingface)
Contributing
I welcome contributions to SynthMob! Feel free to open issues or submit pull requests to improve the framework.
License
SynthMob is licensed under the MIT License.
Acknowledgments
- Google Earth Engine
- Overture Maps Foundation
- Contributors to open-source geospatial libraries.
Contact
If you have any questions or need further assistance, feel free to open an issue on GitHub or contact me at lwdovico@protonmail.com
Happy Mapping!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file synthmob-0.0.2.tar.gz.
File metadata
- Download URL: synthmob-0.0.2.tar.gz
- Upload date:
- Size: 17.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a8963f315138f00b4018c0d9360b8090d4b72664d03501a011ea8b63fae5dfb2
|
|
| MD5 |
1d07b9471238d699bc9d2dfff946b1c9
|
|
| BLAKE2b-256 |
d005c224901807a8e946a8ae9690bad2e32c989fa50a3bb6624c9fbbb1285df2
|
File details
Details for the file synthmob-0.0.2-py3-none-any.whl.
File metadata
- Download URL: synthmob-0.0.2-py3-none-any.whl
- Upload date:
- Size: 21.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d009c9ef28da8766b2aaf92161977cdc960fd7a394839b458c3ad26cbcb14055
|
|
| MD5 |
ecd8f60e4c4f13ff739bbf0bb8a49b16
|
|
| BLAKE2b-256 |
ebed92f358592e6bef2414811501e32758a08cabedb03ced8bd6f02b2bf97bc8
|