Exploring how deep learning decodes anomalous diffusion via Grad-CAM

Jaeyong Bae, Yongjoo Baek, Hawoong JeongarXiv 2024 · DOI

Abstract

Deep learning models are exceptionally good at identifying the physical mechanisms behind "anomalous diffusion" in particle trajectories, but they are notoriously difficult to interpret. This paper uses Grad-CAM to reveal that these models act like hierarchical physicists—first identifying local "wiggles" (autocorrelation) in early layers before zooming out to recognize long-range patterns (varying diffusivity) in deeper layers. Validation via targeted erasure and augmentation confirms the physical relevance of the identified features.

Introduction

Anomalous diffusion—where particles spread at rates different from standard Brownian motion—is a hallmark of complex systems, from proteins moving in a cell to stock market fluctuations. While several mathematical models describe these movements (e.g., Fractional Brownian Motion, Lévy Walks), identifying which model fits a specific, noisy trajectory is a major challenge. Deep learning, specifically Convolutional Neural Networks (CNNs), has recently dominated this classification task. However, these models are often viewed as "black boxes." This research seeks to "open the box" to understand which features of a trajectory lead to specific classifications.

Methods: ResAnDi and Grad-CAM

The authors developed ResAnDi, a modified ResNet18 architecture designed to handle 2D time-series data (x and y coordinates). To interpret the model, they employed Grad-CAM (Gradient-weighted Class Activation Mapping). Grad-CAM produces a "heatmap" over the input trajectory, highlighting the specific sub-intervals that contributed most to the model's final decision.

Overview of the ResAnDi architecture and Grad-CAM interpretability pipeline.

To validate these highlights, the authors performed two rigorous tests:

  1. Targeted Erasure: Erasing parts of the trajectory with high Grad-CAM scores caused the model's accuracy to plummet, confirming the scores' accuracy.
  2. Targeted Augmentation: Focusing data augmentation (rotations) on the most "informative" trajectories identified by Grad-CAM significantly improved robustness against measurement noise.

The Multiscale Physicist: Hierarchical Learning

A key finding is the hierarchical nature of the learning process. By using t-SNE to visualize the output of different blocks, the authors showed that early layers distinguish models based on local features (like "jaggedness" or autocorrelation). Deeper layers are required to distinguish models that look similar locally but differ in long-range behavior (like varying diffusivity over the entire path).

t-SNE visualizations of feature separation across different ResAnDi blocks, showing the transition from local to global feature recognition.

The authors correlated Grad-CAM scores with human-designed statistical measures, such as Autocorrelation (AC) for early-layer decisions and Varying Diffusivity (VD) for late-layer decisions. This provides a physical grounding for the features learned by the "black box."

Key Results and Performance

ResAnDi achieved an overall classification accuracy of 90.36%, comparable to top-performing algorithms in the AnDi challenge. Validation experiments showed that erasing the top 10% of Grad-CAM-important intervals reduced accuracy far more than random erasure. Furthermore, models trained with "Targeted Augmentation" were significantly more robust when tested on data with a low Signal-to-Noise Ratio (SNR).

Conclusion

This work demonstrates that deep learning models for anomalous diffusion are not just black boxes but act as multiscale feature extractors. Grad-CAM serves as a powerful tool for both interpreting model decisions and improving training efficiency through targeted augmentation. Future work may involve building active learning pipelines or designing architectures that explicitly incorporate these discovered multiscale attention mechanisms.

Summary updated

BibTeX
@misc{bae2024exploring,
  author = {Jaeyong Bae and Yongjoo Baek and Hawoong Jeong},
  title = {{Exploring how deep learning decodes anomalous diffusion via Grad-CAM}},
  year = {2024},
  eprint = {2410.16345},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2410.16345},
}
Figure