Skip to content

ZeroCSIS/TrajFlow

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TrajFlow: nationwide Pseudo GPS Trajectory Generation with Flow Matching Models

This repository is the implementation of paper TrajFlow: nationwide Pseudo GPS Trajectory Generation with Flow Matching Models.

TrajFlow Motivation

Paper

TrajFlow is a flow-matching based framework for pseudo GPS trajectory generation targeting multi-scale mobility patterns.

Data Availability

  • This repository provides the training and inference pipeline for TrajFlow.
  • The main paper conclusions are validated on BW data, which is commercial/private and not open-sourced here.
  • Open-source support is provided for DiDi Chengdu/XiAn data to verify that the pipeline works on public-style data.
  • This repository does not ship raw trajectories, private data, or model checkpoints.
  • We do not redistribute DiDi datasets. Please obtain data from official/authorized channels under your own compliance responsibility.

Expected local layout for testing:

  • ./data/DiDiTaxi_Chengdu_traj
  • ./data/DiDiTaxi_XiAn_traj

Setup

conda env create -f environment.yml
conda activate flow_matching_py311
pip install -r requirements.txt

Notes:

  • flow_matching is installed as an external dependency via requirements.txt.
  • This repository does not vendor a local flow_matching/ copy.

Usage

Training:

python train.py --config ./src/config/config_chengdu.yaml
# XiAn:
# python train.py --config ./src/config/config_xian.yaml

Generation:

python generate.py \
  --config ./outputs/run_YYYYMMDD_HHMMSS/config.yaml \
  --checkpoint ./outputs/models/run_YYYYMMDD_HHMMSS/best_model.pt
  • Evaluation scripts are intentionally omitted from the open-source release to keep the repository focused on the core training/generation pipeline.

License

Unless otherwise noted, the original code in this repository is released under CC BY-NC 4.0 (LICENSE).

This repository also includes third-party code under separate licenses. For example, src/utils/jismesh_v2/ is distributed under the MIT License; see src/utils/jismesh_v2/LICENSE.

Citation

If you use this repository, please cite:

@inproceedings{li2026trajflow,
  title={TrajFlow: nationwide Pseudo GPS Trajectory Generation with Flow Matching Models},
  author={Li, Peiran and Wang, Jiawei and Zhang, Haoran and Shi, Xiaodan and Koshizuka, Noboru and Shimizu, Chihiro and Jiang, Renhe},
  booktitle={International Conference on Learning Representations (ICLR)},
  year={2026},
  url={https://openreview.net/forum?id=BDOldEjwCE}
}

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages