Efficient and Encrypted Inference using Binarized Neural Networks within In-Memory Computing Architectures
Gokulnath Rajendran, Suman Deb, Anupam Chattopadhyay
TL;DR
This work tackles model protection for binarized neural networks deployed on crossbar-based in-memory computing by introducing PUF-derived secret-key transformations that yield protected weights and biases $W^*$ and $B^*$. The authors formalize a reversible framework with transformations $(\\Gamma_R, \\beta_R, \\delta_R, \\psi_R)$ ensuring the correct key preserves the output $Y = \\operatorname{sign}(W^\\top X - B)$, while omitting the key leads to drastic accuracy loss. They implement three transformation schemes (row/column inversion and swapping, plus a mixed row inversion with column swap) on MNIST with RRAM crossbars and demonstrate that encrypted inference incurs minimal runtime overhead and preserves performance when the key is available, but falls below 15% accuracy otherwise. The results indicate a practical, hardware-friendly approach to BNN privacy in in-memory computing and point to extensions to other activations and architectures to achieve privacy with lower costs than full FHE.
Abstract
Binarized Neural Networks (BNNs) are a class of deep neural networks designed to utilize minimal computational resources, which drives their popularity across various applications. Recent studies highlight the potential of mapping BNN model parameters onto emerging non-volatile memory technologies, specifically using crossbar architectures, resulting in improved inference performance compared to traditional CMOS implementations. However, the common practice of protecting model parameters from theft attacks by storing them in an encrypted format and decrypting them at runtime introduces significant computational overhead, thus undermining the core principles of in-memory computing, which aim to integrate computation and storage. This paper presents a robust strategy for protecting BNN model parameters, particularly within in-memory computing frameworks. Our method utilizes a secret key derived from a physical unclonable function to transform model parameters prior to storage in the crossbar. Subsequently, the inference operations are performed on the encrypted weights, achieving a very special case of Fully Homomorphic Encryption (FHE) with minimal runtime overhead. Our analysis reveals that inference conducted without the secret key results in drastically diminished performance, with accuracy falling below 15%. These results validate the effectiveness of our protection strategy in securing BNNs within in-memory computing architectures while preserving computational efficiency.
