# RED: Effective Trajectory Representation Learning with Comprehensive Information

arXiv: https://arxiv.org/abs/2411.15096 · HTML: https://mlsanity.com/paper/2411.15096/

## Key facts

- Cited by 8 papers in the map (data through 14 Oct 2026).
- Builds on 17 of its 51 references that are in the map.
- First posted on arXiv 22 Nov 2024.

## Builds on (most cited first, 17 of 17)

- [Attention Is All You Need](https://mlsanity.com/paper/1706.03762/) (2017)
- [BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding](https://mlsanity.com/paper/1810.04805/) (2018)
- [Graph Attention Networks](https://mlsanity.com/paper/1710.10903/) (2017)
- [Masked Autoencoders Are Scalable Vision Learners](https://mlsanity.com/paper/2111.06377/) (2021)
- [Efficient Estimation of Word Representations in Vector Space](https://mlsanity.com/paper/1301.3781/) (2013)
- [node2vec: Scalable Feature Learning for Networks](https://mlsanity.com/paper/1607.00653/) (2016)
- [Recurrent Neural Networks for Multivariate Time Series with Missing Values](https://mlsanity.com/paper/1606.01865/) (2016)
- [Time2Vec: Learning a Vector Representation of Time](https://mlsanity.com/paper/1907.05321/) (2019)
- [Self-supervised Trajectory Representation Learning with Temporal Regularities and Travel Semantics](https://mlsanity.com/paper/2211.09510/) (2022)
- [GETNext: Trajectory Flow Map Enhanced Transformer for Next POI Recommendation](https://mlsanity.com/paper/2303.04741/) (2023)
- [Contrastive Trajectory Similarity Learning with Dual-Feature Attention](https://mlsanity.com/paper/2210.05155/) (2022)
- [Unsupervised Path Representation Learning with Curriculum Negative Sampling](https://mlsanity.com/paper/2106.09373/) (2021)
- [Jointly Contrastive Representation Learning on Road Network and Trajectory](https://mlsanity.com/paper/2209.06389/) (2022)
- [LightPath: Lightweight and Scalable Path Representation Learning](https://mlsanity.com/paper/2307.10171/) (2023)
- [Weakly-supervised Temporal Path Representation Learning with Contrastive Curriculum Learning -- Extended Version](https://mlsanity.com/paper/2203.16110/) (2022)
- [Self-supervised Representation Learning for Trip Recommendation](https://mlsanity.com/paper/2109.00968/) (2021)
- [Review and Perspective for Distance Based Trajectory Clustering](https://mlsanity.com/paper/1508.04904/) (2015)

## Built on by (most cited first, 8 of 8)

- [Leveraging the Spatial Hierarchy: Coarse-to-fine Trajectory Generation via Cascaded Hybrid Diffusion](https://mlsanity.com/paper/2507.13366/) (2025)
- [Traj-MLLM: Can Multimodal Large Language Models Reform Trajectory Data Mining?](https://mlsanity.com/paper/2509.00053/) (2025)
- [Spatio-Temporal Trajectory Foundation Model - Recent Advances and Future Directions](https://mlsanity.com/paper/2511.20729/) (2025)
- [REFINE: Trajectory Representation Learning via Closed-Loop Transcription -- Extended Version](https://mlsanity.com/paper/2609.07206/) (2026)
- [DGCPath: Distribution-Aware Generative Contrastive Framework for Self-supervised Path Representation Learning -- Extended Version](https://mlsanity.com/paper/2609.07316/) (2026)
- [TrajSceneLLM: A Multimodal Perspective on Semantic GPS Trajectory Analysis](https://mlsanity.com/paper/2506.16401/) (2025)
- [Capturing Context-Aware Route Choice Semantics for Trajectory Representation Learning](https://mlsanity.com/paper/2510.14819/) (2025)
- [Efficient Prompt Learning for Traffic Forecasting](https://mlsanity.com/paper/2605.08273/) (2026)

## Abstract (arXiv)

Trajectory representation learning (TRL) maps trajectories to vectors that can then be used for various downstream tasks, including trajectory similarity computation, trajectory classification, and travel-time estimation. However, existing TRL methods often produce vectors that, when used in downstream tasks, yield insufficiently accurate results. A key reason is that they fail to utilize the comprehensive information encompassed by trajectories. We propose a self-supervised TRL framework, called RED, which effectively exploits multiple types of trajectory information. Overall, RED adopts the Transformer as the backbone model and masks the constituting paths in trajectories to train a masked autoencoder (MAE). In particular, RED considers the moving patterns of trajectories by employing a Road-aware masking strategy} that retains key paths of trajectories during masking, thereby preserving crucial information of the trajectories. RED also adopts a spatial-temporal-user joint Embedding scheme to encode comprehensive information when preparing the trajectories as model inputs. To conduct training, RED adopts Dual-objective task learning}: the Transformer encoder predicts the next segment in a trajectory, and the Transformer decoder reconstructs the entire trajectory. RED also considers the spatial-temporal correlations of trajectories by modifying the attention mechanism of the Transformer. We compare RED with 9 state-of-the-art TRL methods for 4 downstream tasks on 3 real-world datasets, finding that RED can usually improve the accuracy of the best-performing baseline by over 5%.
