Paper 2024/2008

PrivCirNet: Efficient Private Inference via Block Circulant Transformation

Tianshi Xu, Peking University
Lemeng Wu, Meta, Inc.
Runsheng Wang, Peking University
Meng Li, Peking University
Abstract

Homomorphic encryption (HE)-based deep neural network (DNN) inference protects data and model privacy but suffers from significant computation overhead. We observe transforming the DNN weights into circulant matrices converts general matrix-vector multiplications into HE-friendly 1-dimensional convolutions, drastically reducing the HE computation cost. Hence, in this paper, we propose PrivCirNet, a protocol/network co-optimization framework based on block circulant transformation. At the protocol level, PrivCirNet customizes the HE encoding algorithm that is fully compatible with the block circulant transformation and reduces the computation latency in proportion to the block size. At the network level, we propose a latency-aware formulation to search for the layer-wise block size assignment based on second-order information. PrivCirNet also leverages layer fusion to further reduce the inference cost. We compare PrivCirNet with the state-of-the-art HE-based framework Bolt (IEEE S&P 2024) and HE-friendly pruning method SpENCNN (ICML 2023). For ResNet-18 and Vision Transformer (ViT) on Tiny ImageNet, PrivCirNet reduces latency by $5.0\times$ and $1.3\times$ with iso-accuracy over Bolt, respectively, and improves accuracy by $4.1\%$ and $12\%$ over SpENCNN, respectively. For MobileNetV2 on ImageNet, PrivCirNet achieves $1.7\times$ lower latency and $4.2\%$ better accuracy over Bolt and SpENCNN, respectively. Our code and checkpoints are available at https://github.com/Tianshi-Xu/PrivCirNet.

Metadata
Available format(s)
PDF
Category
Applications
Publication info
Published elsewhere. NeurIPS'24
Keywords
Privacy-Preserving Machine LearningHomomorphic EncryptionEncoding Algorithm
Contact author(s)
tianshixu @ stu pku edu cn
History
2024-12-12: approved
2024-12-12: received
See all versions
Short URL
https://ia.cr/2024/2008
License
Creative Commons Attribution-NonCommercial
CC BY-NC

BibTeX

@misc{cryptoeprint:2024/2008,
      author = {Tianshi Xu and Lemeng Wu and Runsheng Wang and Meng Li},
      title = {{PrivCirNet}: Efficient Private Inference via Block Circulant Transformation},
      howpublished = {Cryptology {ePrint} Archive, Paper 2024/2008},
      year = {2024},
      url = {https://eprint.iacr.org/2024/2008}
}
Note: In order to protect the privacy of readers, eprint.iacr.org does not use cookies or embedded third party content.