These codes are about "GradCAM-AE: A New Shield Defense Against Poisoning Attacks on Federated Learning"
Here is a structure of FL_GradCAM:
GradCAM-assisted defense against poisoning attacks on FL. The server arbitrarily selects an image (e.g., an image with the label "bird") from the global model testing dataset to create GradCAM heat maps for every uploaded local model update. These GradCAM heat maps flow into an autoencoder for malicious model detection.
Autoencoder-based abnormal GradCAM heat map identification. The server flattens and concatenates GradCAM heat maps as input to the encoder neural network, which compresses the GradCAM heat maps from a high dimension to a low dimension Z. The decoder neural network takes Z as its input to reconstruct the original input GradCAM heat maps.
- Install requirements via
pip install -r requirements.txt
Enter into each folder and run the following command:
python FL_GradCAM_main.py