Skip to main content

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.

Installation

  1. Install from registry

    pip install synthmob
    
  2. Set Up Google Earth Engine
    Authenticate on Google Earth Engine and create a project name (required by Google Earth Engine quota policy)

  3. 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


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!

Metadata

Release files for synthmob 0.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for synthmob 0.0.2
File Size Uploaded
synthmob-0.0.2.tar.gz 17.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for synthmob 0.0.2
File Interpreter ABI Platform
synthmob-0.0.2-py3-none-any.whl Python 3 none any Details

Total release size: 38.7 kB

Release files / synthmob-0.0.2.tar.gz

Download URL synthmob-0.0.2.tar.gz
Size 17.6 kB
Tags Source
SHA-256 checksum
How to use checksums
a8963f315138f00b4018c0d9360b8090d4b72664d03501a011ea8b63fae5dfb2
BLAKE2b-256 checksum
How to use checksums
d005c224901807a8e946a8ae9690bad2e32c989fa50a3bb6624c9fbbb1285df2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.3

Release files / synthmob-0.0.2-py3-none-any.whl

Download URL synthmob-0.0.2-py3-none-any.whl
Size 21.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d009c9ef28da8766b2aaf92161977cdc960fd7a394839b458c3ad26cbcb14055
BLAKE2b-256 checksum
How to use checksums
ebed92f358592e6bef2414811501e32758a08cabedb03ced8bd6f02b2bf97bc8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.3

Release history Release notifications | RSS feed

This release

0.0.2 This release

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page