  Today's robots often interface with data-driven perception and planning
models with classical model-predictive controllers (MPC). Often, such learned
perception/planning models produce erroneous waypoint predictions on
out-of-distribution (OoD) or even adversarial visual inputs, which increase
control costs. However, today's methods to train robust perception models are
largely task-agnostic - they augment a dataset using random image
transformations or adversarial examples targeted at the vision model in
isolation. As such, they often introduce pixel perturbations that are
ultimately benign for control. In contrast to prior work that synthesizes
adversarial examples for single-step vision tasks, our key contribution is to
synthesize adversarial scenarios tailored to multi-step, model-based control.
To do so, we use differentiable MPC methods to calculate the sensitivity of a
model-based controller to errors in state estimation. We show that re-training
vision models on these adversarial datasets improves control performance on OoD
test scenarios by up to 36.2% compared to standard task-agnostic data
augmentation. We demonstrate our method on examples of robotic navigation,
manipulation in RoboSuite, and control of an autonomous air vehicle.
