liveBook · Manning

Adversarial input

As explained in Deep Learning with Python, Third Edition

Inputs intentionally or effectively perturbed to cause a model to make a wrong prediction despite minimal change to the original example.

An adversarial example is an input changed just enough to make a deep learning model misclassify it. The change may be nearly invisible to people while radically altering the model’s prediction, exposing a gap between machine and human perception. section 19.1.2

Turning a panda into a gibbon

Starting with a panda photograph, apply gradient ascent in input space to increase the network’s prediction for the gibbon class. The resulting image still looks like a panda to people, but the network classifies it as a gibbon. section 19.1.2

Practical takeaways:

  • Treat high confidence as potentially brittle: small input changes can produce a different prediction. section 19.1.2
  • Do not confuse humanly minor changes with modelically minor changes; the two systems may respond very differently to the same image. section 19.1.2

How Deep Learning with Python, Third Edition covers it

How deep it goes
Explains the gradient-ascent mechanism and a panda-to-gibbon example, without detailing attack algorithms or defenses.
Examples
Uses a panda image modified toward the gibbon class and a figure illustrating imperceptible classification-changing perturbations.
What it assumes
Assumes familiarity with deep learning models and gradient ascent, while illustrating the vulnerability through a concrete image example.
What you can do after
Evaluate/understand how small input perturbations can cause confident model misclassification.
How it connects
Connects adversarial examples with gradient ascent, convolutional neural networks, image classification, and human perception.

Also explained in

Compare how 5 books explain adversarial input →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Deep Learning with Python, Third Edition. The section links point to the parts of the book it draws on.