Some attacks on image classifiers change only a handful of pixels, sometimes fewer than 1% of them, but are allowed to set those pixels to any value. These are called sparse attacks. They model stickers on road signs or dead camera pixels. Training a network to resist them is expensive. The standard defense, adversarial training, retrains the model on attacked inputs. The hard part of building each sparse attack is deciding which pixels to change, and that is a combinatorial search, not a smooth optimization. Doing the search well takes many forward and backward passes per training image. Doing it cheaply in one step makes training collapse: the model learns to resist only the weak attack's poor choice of pixels, a failure called catastrophic overfitting (Fast Adversarial Training against Sparse Attacks Requires Loss Smoothing).
We propose to stop redoing that search from scratch at every step. Each training image keeps a small memory of which pixels its current attack uses. That memory carries over from one epoch to the next, and each training step spends a single gradient pass both adjusting the stored pixel values and swapping a few weak locations for better ones. Over many epochs, a one-step-per-iteration budget adds up to a long, many-step search over locations. The bet is that pixel locations stay good attack choices as the model slowly changes, just as whole dense perturbations do. Dense perturbations have been shown to carry over this way, a property called temporal transferability (Efficient Adversarial Training With Transferable Adversarial Examples).
Core Claim
Catastrophic overfitting in fast sparse adversarial training is mainly a location-search failure. Zhong et al. show this with a Hessian analysis of the jagged sparse loss surface and with the observation that one-step attacks pick poor coordinates. A location failure should be fixable by accumulating the location search across epochs, not only by smoothing the loss. Concretely, we claim that a per-example memory of attack locations, updated by one gradient pass plus a few coordinate swaps per iteration, gives two things at one-step cost. First, it reaches robust accuracy under Sparse-AutoAttack matching or exceeding 20-step sparse training. Second, combined with loss smoothing, it beats the best fast method on robust accuracy at matched wall-clock time.
The idea differs from ATTA, which recycles dense $\ell_\infty$/$\ell_2$ perturbation vectors and maps them through augmentations with a geometric "connection function". What we carry across epochs is a discrete support set, meaning the list of pixel positions the attack is allowed to change. Our memory also has an explicit swap step to keep it from going stale. The research file flags one obstacle to ATTA-style recycling for sparse attacks: remapping a few surgical pixels through augmentations might blur them through interpolation. That problem disappears if the memory is stored in original-image coordinates and training uses only integer-shift crops and flips. Those augmentations map pixel indices exactly. Stored pixels that fall outside the crop are simply replaced.
Research Program
For each training image $i$ we store a support set $S_i$ of $k$ pixel positions, together with their perturbation values $p_i$. Here $k$ is the sparsity budget, and each value may span the full pixel range. At each iteration, the stored attack is mapped into the augmented view, and one forward and backward pass computes the input gradient $g$.
The values on $S_i$ are updated by a single signed step and then clipped to valid pixel range. Each pixel $j$ in the image gets a score $s_j$, estimated to first order as the loss gain from moving pixel $j$ to its best extreme value. The $r_t$ lowest-scoring members of $S_i$ are then swapped for the $r_t$ highest-scoring pixels outside it. The swap count $r_t$ decays over training on a piecewise-constant schedule, borrowed from the schedule that makes random search effective for sparse attacks in Sparse-RS. The model is then trained on the updated attacked image.
The per-iteration cost matches one-step training. Memory cost is $k$ indices and values per image, which is negligible on CIFAR-10 and ImageNet-100.
Before building the full method, we will measure whether sparse locations actually carry over from one epoch to the next. We take checkpoints of a standard sparse adversarial training run. For each epoch we compute the strong sPGD attack's support set on a held-out subset of training images. We then measure two things at the next checkpoint: how much of that support survives, and how much attack loss the old support retains. If locations turn over almost completely each epoch, the premise fails and we stop.
The main risk is the one the file names: accumulated memory may lock the model onto outdated coordinates. The model could then learn to defend exactly the remembered pixels, which would be catastrophic overfitting in a new form. We will track this during training by periodically running the full attack suite on a fixed validation batch, and by logging the overlap between remembered supports and freshly searched ones.
Baselines
The naive reference point is plain one-step sparse adversarial training with a fresh one-step attack every iteration and no smoothing. It is expected to collapse. Running it under our code and budget confirms that the collapse, as reported by Zhong et al., reproduces in our setup.
The strongest existing method is Fast-LS-$\ell_0$ from Fast Adversarial Training against Sparse Attacks Requires Loss Smoothing. It is one-step sparse training stabilized by three loss-smoothing tricks: soft labels, a TRADES-style trade-off loss, and N-FGSM noise augmentation. It is the strongest competitor because it already solves the collapse at one-step cost. On CIFAR-10 it reports 63.0% robust accuracy against Sparse-AutoAttack in 0.8 GPU hours. The 20-step baseline reaches 61.7% in 5.5 hours. On ImageNet-100 it reports 72.4% robust accuracy against sparse attacks.
We will rerun it with the authors' settings: same architecture, same sparsity budget, same epochs and augmentations, on the same GPU type. We then compare three configurations at matched wall-clock time: our memory alone, Fast-LS-$\ell_0$ alone, and Fast-LS-$\ell_0$ with our memory added. Hyperparameters get an equal tuning budget, meaning the same number of configurations tried on a validation split. Beating it means higher Sparse-AutoAttack robust accuracy than our reproduction of Fast-LS-$\ell_0$, averaged over three seeds with non-overlapping spread, at no more than 1.2 times its training time.
The expensive upper reference is multi-step sparse adversarial training (sAT and sTRADES) from Sparse-PGD. No reported result on CIFAR-10 or ImageNet-100 was found on Lacuna for this paper, so we will train it ourselves. The 61.7% figure above, from a 20-step baseline, is the only anchor we have.
Two ablations isolate the key ingredient. The first keeps everything except cross-epoch memory: the support is re-drawn at random each iteration, with the same swap step and one gradient pass. This separates "accumulated location search" from "a random starting mask", which is the kind of noise N-FGSM already supplies. The second keeps the memory but turns off swaps, which tests whether frozen remembered locations cause the lock-in failure.
Why not just…?
Why not just use Fast-LS-$\ell_0$, which already works? This is the real threat. It already beats 20-step training at 7× less cost, so our method could turn out redundant. Zhong et al. treat the problem as a rough loss surface and smooth it. They also diagnose location choice as the cause, and smoothing does not add any search over locations. If the combined configuration does not beat Fast-LS-$\ell_0$ alone, and memory alone does not match it, then location memory adds nothing, and the matched-time comparison will show this directly. A partial win also counts as a result: memory might match Fast-LS-$\ell_0$ without the soft labels and TRADES loss. That matters because Sparse-PGD reports that TRADES-regularized models can mask gradients.
Why not just train on perturbations from a fast feed-forward generator such as TSAA or EGS-TSSA? These are networks trained to emit sparse attacks in milliseconds (Transferable Sparse Adversarial Attack; Transferable Structural Sparse Adversarial Attack Via Exact Group Sparsity Training). But they were trained against fixed, undefended models, and nothing in the file shows they keep up as the defended model changes. Keeping the generator current would reintroduce an inner training loop, which is exactly the cost we are trying to remove. We will run a frozen-generator variant as a secondary comparison at matched time. We expect it to fall short, but that expectation is untested.
Why not just train on Sparse-RS attacks, since random search is the strongest sparse attack? Sparse-RS needs a median of 25 to 429 queries per image in its own experiments (Sparse-RS). That makes it far too slow to run inside every training step. Our swap step can be read as spreading a random-search-style location search across epochs instead of running it all within each step.
Why not just use dense adversarial training, or randomized ablation at test time? Dense training bounds each pixel change to small values, so it does not cover full-range pixel changes. Randomized ablation, which certifies robustness by voting over many predictions on randomly masked copies of the input (Robustness Certificates for Sparse Adversarial Attacks by Randomized Ablation), costs many forward passes per prediction. Its authors describe its gains on CIFAR-10 as less pronounced.
Proposed Experiments
The first experiment is the support-persistence diagnostic on CIFAR-10 described above. It decides whether the program continues.
The main experiment trains all baselines, ablations, and our method on CIFAR-10 and ImageNet-100. We report four things: clean accuracy, robust accuracy under Sparse-AutoAttack (white-box sPGD combined with black-box Sparse-RS, from Sparse-PGD), wall-clock training time, and training curves of robust accuracy to expose late collapse.
The third experiment turns the transferability lens into a check for false robustness. We train TSAA and EGS-TSSA generators on independently trained surrogate models and apply their sparse attacks to every defended model. This matters because loss smoothing and TRADES-style losses can make white-box attacks fail without real robustness. If a defense beats Sparse-AutoAttack but falls to attacks transferred from a surrogate, its gradients are being masked, and that would reorder our comparison.
The decisive outcome is clear-cut. Fast-LS-$\ell_0$ plus memory should exceed our Fast-LS-$\ell_0$ reproduction under Sparse-AutoAttack and should not lose more to transferred attacks. The first ablation, random re-drawn masks, should fall between plain one-step training and full memory. That ordering is what would tie the gain to accumulated location search rather than to added randomness.
References
- Fast Adversarial Training against Sparse Attacks Requires Loss Smoothing
- Efficient Adversarial Training With Transferable Adversarial Examples
- Sparse-RS: A Versatile Framework for Query-Efficient Sparse Black-Box Adversarial Attacks
- Sparse-PGD: A Unified Framework for Sparse Adversarial Perturbations Generation
- Transferable Sparse Adversarial Attack
- Transferable Structural Sparse Adversarial Attack Via Exact Group Sparsity Training
- Robustness Certificates for Sparse Adversarial Attacks by Randomized Ablation