Performance Comparison of Homomorphic Encrypted Convolutional Neural Network Inference Among HElib, Microsoft SEAL and OpenFHE
Hao-Yun Zhu, Takuya Suzuki, Hayato Yamana · 2023
Homomorphic encryption (HE) offers a promising solution for maintaining data privacy even during calculation, as it allows for the evaluation of ciphertexts. Several HE libraries have been released, but selecting the best-suited library for HE beginners can be challenging. This paper provides insights into the selection process by comparing three popular HE libraries: HElib, Microsoft SEAL, and OpenFHE. To evaluate the performance of these libraries, we implemented a convolutional neural network inference using each of the three libraries and analyzed its latency. Our experimental results show that Microsoft SEAL achieves the shortest latency, less than 56% of OpenFHE and less than 17% of HElib. In terms of ease of use, OpenFHE surpasses the other libraries because it eliminates the need for programmers to consider rescaling during calculations and has more choices on different key-switching algorithms. In contrast, utilizing automatic rescaling with OpenFHE results in 5x longer latency than manual rescaling.