Exploring Explainability in Video Action Recognition

Avinab Saha, Shashank Gupta, Sravan Kumar Ankireddy, Karl Chahine, Joydeep Ghosh

Abstract

Image Classification and Video Action Recognition are perhaps the two most foundational tasks in computer vision. Consequently, explaining the inner workings of trained deep neural networks is of prime importance. While numerous efforts focus on explaining the decisions of trained deep neural networks in image classification, exploration in the domain of its temporal version, video action recognition, has been scant. In this work, we take a deeper look at this problem. We begin by revisiting Grad-CAM, one of the popular feature attribution methods for Image Classification, and its extension to Video Action Recognition tasks and examine the method's limitations. To address these, we introduce Video-TCAV by building on TCAV for Image Classification tasks, which aims to quantify the importance of specific concepts in the decision-making process of Video Action Recognition models. As the scalable generation of concepts is still an open problem, we propose a machine-assisted approach to generate spatial and spatiotemporal concepts relevant to Video Action Recognition for testing Video-TCAV. We then establish the importance of temporally-varying concepts by demonstrating the superiority of dynamic spatiotemporal concepts over trivial spatial concepts. In conclusion, we introduce a framework for investigating hypotheses in action recognition and quantitatively testing them, thus advancing research in the explainability of deep neural networks used in video action recognition.

Introduction

While explainability in image classification has matured, video action recognition remains a "black box" due to the added complexity of time. Most Explainable AI (XAI) research focuses on static images. When applied to video, popular methods like Grad-CAM, which produces heatmaps of "important" pixels, often fall short. They frequently ignore the temporal interplay between frames; for example, a model might identify "playing tennis" based solely on a static image of a tennis court (the background) rather than the actual motion of the player.

Comparison of Grad-CAM feature attribution showing a positive case (a) and a limitation (b) where the model focuses on the background court rather than the player's action.

Furthermore, Grad-CAM provides only local explanations, detailing why a model made a specific decision for one specific video. To understand what a model has learned across an entire dataset, researchers require global explanations. This work bridges this gap by extending Testing with Concept Activation Vectors (TCAV) to the video domain via the proposed Video-TCAV framework.

Methodology

Video-TCAV moves beyond pixel-level analysis to quantify how much high-level concepts influence a model's decision. Instead of looking at pixels, TCAV analyzes "concepts"—high-level ideas like "stripedness" or "rackets."

Model and Concept Generation

The framework was tested on the Video Swin Transformer, a state-of-the-art model for action recognition. To avoid the manual labor of hand-picking concept videos, an automated pipeline was developed using YOLO-v7 to extract specific objects from the Kinetics-400 dataset.

The Video Swin Transformer architecture, indicating the specific layers (1, 2, and 3) where Video-TCAV scores were calculated to observe the evolution of concept importance.

The study distinguishes between two types of concepts:

  • Spatial Concepts: Static crops of an object repeated across all frames, representing appearance without motion.
  • Spatiotemporal Concepts: Tracking an object as it moves across frames to capture the dynamics of the action.

TCAV Scores

By training a linear classifier to distinguish between a concept (e.g., "tennis racket") and random noise in the model's internal embedding space, the framework calculates a score representing the model's sensitivity to that concept at different layers.

Results and Discussion

Analysis using Video-TCAV revealed several key insights into how deep video models process information.

The Background Trap and Concept Significance

While Grad-CAM often highlights the tennis court, Video-TCAV reveals that the model's actual understanding of the action relies on more specific objects like the racket or the player. Using two-sided t-tests with Bonferroni correction, the authors proved that the concepts identified by Video-TCAV were statistically significant (p < 0.05) compared to random noise.

Temporal Dominance with Depth

A critical finding is that motion matters more as depth increases. In the early layers of the neural network, static (spatial) and moving (spatiotemporal) concepts are treated with similar importance. However, as information moves deeper into the network, the importance of static concepts plateaus or drops, while the importance of motion-based concepts increases significantly. In the final layer of the Video Swin Transformer, the model almost exclusively prefers spatiotemporal concepts for making its final prediction.

This progression mirrors the human brain's visual cortex, where basic features are processed in the V1 area first, and motion is handled later in the V5/MT area. Deep video models appear to have evolved a similar hierarchical structure.

Conclusion

Video-TCAV provides a more nuanced, concept-level explanation than traditional heatmap-based methods. While the framework currently depends on the accuracy of object detectors like YOLO-v7, it establishes a robust foundation for investigating hypotheses in action recognition. Future work may leverage text-to-video diffusion models to generate even more granular concept clips, allowing for more precise testing of specific model behaviors.

Summary updated

BibTeX
@inproceedings{saha2024exploring,
  author = {Avinab Saha and Shashank Gupta and Sravan Kumar Ankireddy and Karl Chahine and Joydeep Ghosh},
  title = {{Exploring Explainability in Video Action Recognition}},
  booktitle = {XAI4CV},
  year = {2024},
  url = {https://openreview.net/forum?id=LD56Lu5y97},
}
Figure