Parallel Secure Inference for Multiple Models Based on CKKS
摘要
Homomorphic encryption is utilized in machine learning to safeguard the privacy of user data and server’s model parameters. CKKS is a homomorphic scheme that supports complex computation and has better performance than BFV. This gives CKKS an advantage when applied to machine learning. However, existing secure inference frameworks based on homomorphic encryption are mainly adopted in BFV or BGV, as these schemes have more batching slots than CKKS. In this paper, we propose two parallel inference methods based on CKKS to enhance the batching capabilities (called parallelism) of CKKS, model parallelism and sample parallelism. The model parallelism is facilitative to inference of two models at the same time and improves inference performance. This is the main method to mitigate the parallelism gap between BFV and CKKS. Meanwhile, sample parallelism allows multiple samples to be inference simultaneously to decrease the number of decrypt operations and communication. Subsequently, we apply the two parallel techniques to phenotypic inference from genetic data. Experimental results show that our method improves the performance by at least 47.8% compared to the method without parallel techniques.