Deep neural network (DNN) typically involves convolutions, pooling, and activation function. Due to the growing concern about privacy, privacy-preserving DNN becomes a hot research topic. Generally, the convolution and pooling operations can be supported by additive homomorphic and secure comparison, but the secure implementation of activation functions is not so straightforward for the requirements of accuracy and efficiency, especially for the non-linear ones such as exponential, sigmoid, and tanh functions. This paper pays a special attention to the implementation of such non-linear functions in semi-honest model with two-party settings, for which SIRNN is the current state-of-the-art. Different from previous works, we proposed improved implementations for these functions by using their intrinsic features as well as worthy tiny tricks. At first, we propose a novel and efficient protocol for exponential function by using a divide-and-conquer strategy with most of the computations executed locally. Exponential protocol is widely used in machine learning tasks such as Poisson regression, and is also a key component of sigmoid and tanh functions. Next, we take advantage of the symmetry of sigmoid and Tanh, and fine-tune the inputs to reduce the 2PC building blocks, which helps to save overhead and improve performance. As a result, we implement these functions with fewer fundamental building blocks. The comprehensive evaluations show that our protocols achieve state-of-the-art precision while reducing run-time by approximately 57%, 44%, and 42% for exponential (with only negative inputs), sigmoid, and Tanh functions, respectively.
翻译:深度神经网络(DNN)通常包含卷积、池化和激活函数操作。随着隐私问题的日益关注,隐私保护型DNN已成为研究热点。通常,卷积和池化操作可通过加法同态加密和安全比较实现,但激活函数的安全实现因精度和效率要求而并非易事,特别是对于指数函数、sigmoid函数和tanh函数等非线性函数。本文重点研究半诚实模型下两方设置中这类非线性函数的实现方法——当前最先进的方案是SIRNN。与现有工作不同,我们利用这些函数的内在特性及巧妙技巧提出了改进型实现方案。首先,我们采用分治策略提出一种新颖高效的指数函数协议,其中大部分计算在本地执行。该指数协议广泛应用于泊松回归等机器学习任务,同时也是sigmoid和tanh函数的核心组件。其次,我们利用sigmoid和tanh的对称性,通过输入微调减少安全两方计算(2PC)基础模块数量以降低开销并提升性能。最终,我们使用更少的基础模块实现了这些函数。综合评估表明,我们的协议在达到当前最优精度的同时,对指数函数(仅负输入)、sigmoid函数和tanh函数的运行时间分别降低了约57%、44%和42%。