TARO: Temporal Adversarial Rectification Optimization Using Diffusion Models as Purifiers

Daniel Wesego, Pedram RooshenasarXiv 2026

TL;DR

TARO (Temporal Adversarial Rectification Optimization) is a novel test-time adversarial purification method that treats diffusion noise scales as "temporal experts." By aggregating global structure from high-noise views with fine semantic details from low-noise ones, TARO achieves state-of-the-art robustness against adaptive attacks while maintaining high clean accuracy in a zero-shot setting.

What Problem Does This Paper Address?

Deep neural networks are notoriously fragile to adversarial examples—small, calculated perturbations that flip a model's prediction. While Adversarial Training (AT) is the standard defense, it is computationally expensive and often fails against attack types not seen during training.

Adversarial Purification (AP) offers a more flexible alternative: instead of hardening the classifier, we use a generative model (like a diffusion model) to "purify" the input, mapping it back to the natural image manifold before classification. However, standard diffusion purifiers face a "robustness-fidelity tension":

  • High-noise denoising removes strong adversarial artifacts but often destroys class-relevant details or causes "semantic drift."
  • Low-noise denoising preserves details but may leave adversarial structures intact.

Furthermore, many recent purification defenses have been shown to provide a false sense of security because they are evaluated against "non-adaptive" attacks that fail to differentiate through the defense's stochastic or optimization-based components.

Methods

The authors introduce TARO, which casts purification as a test-time optimization problem. Unlike previous methods that rely on a single noise level, TARO treats different diffusion timesteps as scale-dependent experts.

Key Innovations:

  1. Temporal Product-of-Experts (PoE): TARO builds a prior by aggregating scores from multiple denoising views along the diffusion trajectory.
  2. Affine Temporal Aggregation: Instead of a simple average, TARO uses an affine extrapolation (controlled by a guidance strength parameter $\gamma$). This allows the model to use the discrepancy between a coarse (high-noise) expert and a fine (low-noise) expert as a rectification signal.
  3. Expert Consistency Regularization: To stabilize the process, especially against $\ell_2$ attacks, the authors add a loss term that encourages different temporal experts to agree on the final purified estimate.
  4. Optimization-Aware Evaluation: The paper emphasizes a rigorous evaluation protocol. They highlight that attackers must differentiate through the entire inner optimization loop (preserving higher-order gradients) to avoid "accidental gradient masking."

The method can be used zero-shot (using only a pretrained diffusion model) or as a hybrid (TARO-AA) by combining it with learned adversary-aware residual models like AAOpt.

Datasets

The authors evaluated TARO across several standard benchmarks:

  • CIFAR-10 & CIFAR-100: Standard small-image classification benchmarks.
  • CIFAR-10-C: Used to test robustness against common non-adversarial corruptions (e.g., noise, blur).
  • Imagenette: A higher-resolution subset of ImageNet to demonstrate scalability to more complex image distributions.

Key Insights and Ideas

  • The "Aha" Moment: Different noise regimes provide complementary information. High-noise experts are "globally aware" and less sensitive to adversarial noise, while low-noise experts are "locally grounded." Combining them via affine extrapolation effectively "sharpens" the purification target.
  • Guidance as Correction: The parameter $\gamma$ acts similarly to Classifier-Free Guidance (CFG) but in a temporal sense. It amplifies the "clean" signal found by the coarse expert while using the fine expert to keep the image semantically accurate.
  • The Gradient Masking Trap: The authors show that ignoring the Jacobian of the inner purification loop leads to severely inflated robustness estimates. They demonstrate this by "breaking" a recent defense (CLIPure), which drops from ~90% reported robust accuracy to 0% under proper evaluation.

Key Results

TARO consistently outperforms both traditional adversarial training and existing purification baselines.

  • State-of-the-Art $\ell_\infty$ Robustness: On CIFAR-10, TARO-3 achieves 88.57% robust accuracy under PGD-EOT-20, significantly higher than standard Adversarial Training (~66%) and prior purification methods.
Table 2: Standard and robust accuracy on CIFAR-10 using WRN-28-10 under PGD-EOT-20. Base- lines include adversarial training (AT), adversarial purification, and test-time optimization purification.
  • Scaling to CIFAR-100: In more challenging settings, the hybrid TARO-3-AA variant reaches 72.41% robust accuracy, showing that temporal multi-scale signals provide a stronger optimization target than single-scale guidance.
Table 4: BPDA+EOT attack on CIFAR-100 un- der ℓ∞perturbations (ϵ = 8/255), WRN-28-10.
  • Resilience to Perceptual Attacks: Against DiffBreak (a low-frequency attack that collapses standard diffusion purifiers to 0% accuracy), TARO-2-AA maintains a robust accuracy of 90.10%.
  • Ablation on $\gamma$: The authors found that a moderate guidance strength ($\gamma \approx 1.4$ to $1.5$) is optimal. Too low, and the image becomes blurry; too high, and the optimization becomes unstable.
Table 1: Guidance-strength and consistency ablation for TARO-2 on CIFAR-10 using WRN-28-10 under PGD-EOT-20. We report clean accuracy and robust accuracy under ℓ∞and ℓ2 attacks.

Limitations and Future Work

  • Computational Cost: Because TARO involves an iterative optimization loop and evaluates multiple experts at each step, it is slower than a standard forward pass. The authors note a modest increase in runtime (e.g., 1.38s vs 1.05s for AAOpt).
  • Hyperparameter Tuning: The optimal guidance strength $\gamma$ and consistency weights can vary depending on the threat model ($\ell_\infty$ vs. $\ell_2$).
  • Empirical Defense: Like all purification methods, TARO is an empirical defense and does not provide formal "certified" robustness guarantees.
  • Future Directions: The authors suggest that automatically selecting temporal weights and stabilization strengths based on the input could further improve performance and ease of use.

Summary updated

BibTeX
@misc{wesego2026taro,
  author = {Daniel Wesego and Pedram Rooshenas},
  title = {{TARO: Temporal Adversarial Rectification Optimization Using Diffusion Models as Purifiers}},
  year = {2026},
  eprint = {2605.08440},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2605.08440},
}
Figure