The offcial pytorch implementation of TSMini.
@article{chang2025k,
title={K Nearest Neighbor-Guided Trajectory Similarity Learning},
author={Chang, Yanchuan and Cai, Xu and Jensen, Christian S and Qi, Jianzhong},
journal={arXiv preprint arXiv:2502.00285},
year={2025}
}
- A linux server with Python 3.11.0
pip install -r requirements.txt
- Datasets can be downloaded from here. (Notes: the file is shared by an anonymous account and the link is untrackable and bi-anonymous.)
tar -zxvf TSMini_datasets.tar.gz -C ./data/
Train and test TSMini to approximate Frechet on the Porto dataset:
python train_trajsimi.py --dataset porto --trajsimi_measure_fn_name frechet