UAI 2026Accept

From Moves to Paths: A Hierarchical Framework for Trajectory Representation Learning

Authors: Chundong Wang, Xiangtian Zheng, Qingbo Hao, Yongxin Zhao, Yixuan Song, Jia Li

Abstract

Trajectory representation learning (TRL) seeks to convert trajectory data into low-dimensional embeddings for various downstream tasks. Existing methods are limited to a single perspective: GPS-based approaches capture dynamic details but lack semantic context, while route-based methods preserve structure but lose fine-grained motion patterns. To address these limitations, we propose a trajectory representation model with multi-perspective fusion, MPH, where M denotes the Motion modality (GPS), P denotes the planned path modality (Route), andH signifies the Hierarchical encoding and fusion strategy. MPH first map-matches raw GPS trajectories to route sequences and designs dedicated encoders to extract dynamic behavioral patterns and static semantic features respectively. Based on this, MPH leverages a cross-attention mechanism for modality interaction and fusion, producing fused route representations that are hierarchically aggregated into trajectory-level embeddings. Furthermore, we introduce two self-supervised tasks to train the model. Contrastive learning is employed to align road segment representations across the two perspectives, while the dual-mask prediction task strengthens contextual modeling by jointly reconstructing masked road segment identities and their corresponding temporal information. Experiments on two real-world datasets show that MPH outperforms all baselines across different tasks.

PDFOpen original