Deep learning has revolutionized how we classify time series data—from detecting heart arrhythmias in ECGs to predicting stock market shifts. However, these models are notoriously "black boxes." When a model flags a heartbeat as abnormal, we often don't know why. Current explanation methods usually look at the data through a single lens (time) and produce fragmented results.
A new paper introduces MIX (Multi-view Time-Frequency Interactive EXplanation), a framework that looks at time series through multiple "lenses" of time and frequency to provide more faithful and human-readable explanations.
The Challenge of Explaining Time Series Models
Explaining Time Series Classification (TSC) is difficult for two primary reasons:
- The Domain Gap: Most explainers focus only on the time domain (when an event happens). But many critical patterns are defined by frequency (how fast a signal oscillates). If a model relies on a specific high-frequency "shiver" in the data, a time-only explainer might miss it entirely.
- Fragility and Fragmentation: Many methods provide "point-based" attributions, highlighting individual milliseconds. This results in "noisy" explanations that are hard for humans to interpret and often change wildly if the input data has even a tiny bit of random noise.
Existing tools like SpectralX tried to bridge this gap using Fourier transforms, but they used a fixed setup that didn't adapt well to different types of data and failed to map frequency insights back to the time-domain view that humans prefer.
The MIX Framework
To solve these issues, the authors propose a novel three-phase framework that leverages multi-resolution analysis.
1. Multi-view Construction (Haar DWT)
Instead of just looking at the raw signal, MIX uses the Haar Discrete Wavelet Transform (DWT) to break the signal into multiple resolutions. This creates a hierarchy of "views" ranging from coarse approximations to fine-grained details, allowing the explainer to capture both time and frequency features simultaneously.
2. OSIGV (Overlapping Segment-level Integrated Gradients)
Rather than scoring individual data points, MIX scores overlapping segments. This captures the temporal relationship between points and makes the explanation look more like cohesive "events" (e.g., a specific wave in an ECG) rather than random static. This approach avoids "edge effects" where an important pattern might be split between two non-overlapping segments.
3. Interactive Cross-view Refinement & Greedy Selection
This is the framework's "secret sauce." MIX identifies the "best" view (the one the model seems most confident about) and uses the information from that view to guide and refine the explanations in other views. They call this Keystone-first IG, inspired by "keystone species" in ecology that have a disproportionate impact on their environment. Finally, a greedy selection strategy traverses all these views to pick the most informative features and maps them back to the original time series for the user.
Key Results
The researchers put MIX through a rigorous gauntlet, testing it on synthetic datasets, 11 diverse real-world datasets from the UCR Archive, the MIT-BIH medical dataset, and the UEA Basic Motion multivariate dataset. MIX was compared against top-tier baselines like LIMESegment, InteDisUX, and SpectralX.
- Unmatched Faithfulness: MIX achieved the best performance in 24 out of 33 test cases. This means when MIX says a part of the data is important, removing that part causes the model's confidence to drop significantly—proving the explanation is "faithful" to the model's internal logic.
- Superior Robustness: In 27 out of 33 cases, MIX was the most robust. It provided consistent explanations even when the input data was perturbed with noise, whereas baseline methods often produced wildly different results.
- Medical Accuracy: On the MIT-BIH dataset, MIX's explanations overlapped significantly more with the actual regions cardiologists use to diagnose heart issues, achieving a Jaccard score of 0.63 compared to just 0.33 for LIMESegment.
Limitations and Future Work
While MIX represents a major step forward in making time series models transparent, the authors acknowledge a few areas for future development:
- Independent Channels: For multivariate data (like a 12-lead ECG), MIX currently treats each channel independently during the wavelet phase. Future versions could explore "cross-channel" wavelets to see how different sensors interact.
- Evaluation Metrics: The authors note that there is no perfect way to measure an explanation. While standard metrics like "Faithfulness" are useful, the field still needs more holistic ways to evaluate if an explanation actually helps a human make a better decision.
- Global Explanations: MIX is primarily a "local" explainer (explaining one specific prediction). While a global extension was proposed, more work is needed to effectively summarize what a model learns across an entire massive dataset.
By treating frequency as a first-class citizen and allowing different views of the data to collaborate, MIX provides a much-needed tool for building trust in the deep learning models that increasingly power our world.
Summary updated