## 4 K-Anonymity-Based SHFL
### Secure Hierarchical Distributed Architecture
#### 4.1.2 K-Anonymity-Based Regrouping of Anonymous Clusters of SHFL
Figure 4: Comparison of SHFL training accuracy and training loss for different numbers of LCs and ILCs in the MNIST dataset, (**a**) training accuracy over MNIST; (**b**) training loss over MNIST. Figure 5: Comparison of SHFL training accuracy and training loss for different numbers of LCs and ILCs on the CIFAR-10 dataset, (**a**) training accuracy over CIFAR-10; (**b**) training loss over CIFAR-10. To further prove the accuracy of the proposed SHFL, we used the healthcare dataset related to X-rays for COVID-19. The dataset was divided into three classes: COVID-19, Pneumonia, and No findings. We utilized the \(5\times 5\) convolution layer cross-validation procedure for both binary and triple classification problems. Twenty percent of the X-ray images were used for testing, and the remaining was used for training the model. As shown in Figure 6, we trained the LCs and ILCs for 100 local epochs and tested the accuracy of 200 communication rounds for three network topologies: {5 LCs and 5 ILCs}, {15 LCs and 5 ILCs}, and {15 LCs and 15 ILCs}. Different topologies provide different levels of fluctuations in terms of accuracy. The end clients of distributed learning can provide their X-ray data in real time and obtain an initial probabilistic diagnosis. These results are for initial examinations and are mainly applicable to medical professionals. In Figure 6, the overlapped confusion matrix (CM) is shown for the following network topologies: (a) {5 LCs and 5 ILCs}, (b) {15 LCs and 5 ILCs}, and (c) {15 LCs and 15 ILCs}. The overlapped confusion matrix was created using the sum of the client models of all the folds. The SHFL model utilized the AlexNet client model to classify the training and testing of the COVID-19 dataset. In the case of the network topology of {5 LCs and 5 ILCs}, the proposed SHFL achieved 93% accuracy for COVID-19 detection and 88% accuracy for normal or no findings. Similarly, we achieved 81% accuracy in pneumonia detection. In the case of the network topology of {15 LCs and 5 ILCs}, we achieved 96% accuracy for COVID-19 detection and recognition. The network topology of {15 LCs and 15 ILCs} is very dense but still maintains an accuracy of 93% for COVID-19 detection. We are currently training and testing our proposed SHFL framework for a healthcare application for COVID-19 detection and have achieved high accuracy. However, we note that our research is currently independent. COVID-19 detection is a sensitive research field, and thus far, we have utilized only simulation-based experiments on publicly available COVID-19 datasets. ### Comparison

We selected three schemes related to privacy preservation in FL for comparison with the proposed SHFL. The schemes selected for comparison are Efficient and Privacy-Preserving Federated Learning (EPPFL) [38], Federated Optimization (FedOpt) [27], and Extreme Boost Federated Learning (FedXGB) [39]. We compared the existing schemes with the proposed SHFL in terms of the training accuracy and expected loss. For comparison, we selected the MNIST dataset, as it is utilized in existing schemes. In addition, we used the same CNN architecture for all compared schemes. A random distribution divided the MNIST dataset into 25% for testing and 75% for training. The remaining parameters were set to the values given in Table 2. Figure 7 shows the training accuracy and expected loss with an increasing number of communication rounds. Figure 7a shows that the proposed SHFL

Figure 6: Overlapped and 5-fold confusion matrix results for (**a**) 5 LCs, 5 ILCs, (**b**) 15 LCs, 2 ILCs, and (**c**) 15 LCs, 5 ILCs. achieves 3%, 7%, and 9% greater accuracy than EPPFL, FedOpt, and FedXGB, respectively. Similarly, in Figure 7b, SHFL has less expected loss than EPPFL, FedOpt, and FedXGB by approximately 6%, 9%, and 12%, respectively. We attributed this performance to the hierarchical architecture of the proposed SHFL. In addition, the anonymity of LCs and ILCs enables the SHFL in securing higher performance. ## 6 Conclusions

This paper presented an SHFL framework for smart healthcare systems.