Capsule Network is powerful at defining the positional relationship between features in deep neural networks for visual recognition tasks, but it is computationally expensive and not suitable for running on mobile devices. The bottleneck is in the computational complexity of the Dynamic Routing mechanism used between the capsules. On the other hand, XNOR-Net is fast and computationally efficient, though it suffers from low accuracy due to information loss in the binarization process. To address the computational burdens of the Dynamic Routing mechanism, this paper proposes new Fully Connected (FC) layers by xnorizing the linear projection outside or inside the Dynamic Routing within the CapsFC layer. Specifically, our proposed FC layers have two versions, XnODR (Xnorize the Linear Projection Outside Dynamic Routing) and XnIDR (Xnorize the Linear Projection Inside Dynamic Routing). To test the generalization of both XnODR and XnIDR, we insert them into two different networks, MobileNetV2 and ResNet-50. Our experiments on three datasets, MNIST, CIFAR-10, and MultiMNIST validate their effectiveness. The results demonstrate that both XnODR and XnIDR help networks to have high accuracy with lower FLOPs and fewer parameters (e.g., 96.14% correctness with 2.99M parameters and 311.74M FLOPs on CIFAR-10).
翻译:胶囊网络在视觉识别任务中能够有效定义深度神经网络中特征之间的位置关系,但其计算成本高昂,不适合在移动设备上运行。其瓶颈在于胶囊间动态路由机制的计算复杂度。另一方面,XNOR-Net虽然计算速度快且效率高,但由于二值化过程中的信息损失导致准确率较低。为解决动态路由机制的计算负担,本文通过对CapsFC层中动态路由外部或内部的线性投影进行异或化处理,提出了新的全连接层。具体而言,我们提出的全连接层有两个版本:XnODR(对动态路由外部的线性投影进行异或化)和XnIDR(对动态路由内部的线性投影进行异或化)。为测试XnODR和XnIDR的泛化能力,我们将它们分别插入MobileNetV2和ResNet-50两种不同网络。在MNIST、CIFAR-10和MultiMNIST三个数据集上的实验验证了其有效性。结果表明,XnODR和XnIDR均能使网络在保持较高准确率的同时,降低FLOPs和参数量(例如,在CIFAR-10上准确率达96.14%,参数量为2.99M,FLOPs为311.74M)。