TL;DR
This paper introduces PETSA, a parameter-efficient method for adapting time series forecasting models during inference. PETSA achieves competitive accuracy with significantly fewer trainable parameters than existing methods by only updating small calibration modules, making it more memory and computationally efficient.
What Problem Does This Paper Address?
Real-world time series data often exhibits non-stationarity, meaning its statistical properties change over time. This shift can significantly degrade the performance of pre-trained forecasting models. Test-Time Adaptation (TTA) aims to solve this by allowing models to adapt to new data distributions during inference. However, many existing TTA methods require updating the entire model, leading to high computational and memory costs, which can be prohibitive, especially for large forecasting models. This paper addresses the need for a TTA method that is both effective and efficient in terms of parameter usage for time series forecasting.
Methods
The core of PETSA lies in its parameter-efficient adaptation strategy. Instead of retraining the entire forecasting model, PETSA introduces two lightweight calibration modules: one for the input and one for the output. These modules are designed to adapt the representations of a frozen, pre-trained forecaster.
Key techniques include:
- Low-Rank Adapters: These are used within the calibration modules to efficiently transform the input and output data. By decomposing weight matrices into lower-rank components, the number of trainable parameters is drastically reduced.
- Dynamic Gating: This mechanism allows the adaptation to be conditioned on the input data itself, providing a more flexible and responsive adjustment of representations.
- Specialized Loss Function: To compensate for the limited adaptation capacity (due to parameter efficiency), PETSA employs a multi-component loss function:
- Robust Term (Huber Loss): Makes the adaptation robust to outliers in the data.
- Frequency-Domain Term: Preserves periodic patterns in the time series by aligning the frequency spectra of predictions and ground truth.
- Patch-wise Structural Term: Enhances structural alignment by capturing local correlations, means, and variances within data patches.
This combination allows PETSA to adapt effectively even with a small number of trainable parameters.
Datasets
The paper evaluates PETSA on several widely used multivariate time series forecasting benchmark datasets:
- ETTh1
- ETTm1
- ETTh2
- ETTm2
- Exchange Rate
- Weather
These datasets are standard for evaluating time series forecasting models and cover various application domains. No new benchmarks were introduced.
Key Insights and Ideas
- Parameter efficiency is crucial for TTA in TSF: The paper strongly demonstrates that achieving competitive forecasting accuracy during TTA doesn't necessitate updating the entire model. PETSA's success highlights that targeted, parameter-efficient adaptation can be highly effective.
- A multi-faceted loss function is key for limited adaptation: When adaptation capacity is constrained (due to parameter efficiency), a carefully designed loss function that addresses robustness, periodicity, and structural alignment is essential for maintaining high accuracy.
- Low-rank adapters and dynamic gating are powerful tools for efficient adaptation: These techniques, borrowed from other domains, prove highly effective in reducing the parameter footprint of TTA for time series, enabling faster and more memory-efficient adaptation.
- PETSA offers a strong trade-off between performance and efficiency: The results consistently show PETSA achieving comparable or better accuracy than a more parameter-heavy TTA method (TAFAS) while using orders of magnitude fewer parameters.
Key Results
- Superior Parameter Efficiency: PETSA uses significantly fewer trainable parameters than TAFAS. For example, at a window size of 720, PETSA uses up to 33.6x fewer parameters than TAFAS on the ETTh1 dataset. Memory usage is also drastically reduced, with PETSA using as little as 0.11MB compared to TAFAS's 3.70MB for similar performance on ETTm1.
- Competitive Accuracy: Despite its parameter efficiency, PETSA achieves competitive or better Mean Squared Error (MSE) scores across various datasets, window sizes, and forecasting backbones (Transformer-based, Linear-based, MLP-based). In Table 1, PETSA achieved 127 "best-MSE" wins compared to TAFAS's 88.
- Robustness Across Horizons: PETSA maintains its advantage even as the forecast window (horizon) increases, demonstrating its ability to handle longer-term uncertainty.
- Versatility: The framework is shown to improve the performance of multiple different forecasting backbones, indicating its general applicability.
Limitations and Future Work
- Hyperparameter Tuning: The paper mentions that the optimal beta (β) value for the frequency loss component might require hyperparameter tuning for different datasets and models, suggesting that while PETSA is efficient, some tuning might still be needed for peak performance.
- Dataset Specificity: While tested on several benchmarks, the performance of the frequency loss component can vary by dataset, as seen in Figure 13 where it sometimes harmed performance. Future work could explore more adaptive ways to balance these loss components.
- Future Work: The authors suggest further exploration of parameter-efficient TTA for time series forecasting, potentially by investigating more advanced calibration mechanisms or loss components. The current work lays a strong foundation for such future research.
Summary updated