Horizon Activation Mapping for Neural Networks in Time Series Forecasting
This paper introduces Horizon Activation Mapping (HAM), a model-agnostic visual interpretability technique that analyzes gradient norm averages across time series subseries to enable granular model selection, validation, and cross-family comparisons for diverse neural network architectures in time series forecasting.
Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer
Imagine you are trying to teach a robot to predict the weather for the next few weeks. You have many different types of robots (neural networks) to choose from, but they all speak different languages and use different internal gears. Usually, to see which robot is working best, you just look at the final score: "How close was the prediction to the actual weather?"
But what if you want to know how the robot is thinking? What if you want to see which days it is paying attention to and which days it is ignoring? That is exactly what this paper introduces: a tool called Horizon Activation Mapping (HAM).
Here is a simple breakdown of what the paper does, using everyday analogies.
1. The Problem: The "Black Box" Forecasters
In the world of time series forecasting (predicting future numbers based on past data), there are many different "families" of AI models. Some are like fast runners (MLPs), some are like careful readers (Self-Attention), and some are like time-traveling detectives (Diffusion models).
Currently, if you want to compare them, you just look at the final error score. It's like judging two chefs only by how good the final dish tastes, without ever seeing their cooking process. You don't know if one chef is chopping vegetables perfectly while the other is burning the sauce. The authors wanted a way to "see inside" these different robots to understand their learning process, regardless of their internal design.
2. The Solution: HAM (The "Heat Map" of Time)
The authors created Horizon Activation Mapping (HAM). Think of this as a heat map for time.
- The Analogy: Imagine you are watching a movie. A standard heat map (like Grad-CAM used in image AI) shows you which parts of the screen the AI is looking at. HAM does something similar, but for time.
- How it works: Instead of looking at an image, HAM looks at a timeline of data (the "horizon"). It asks: "As the AI tries to predict the future, how much effort (gradient) is it putting into the beginning of the timeline versus the end?"
- The Two Modes:
- Causal Mode: The AI looks at the past to predict the future (like reading a book from page 1 to the end).
- Anti-Causal Mode: The AI looks at the future to understand the past (like reading a book from the last page backward to the start).
- HAM draws a line for both. If the line is straight, the AI is treating all days equally. If the line curves up or down, it means the AI is focusing more on specific parts of the timeline.
3. What They Discovered (The "Experiments")
The authors tested this tool on various models using a dataset of energy consumption (ETTm2). Here are their key findings, translated into simple terms:
Dropouts (The "Distraction" Test):
They added "dropouts" (randomly turning off parts of the network) to see if it helped. They found that for complex, multi-variable tasks, adding dropouts made the AI work harder (higher gradient magnitudes), especially on the longer-term predictions. It's like telling a student to take a break every few minutes; surprisingly, it made them focus more intensely on the long-term homework.Batch Size (The "Class Size" Effect):
They changed how many data points the AI studied at once (batch size).- The Finding: When the "class size" (batch size) changed, the AI's behavior changed in a very predictable, smooth way. It's as if the AI's "effort curve" follows a specific mathematical recipe (a polynomial) depending on how many examples it sees at once. This suggests that even if the final score looks the same, the way the AI learns is different based on batch size.
Early Stopping (The "Quit Too Soon" Test):
They stopped training the AI before it was fully finished.- The Finding: When training stopped early, the AI's "effort" dropped significantly. The tool showed that the AI stopped trying to learn the long-term patterns (the end of the timeline) and just settled for a "good enough" local solution. It's like a student who stops studying a week before the exam and only memorizes the first chapter.
Different Model Families:
They compared different types of AI (like N-HITS, FEDformer, SpaceTime, and Diffusion models).- N-HITS: This model showed a specific pattern that matched its mathematical theory: it treats the future as a linear combination of the past. The HAM plot confirmed this "neural approximation."
- SpaceTime: This model showed a shift from a straight line to an exponential curve as the prediction horizon got longer. It means this model naturally focuses much more on the distant future as the prediction window gets wider.
- Diffusion Models: These models (which use noise to learn) showed that they treat small chunks of time with very high intensity, almost like a constant hum, regardless of how far into the future they are predicting.
4. Why This Matters
The paper argues that HAM is a universal translator.
- Before: You could only compare models by their final score (MSE/MAE).
- Now: You can look at the HAM plot and say, "Ah, Model A is ignoring the last 20% of the timeline, while Model B is focusing heavily on the middle."
This allows researchers to:
- Pick the right model for a specific job (e.g., if you need to predict far into the future, pick the model whose HAM curve shows it cares about the long term).
- Choose better data splits (deciding which data to use for training vs. testing) by seeing how the AI reacts to different data chunks.
- Understand the "Optimization Landscape": They can see if the AI is stuck in a "local valley" (a mediocre solution) or if it is climbing the right mountain.
Summary
The paper introduces HAM, a visual tool that acts like an X-ray for time-series AI. Instead of just looking at the final grade, it shows you exactly where and how hard the AI is working across the timeline. It reveals that different AI families have distinct "personalities" in how they learn, and this tool helps us see those differences clearly, regardless of the model's internal architecture.
Drowning in papers in your field?
Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.