Visualizing the decision-making process in deep neural decision forest

Shichao Li, Kwang-Ting Cheng

TL;DR

This paper introduces a gradient-based visualization technique called Decision Saliency Maps (DSMs) to peer inside the "black box" of Deep Neural Decision Forests (NDFs). By tracing how inputs are routed through the forest for both classification and regression tasks, the authors demonstrate that these models retain the highly decisive, interpretable routing behavior of traditional decision trees while leveraging the power of deep learning.

What Problem Does This Paper Address?

Traditional decision trees are highly valued for their interpretability: an input follows a clear, logical path through splitting nodes to a single leaf node prediction. However, their reliance on hand-crafted features limits their performance on complex visual tasks.

Deep Neural Decision Forests (NDFs) bridge this gap by combining deep convolutional neural networks (CNNs) as feature extractors with decision trees. To make the entire structure differentiable and trainable via backpropagation, NDFs use a "soft routing" framework where an input is probabilistically sent down every path simultaneously. While this drastically improves accuracy, it comes at a cost: visiting every leaf node makes it difficult to see exactly how a decision was reached. Furthermore, prior to this work, there were no visualization tools to explain NDF routing choices, and their behavior in regression tasks remained unvalidated.

Figure 1: Illustration of the decision-making process in deep neural decision forest. Input images are routed (red arrows) by splitting nodes and arrive at the prediction given at leaf nodes. The feature extractor computes deep repre- sentation from the input and send it (blue arrows) to each splitting node for decision making. Best viewed in color.

Methods

The authors tackle the interpretability problem using two key approaches:

  1. Decision Saliency Maps (DSM): To understand which parts of an image influence a specific routing choice, the authors compute the gradient of the routing probability ($s_i$) at a given splitting node with respect to the input image ($x$): $$\text{DSM} = \frac{\partial s_i}{\partial x}$$ This highlights the exact pixels that the feature extractor relies on when deciding whether to send an image left or right at a specific node.

  2. Cascaded NDFs for Regression: The authors extend NDFs to a complex multi-coordinate regression task: 3D face alignment. They use a boosted cascade of NDFs across 10 stages. At each stage, the model takes local patches around currently estimated facial landmarks and outputs a shape update vector to iteratively refine the landmark positions.

Datasets

The approach was evaluated using three standard benchmarks:

  • MNIST: For baseline handwritten digit classification.
  • CIFAR-10: For more complex object classification.
  • 3DFAW (3D Face Alignment in the Wild): A challenging multi-task coordinate regression dataset used to predict the positions of 66 facial landmarks.

Key Insights and Ideas

  • Naturally Decisive Routing: A major revelation is that despite being trained with "soft" probabilities, NDFs are highly decisive at inference time. The routing probabilities strongly peak near 0.0 and 1.0. This means the model naturally emulates the clean, sparse paths of traditional "hard" decision trees.
  • Dynamic Gaze Shifting: By analyzing the DSMs along a computation path, the authors found that the network looks at entirely different regions of the input image at different splitting nodes (visible as shifting highlights across the path). The model dynamically changes its focus depending on the specific sub-decision it is making.
  • Uncertainty Correlates with Error: When the routing probability drops closer to 0.5 (indicating ambiguity), the model's performance degrades. For example, the authors observed that the model frequently misclassifies a dog as a bird when its routing certainty wavers.
Figure 2: Decision saliency maps for MNIST test set. Each row gives the decision-making process of one image, where the left-most image is the input and the others are DSMs along the computation path of the input. Each DSM is computed by taking derivative of the routing probability with respect to the input image. Model prediction is given above the input image and (Na, Pb) means the input arrives at splitting node a with probability b during the decision-making process.

Key Results

  • Classification Accuracy: The NDF achieved competitive results, hitting 99.3% accuracy on MNIST using a shallow CNN, 92.4% on CIFAR-10 using a VGG16 backbone, and 93.4% on CIFAR-10 using a ResNet50 backbone.
  • Regression Performance: On the 3DFAW dataset, the cascaded NDF successfully updated coarse initial face shapes to tightly fit ground-truth facial landmarks. Crucially, the distribution of recommendation scores remained heavily peaked at 0 and 1 across early, middle, and late stages (Stages 1, 5, and 10), proving for the first time that NDF decisiveness holds true for regression tasks.

Limitations and Future Work

The authors note that their method functions strictly as a visualization-based diagnostic tool. The current framework does not introduce an explicit loss function to actively drive or enforce semantically meaningful feature learning during the training phase. A promising direction for future work would be incorporating DSMs directly into the optimization loop to explicitly guide the network to focus on specific, human-interpretable regions of interest.

Summary updated

Abstract

Deep neural decision forest (NDF) achieved remarkable performance on various vision tasks via combining decision tree and deep representation learning. In this work, we first trace the decision-making process of this model and visualize saliency maps to understand which portion of the input influence it more for both classification and regression problems. We then apply NDF on a multi-task coordinate regression problem and demonstrate the distribution of routing probabilities, which is vital for interpreting NDF yet not shown for regression problems. The pre-trained model and code for visualization will be available at https://github.com/Nicholasli1995/VisualizingNDF
BibTeX
@misc{li2019visualizing,
  author = {Shichao Li and Kwang-Ting Cheng},
  title = {{Visualizing the decision-making process in deep neural decision forest}},
  year = {2019},
  eprint = {1904.09201},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1904.09201},
}
Figure