TL;DR
This paper introduces Augmented Random Forest (ARF), a novel post-training defense against adversarial attacks that enhances the robustness of pre-trained Deep Neural Networks (DNNs) without modifying their weights. By leveraging test-time augmentations and a random forest classifier on DNN logits, ARF achieves state-of-the-art adversarial robustness with minimal impact on natural image classification 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 lead to incorrect predictions. While adversarial training is a leading defense, it requires computationally expensive retraining of the DNN. Existing methods often necessitate access to the entire training dataset or complex retraining procedures, posing challenges for real-world deployment and adaptation to new attacks. This paper addresses the need for a simple, efficient, and flexible defense mechanism that can be applied to already trained DNNs without retraining.
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 multiple augmented versions using a diverse set of randomized transformations. These include color adjustments (brightness, contrast, saturation, hue, gamma), geometric transformations (rotation, translation, scaling, flipping), blur, and noise. The goal is to create a neighborhood around the original image that still contains enough information to recover the correct label, even if the adversary perturbs the original.
- Random Forest Classifier: The augmented images are fed through the pre-trained (and potentially non-robust) DNN. Instead of using the DNN's direct output, ARF collects the logits (raw, unnormalized scores before the softmax function) for each augmented image. These logits are then used to train a simple random forest classifier. The random forest learns to infer the true class label by considering the distribution of logits across the augmented inputs. This training is performed only once. During inference, the process is reversed: TTAs are generated, their logits are collected, and these are fed to the trained random forest for the final prediction.
The authors also introduce an adaptive attack called A-PGD, which averages gradients over augmented test-time samples, and explore the visual perceptibility of adversarial attacks against their defense.
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
- Robustness from Logit Distributions: The key insight is that the distribution of logits from a DNN across various augmentations of an image contains robust information that can be leveraged by a simpler classifier like a random forest. This bypasses the vulnerability of the original DNN's direct output.
- Post-Training Defense: ARF's ability to robustify a pre-trained DNN without retraining is a significant advantage, saving considerable computational resources and time. This makes it highly practical for deploying defenses on existing models.
- Simplicity and Flexibility: The method is described as simple and easy to use, requiring only the DNN's logits and a standard random forest implementation. This flexibility allows it to be applied with any classifier that outputs logits.
- TTAs as a Feature Enrichment: While TTAs have been used before, ARF uniquely uses them to enrich the input features for a downstream classifier, rather than relying on them alone for classification.
- Adaptive Attacks Reveal Limitations: The development of adaptive attacks (like A-PGD and BPDA) specifically targeting ARF highlights the ongoing arms race in adversarial robustness and the importance of evaluating defenses against tailored threats.
Key Results
- State-of-the-Art Robustness: ARF achieved state-of-the-art adversarial robustness on various white-box and black-box attacks, often outperforming existing methods like TRADES and VAT, especially when combined with an adversarially trained DNN.
- Minimal Impact on Natural Accuracy: ARF demonstrated minimal compromise on natural image classification accuracy, often performing comparably to the original "plain" DNN.
- Effective Against Adaptive Attacks: While ARF showed some vulnerability to adaptive white-box attacks (like BPDA), combining it with adversarially trained DNNs (TRADES/VAT) significantly improved robustness against these tailored threats.
- Visual Perceptibility: Adversarial images generated by BPDA against ARF were often visually perceptible, suggesting that while they might fool the model, they are not imperceptible to humans, thus limiting their practical threat.
- Computational Efficiency: The random forest training is negligible compared to DNN training, and inference is fast, with the main bottleneck being TTA generation.
Limitations and Future Work
- Vulnerability to Adaptive White-Box Attacks: The paper acknowledges that ARF, particularly when used with a vanilla DNN, is susceptible to adaptive white-box attacks like BPDA. However, combining ARF with adversarially trained DNNs significantly mitigates this vulnerability.
- TTA Generation Bottleneck: While inference is fast, the generation of TTAs can be computationally intensive, especially with a large number of augmentations (N). The authors explored the trade-off between N and robustness.
- Future Work: The authors suggest that integrating ARF within adversarial training could further boost robustness. They also highlight the potential for ARF to be favored over standalone adversarial training due to its simplicity and effectiveness, especially in non-white-box settings. The ability to easily retrain the random forest component allows for quick adaptation to new attacks.
Summary updated