Ray-Tracing for Conditionally Activated Neural Networks
Claudio Gallicchio, Giuseppe Nuti
TL;DR
RayTracing addresses the computational cost of large Mixture of Experts models by proposing a hierarchical MoE architecture where blocks are activated via a thresholded firing rate $r^{(i)}$ and a network-wide threshold $\theta$ that is progressively lowered to unfold the architecture. Each block computes $\mathbf{s}^{(i)} = \text{ReLU}(r^{(i)} - \theta)\; \text{Softmax}(\mathcal{F}^{(i)}(\mathbf{z}^{(i)}))$, and backpropagation proceeds through the activated paths, enabling path-specific training. The approach yields competitive accuracy with substantial parameter reductions (over 50% on average) on datasets including CIFAR-10, without requiring auxiliary load-balancing penalties, and reveals that more difficult inputs activate more network blocks. This work has practical implications for efficient, real-time inference in time-sensitive domains and suggests avenues for hardware-friendly scalable conditional computation. It also opens potential extensions to sequence learning and reservoir/state-space approaches for further efficiency gains.
Abstract
In this paper, we introduce a novel architecture for conditionally activated neural networks combining a hierarchical construction of multiple Mixture of Experts (MoEs) layers with a sampling mechanism that progressively converges to an optimized configuration of expert activation. This methodology enables the dynamic unfolding of the network's architecture, facilitating efficient path-specific training. Experimental results demonstrate that this approach achieves competitive accuracy compared to conventional baselines while significantly reducing the parameter count required for inference. Notably, this parameter reduction correlates with the complexity of the input patterns, a property naturally emerging from the network's operational dynamics without necessitating explicit auxiliary penalty functions.
