用自适应网格和掩码训练,让轨迹模型通用更强。
TrajTok: Adaptive Spatial Tokenization for Trajectory Representation Learning

- 根据轨迹分布自动生成多分辨率六边形网格,转为离散令牌。
- 在波罗多数据集上,冻结编码器+轻量适配器胜过专用模型。
- 适合需要通用轨迹表示的场景,如路径搜索、到达时间预测。
从原始GPS轨迹学习可泛化的轨迹表示仍具挑战,因数据连续、噪声大且采样不规则。空间分块也困难:细网格导致稀疏单元嵌入弱,粗网格则将不同运动模式混为一谈。我们提出TrajTok,一种轨迹编码器及简单预训练方案,实现可迁移的轨迹嵌入。TrajTok首先从GPS点的空间分布学习多分辨率六边形分区,将噪声轨迹转换为离散单元令牌。为同时捕捉几何与运动学信息,采用分解式Transformer编码器,包含早期模态自注意力块、交叉注意力融合层及时空旋转位置编码(ST-RoPE),以编码每个令牌的位置与时间。通过掩码令牌建模进行预训练,恢复部分轨迹中的几何结构与运动模式。在波罗多数据集上,冻结的TrajTok编码器搭配轻量任务适配器,在轨迹相似性搜索、分类、预计到达时间及全程旅行时间回归任务中表现优异,超越多个专用方法。同一编码器同时支持几何主导与运动学主导任务,表明其学习的是可迁移的轨迹结构而非特定任务捷径。结果表明,学习的多分辨率空间分块结合掩码预训练,是构建通用轨迹基础模型的有前景方向。
原文摘要 · Abstract (English)
Learning generalizable trajectory representations from raw GPS traces remains difficult because the data is continuous, noisy, and irregularly sampled. Spatial tokenization is also challenging: fine grids yield sparse cells with weak embeddings, while coarse grids merge heterogeneous movement patterns into the same token. We present TrajTok, a trajectory encoder with a simple pretraining recipe for transferable trajectory embeddings. TrajTok first learns a multi-resolution hexagonal cell partition from the spatial distribution of GPS points, converting noisy GPS sequences into discrete cell tokens. To capture both geometry and kinematics, it uses a factorized transformer encoder with early per-modality self-attention blocks, cross-attention fusion layers, and spatiotemporal rotary position embeddings, ST-RoPE, to encode where and when each token occurs. TrajTok is pretrained with masked-token modeling that recovers both geometric structure and kinematic patterns from partial trajectory observations. On the Porto dataset, a frozen TrajTok encoder with lightweight task adapters achieves strong performance across trajectory similarity search, classification, estimated time of arrival, and full travel-time regression, outperforming multiple task-specific methods. The same frozen encoder supports both geometry-dominated and kinematics-dominated tasks, suggesting that TrajTok learns transferable trajectory structure rather than task-specific shortcuts. These results indicate that learned multi-resolution spatial tokenization combined with masked-token pretraining is a promising direction for general-purpose trajectory foundation models.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。