Deep Features Analysis with Attention Networks

Da Chen, Shipeng Xie, Da Chen 0003, Rong Zhang, Hui XuearXiv 2019

Abstract

Deep neural networks are often criticized for their lack of interpretability, functioning as "black boxes" where the decision-making process is opaque. This paper proposes a novel approach to bridge the gap between internal feature representations and final predictions. By introducing a "sharable attention mechanism" integrated with atrous convolutions, the authors demonstrate that guiding a network to focus on relevant regions of interest (ROI) not only improves classification accuracy but also provides semantically interpretable visualizations. Experiments on the CIFAR-10 dataset show that early-stage attention intervention is particularly effective, yielding a 95.1% accuracy and producing cleaner, more focused heatmaps compared to existing attention-based architectures.

Introduction

The success of deep learning in computer vision is undeniable, yet the underlying reasons for a model's specific classification remain difficult to diagnose. This lack of transparency poses challenges for model optimization and deployment in safety-critical applications. The primary objective of this research is to enhance model interpretability by visualizing the "evidence" a network utilizes for its decisions. The authors hypothesize that by explicitly modeling attention, they can both improve performance and provide a diagnostic tool to verify if a model is focusing on the correct semantic features rather than background noise.

Methods: Sharable Attention and Atrous Convolution

The proposed architecture combines feature visualization with a unified bottom-up/top-down structure known as a Sharable Attention Network.

The Attention Mechanism

To create attention masks, the researchers append two $1 \times 1$ convolutional layers followed by a sigmoid activation function to the standard feature extraction layers. This mask acts as a spatial filter, which is element-wise multiplied by the original feature map. This process "focuses" the network's processing power on the most salient parts of the image.

The progression from raw feature maps to focused attention masks.

Atrous Convolution

To maintain high-resolution feature maps while expanding the receptive field, the implementation utilizes atrous (dilated) convolutions. This allows the network to capture broader context without the loss of spatial detail typically associated with standard pooling layers, which is crucial for generating precise heatmaps.

Experimental Setup and Datasets

The primary evaluation was conducted using the CIFAR-10 dataset, which contains 60,000 32x32 color images across 10 distinct classes. The authors modified the standard Inception-v1 architecture to include their sharable attention modules and compared its performance against the baseline Inception-v1 and the more complex Residual Attention Network (RAN-92).

Key Insights and Results

The study yielded several critical insights into the behavior of attention-guided networks.

Layer-Specific Focus and ROI

The analysis confirmed that different layers in the network attend to different levels of abstraction. Lower layers focus on primitive features like edges and textures, while deeper layers converge on high-level semantic objects. A significant finding was the correlation between "noise" in the heatmaps and classification errors. Models that produced scattered, unfocused heatmaps generally exhibited lower accuracy.

Visualization of regions of interest (ROI) using attention-based heatmaps.

The Importance of Early Intervention

One of the paper's most impactful conclusions is that the placement of the attention mechanism matters significantly. Testing across different stages revealed that early-stage attention provides critical supervision, helping the network discard irrelevant information (like background grass or sky) before it propagates through the deeper layers of the network.

  • Early Stage Placement: 94.71% accuracy
  • Middle Stage Placement: 94.55% accuracy
  • Later Stage Placement: 94.23% accuracy

Performance Comparison

The modified Inception-v1 outperformed both the standard baseline and the RAN-92 model:

Method Accuracy
Inception-v1 (Standard) 93.9%
RAN-92 95.0%
Inception-v1 (Ours) 95.1%

Conclusion and Future Work

By integrating a sharable attention mechanism, the authors successfully improved both the performance and the interpretability of deep neural networks. The resulting heatmaps serve as a powerful diagnostic tool, allowing researchers to verify the model's focus. Future research will aim to optimize the computational efficiency and explore specialized "attention loss" functions to further refine the learning of spatial masks. Extending these techniques to larger datasets like ImageNet remains a key goal for demonstrating scalability.

Summary updated

BibTeX
@misc{chen2019deep,
  author = {Da Chen and Shipeng Xie and Da Chen and Rong Zhang and Hui Xue},
  title = {{Deep Features Analysis with Attention Networks}},
  year = {2019},
  eprint = {1901.10042},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1901.10042},
}
Figure