TL;DR
This paper introduces Augmented Random Forest (ARF), a novel post-training defense against adversarial attacks that requires no retraining of the original deep neural network (DNN). ARF leverages test-time augmentations (TTAs) of input images and a random forest classifier to achieve state-of-the-art robustness, even against adaptive attacks, with minimal compromise on natural image accuracy.
What Problem Does This Paper Address?
Deep Neural Networks (DNNs) are highly susceptible to adversarial attacks, where small, imperceptible perturbations to input data can cause misclassifications. While adversarial training is a common defense, it requires computationally expensive retraining of the DNN, which can be a significant bottleneck, especially when new attacks emerge. Furthermore, many existing defenses require access to the original training data, which may not always be feasible due to privacy or proprietary concerns. This paper addresses the need for a simple, efficient, and data-agnostic defense that can be applied to already trained DNNs without modification.
Methods
The core of the proposed method, Augmented Random Forest (ARF), involves two main stages:
- Test-Time Augmentations (TTAs): For each input image, ARF generates a batch of augmented versions using a variety of randomized geometric, color, blur, and noise transformations. These transformations are designed to perturb the image in ways that are difficult for an adversary to anticipate and to enrich the input space.
- Random Forest Classifier: The original DNN processes these augmented images and outputs its "logits" (pre-softmax scores). These logits, representing the DNN's confidence for each class across the augmented inputs, are then fed into a simple random forest classifier. This random forest is trained once on the logits derived from both clean and adversarial TTAs. During inference, the random forest uses the aggregated logits from the TTAs to make the final, robust prediction.
The key novelty lies in using TTAs to create a richer input representation for a simple classifier, thereby avoiding DNN retraining and leveraging the DNN's existing capabilities.
Datasets
The authors evaluated their approach on four standard image classification datasets:
- CIFAR-10
- CIFAR-100
- SVHN (Street View House Numbers)
- Tiny ImageNet
Key Insights and Ideas
- Post-training robustness is achievable without retraining: The most significant insight is that a robust classifier can be built after a DNN has been trained, by augmenting its input at test time and using a simple ensemble-like approach with a random forest. This bypasses the major computational cost of adversarial training.
- TTAs as a rich feature source: The diverse set of randomized TTAs effectively creates a more robust representation of the input, making it harder for adversarial perturbations to consistently fool the system. The random forest learns to aggregate information from these augmented views.
- Logits are sufficient: The method only requires the DNN's logits, not the full model or the original training data, making it highly practical and privacy-preserving.
- Synergy with adversarial training: While ARF provides robustness on its own, combining it with an adversarially trained DNN (like TRADES or VAT) yields state-of-the-art results, demonstrating a powerful synergistic effect.
- Adaptive attacks are crucial for evaluation: The authors emphasize the importance of testing against adaptive attacks that are specifically designed to circumvent the proposed defense, which they also introduce (e.g., A-PGD).
Key Results
- State-of-the-art robustness: ARF consistently improves adversarial robustness across various datasets and attack types, often outperforming existing methods like VAT and TRADES when used alone.
- Minimal accuracy drop on clean images: ARF achieves high adversarial robustness with only a small compromise on the accuracy of clean (non-adversarial) images, often performing comparably to the original "plain" DNN.
- Effective against adaptive attacks: While ARF shows some vulnerability to white-box adaptive attacks (like BPDA) when used with a plain DNN, its robustness is significantly enhanced when combined with adversarially trained DNNs.
- Efficiency: The random forest training is a one-time, negligible cost compared to DNN retraining. Inference is fast, with the main computation being the TTA generation.
Limitations and Future Work
- Vulnerability to adaptive white-box attacks: The authors acknowledge that ARF can be susceptible to adaptive white-box attacks (specifically BPDA) when used with a non-adversarially trained DNN. However, they show that combining ARF with adversarial training (TRADES/VAT) significantly mitigates this.
- Visual perceptibility of BPDA attacks: Even when BPDA attacks fool ARF (especially the vanilla version), the generated adversarial images often exhibit visible distortions, making them easily detectable by humans. This suggests that while the attack might fool the model, it might not be truly imperceptible.
- Future work: The authors suggest that integrating ARF within adversarial training could further boost robustness, building on recent work on data augmentation. They also propose that ARF's architecture is flexible and can be used with other machine learning classifiers, although random forest performed best in their experiments. The ability to quickly retrain the random forest component could also be a defense against future adaptive attacks.
Summary updated