NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Fortified Networks: Improving the Robustness of Deep Networks by Modeling the Manifold of Hidden Representations

Alex Lamb, Jonathan Binas, Anirudh Goyal, Dmitriy Serdyuk, Sandeep Subramanian, Ioannis Mitliagkas, Yoshua BengioarXiv 2018

Introduction

Deep neural networks (DNNs) have achieved remarkable success across various domains, yet they remain susceptible to adversarial examples—small, intentionally crafted perturbations that lead to incorrect classifications. This vulnerability often stems from the model's failure to generalize outside the narrow "data manifold" of the training set. Adversarial attacks exploit the complex and often irregular decision boundaries in these off-manifold regions. While many defenses attempt to "clean" input pixels directly, this approach is computationally expensive and often fails on complex datasets.

Methodology: Fortified Layers

To address this, the authors propose Fortified Networks, which integrate Denoising Autoencoders (DAEs) directly into the hidden layers of a DNN. These "fortified layers" are designed to project perturbed hidden representations back onto the clean data manifold.

The DAE learns a vector field that maps off-manifold points back toward the high-density regions of the clean data manifold.

The fortification process involves passing a hidden layer's activations ($h_k$) through an encoder-decoder pair ($E_k, D_k$). The DAE is trained with a dual objective: minimizing standard classification loss and a reconstruction loss ($L_{rec}$) that ensures the DAE can recover clean hidden states from noisy or adversarial inputs. This mechanism allows the network to identify when internal representations have been pushed off the data manifold and map them back to a "clean" state.

The Advantage of Hidden Space Manifolds

A key insight of this work is that modeling the manifold in the hidden representation space is significantly more effective than doing so in the raw input space. As data propagates through the network, the representations become more abstract and statistically simpler.

Visualization of the hidden representation manifold (h), showing well-separated and structured clusters compared to the more complex input space.

The "flatter" nature of these hidden manifolds makes it easier for a compact DAE to distinguish between legitimate data and adversarial noise. Furthermore, the reconstruction error of the DAE serves as a reliable indicator of out-of-distribution or adversarial inputs, effectively acting as an "off-manifold" detection signal or "check engine light."

Experimental Evaluation

The effectiveness of Fortified Networks was validated on several benchmarks including MNIST, Fashion-MNIST, and CIFAR-10. Key results include:

  • CIFAR-10: Fortified Networks reached 81.80% accuracy against FGSM attacks, outperforming "Thermometer Encoding" (80.97%) and significantly beating input-space autoencoders (79.77%).
  • MNIST: Achieved 97.97% accuracy against FGSM, compared to 95.60% for standard adversarial training.
  • Black-box Robustness: The defense showed superior resistance to transfer attacks, reaching 97.82% on MNIST, proving it does not rely on gradient masking.

Conclusion

Fortified Networks offer a robust defense mechanism by leveraging the structured nature of hidden representations. By "decorating" internal layers with Denoising Autoencoders, the architecture can identify and correct adversarial perturbations before they lead to misclassification. While adding computational overhead, the synergy between fortification and adversarial training provides a promising path toward more reliable deep learning systems.

Summary updated

BibTeX
@misc{lamb2018fortified,
  author = {Alex Lamb and Jonathan Binas and Anirudh Goyal and Dmitriy Serdyuk and Sandeep Subramanian and Ioannis Mitliagkas and Yoshua Bengio},
  title = {{Fortified Networks: Improving the Robustness of Deep Networks by Modeling the Manifold of Hidden Representations}},
  year = {2018},
  eprint = {1804.02485},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1804.02485},
}
Figure