Complex-Valued Neural Networks (CVNNs) have significant advantages in handling tasks that involve complex numbers. However, existing CVNNs are unable to quantify predictive uncertainty. We propose, for the first time, dropout-based Bayesian Complex-Valued Neural Networks (BayesCVNNs) to enable uncertainty quantification for complex-valued applications, exhibiting broad applicability and efficiency for hardware implementation due to modularity. Furthermore, as the dual-part nature of complex values significantly broadens the design space and enables novel configurations based on layer-mixing and part-mixing, we introduce an automated search approach to effectively identify optimal configurations for both real and imaginary components. To facilitate deployment, we present a framework that generates customized FPGA-based accelerators for BayesCVNNs, leveraging a set of optimized building blocks. Experiments demonstrate the best configuration can be effectively found via the automated search, attaining higher performance with lower hardware costs compared with manually crafted models. The optimized accelerators achieve approximately 4.5x and 13x speedups on different models with less than 10% power consumption compared to GPU implementations, and outperform existing work in both algorithm and hardware aspects. Our code is publicly available at: https://github.com/zehuanzhang/BayesCVNN.git.
翻译:复值神经网络(CVNN)在处理涉及复数的任务中具有显著优势。然而,现有CVNN无法量化预测不确定性。我们首次提出基于丢弃法的贝叶斯复值神经网络(BayesCVNN),以实现复数值应用的不确定性量化,该网络因其模块化特性而具有广泛适用性和硬件实现的高效性。此外,由于复数的双重部分特性显著扩展了设计空间,并催生了基于层混合与部分混合的新型配置,我们引入了一种自动搜索方法,以有效识别实部和虚部的最优配置。为促进部署,我们提出一个框架,利用一组优化构建模块为BayesCVNN生成基于FPGA的定制加速器。实验表明,通过自动搜索可有效找到最优配置,与手工设计的模型相比,在更低硬件成本下实现了更高性能。优化后的加速器在不同模型上相比GPU实现实现了约4.5倍和13倍的加速比,且功耗低于10%,在算法和硬件方面均优于现有工作。我们的代码已开源:https://github.com/zehuanzhang/BayesCVNN.git。