PMME: Spatio-Temporal Few-Shot Learning via Pattern Matching with Memory Enhancement
摘要
Spatio-temporal forecasting is critical for urban computing but remains challenging for cities with limited historical data. Existing spatio-temporal few-shot methods are all based on spatio-temporal GNNs and struggle to capture long-range temporal dependencies, which limits cross-city transfer. We propose Pattern Matching with Memory Enhancement (PMME), a two-stage framework for cross-city spatio-temporal few-shot learning built on multivariate time-series backbones. In the first stage, a Pattern Matching (PM) module leverages Gaussian process-enhanced conditional optimal transport to match and align the features of spatio-temporal patterns shared between source and target cities, thereby mitigating negative transfer. In the second stage, a Residual Memory (RM) module then learns to correct residual errors of the frozen backbone via an attention-based memory matrix, focusing on spatio-temporal patterns that are rare in source cities but potentially common in the target. We further provide a theoretical analysis of PM’s generalization behavior under varying sample sizes and distributional discrepancies. Experiments on four real-world traffic benchmarks show that PMME improves strong backbones and outperforms state-of-the-art few-shot and domain adaptation baselines. Appendix and code are provided in the repository https://github.com/serre20/PMME .