Paper 2024/648

Encrypted KNN Implementation on Distributed Edge Device Network

B Pradeep Kumar Reddy, Indian Institute of Technology Kharagpur
Ruchika Meel, Indian Institute of Technology Kharagpur
Ayantika Chatterjee, Indian Institute of Technology Kharagpur

Machine learning (ML) as a service has emerged as a rapidly expanding field across various industries like healthcare, finance, marketing, retail and e-commerce, Industry 4.0, etc where a huge amount of data is gen- erated. To handle this amount of data, huge computational power is required for which cloud computing used to be the first choice. However, there are several challenges in cloud computing like limitations of bandwidth, network connectivity, higher latency, etc. To address these issues, edge computing is prominent nowadays, where the data from sensor nodes is collected and processed on low-cost edge devices. As simple sensor nodes are not capable of handling complex computations of ML models, data from sensor nodes need to be transferred to some nearest edge devices for further processing. If this sensor data is related to some security- critical application, the privacy of such sensitive data needs to be preserved both during communication from sensor node to edge device and computation in edge nodes. This increased need to perform edge-based ML on privacy-preserved data has led to a surge in interest in homomorphic encryption (HE) due to its ability to perform computations on encrypted form of data. The highest form of HE, Fully Homomorphic Encryption (FHE), is capable of theoretically handling arbitrary encrypted algorithms but comes with huge computational overhead. Hence, the implementation of such a complex encrypted ML model on a single edge node is not very practical in terms of latency requirements. Our paper introduces a low-cost encrypted ML framework on a distributed edge cluster, where multiple low-cost edge devices (Raspberry Pi boards) are clustered to perform encrypted distributed K-Nearest Neighbours (KNN) algorithm computations. Our experimental result shows, KNN prediction on standard Wisconsin breast cancer dataset takes approximately 1.2 hours, implemented on a cluster of six pi boards, maintaining end-to-end data confidentiality of critical medical data without any re- quirement of costly cloud-based computation resource support

Note: Extended version of Accepted paper in SECRYPT 2024

Available format(s)
Publication info
Contact author(s)
pradeepkumarreddy bukka @ gmail com
ruchikasingh758 @ gmail com
cayantika @ gmail com
2024-04-29: approved
2024-04-28: received
See all versions
Short URL
Creative Commons Attribution-NonCommercial


      author = {B Pradeep Kumar Reddy and Ruchika Meel and Ayantika Chatterjee},
      title = {Encrypted {KNN} Implementation on Distributed Edge Device Network},
      howpublished = {Cryptology ePrint Archive, Paper 2024/648},
      year = {2024},
      note = {\url{}},
      url = {}
Note: In order to protect the privacy of readers, does not use cookies or embedded third party content.