Source-linked AI summary

PixMix: Dreamlike Pictures Comprehensively Improve Safety Measures

Dan Hendrycks, Andy Zou, Mantas Mazeika, Leonard Tang, Bo Li, Dawn Song, Jacob Steinhardt

arXiv:2112.05135v3cs.LGcs.CV

TL;DR

The paper asks whether one model can improve multiple machine-learning safety measures without trading performance on one axis for another. It introduces PIXMIX, an augmentation strategy using structurally complex dreamlike pictures such as fractals and feature visualizations. Across CIFAR and ImageNet evaluations, PIXMIX is reported to substantially improve safety measures and achieve a Pareto improvement over the baseline.

  • Problem

    Prior methods often improve some safety measures while harming others, raising whether all safety measures can be improved with a single model.

  • Method

    PIXMIX is a data augmentation pipeline that introduces structurally complex dreamlike pictures, including fractals and feature visualizations, into training.

  • Results

    PIXMIX substantially improves existing safety measures across numerous tasks, provides a Pareto improvement over the baseline, and achieves state-of-the-art performance in nearly all settings.

  • Takeaways & Limitations

    Feature visualizations are a suitable source of complexity for safety-oriented augmentation and have uses beyond interpretability.

Abstract

from arXiv · show

In real-world applications of machine learning, reliable and safe systems must consider measures of performance beyond standard test set accuracy. These other goals include out-of-distribution (OOD) robustness, prediction consistency, resilience to adversaries, calibrated uncertainty estimates, and the ability to detect anomalous inputs. However, improving performance towards these goals is often a balancing act that today's methods cannot achieve without sacrificing performance on other safety axes. For instance, adversarial training improves adversarial robustness but sharply degrades other classifier performance metrics. Similarly, strong data augmentation and regularization techniques often improve OOD robustness but harm anomaly detection, raising the question of whether a Pareto improvement on all existing safety measures is possible. To meet this challenge, we design a new data augmentation strategy utilizing the natural structural complexity of pictures such as fractals, which outperforms numerous baselines, is near Pareto-optimal, and roundly improves safety measures.

1. Introduction

Machine-learning safety spans robustness, consistency, adversarial resilience, calibrated uncertainty, and anomaly detection, but prior methods often improve one property while harming another. PIXMIX addresses this trade-off by using structurally complex pictures in augmentation and reports broad safety gains.

  • Reported contribution: PIXMIX is the only method shown in Figure 1 to significantly outperform the baseline across all five model safety measures.The figure reports normalized performance across five measures.
  • Motivation: Prior methods often improve selected safety properties while degrading others, making simultaneous improvement across all measures an open question.Examples include adversarial training harming classification performance and consistency improvements conflicting with OOD detection.
  • Motivation: Structural complexity, rather than only entropy or descriptive difficulty, is proposed as an underexplored axis for designing safety-oriented augmentations.Fractals are presented as a classic example of structurally complex objects.
  • PIXMIX: PIXMIX incorporates structurally complex “dreamlike” pictures, including fractals and feature visualizations, into a data-processing pipeline.The method is described as simple and effective and is intended to introduce new complexity during training.
  • Reported contribution: PIXMIX is reported to provide substantial gains across a broad range of existing safety measures while outperforming numerous previous methods.The paper states that feature visualizations are useful sources of complexity beyond interpretability.

2. Related Work

Related work studies robustness, calibration, anomaly detection, and augmentation separately or with mixed effects across safety goals. PIXMIX builds on structurally complex image sources and randomized mixing operations to pursue improvements across multiple measures.

  • Robustness: OOD robustness benchmarks evaluate resistance to corruption and perturbation shifts, while prior augmentations can improve OOD generalization at the cost of weaker OOD detection.ImageNet-C and ImageNet-P are described as held-out robustness evaluations, and CIFAR-10-C is a related variant.
  • Calibration: Calibration methods target reliable prediction confidences, while models are markedly less calibrated under distribution shift.Existing approaches include validation sets, ensembling, and pretraining.
  • Anomaly detection: Anomaly detection estimates whether an input is OOD relative to a training set, with prior methods using confidence branches, generated images, Mahalanobis distance, and diverse natural anomalies.Outlier Exposure is identified as a state-of-the-art method tested in the paper.
  • Data augmentation: Data augmentation improves robustness and can provide benefits comparable to much larger models or labeled datasets, motivating techniques such as Cutout, Mixup, CutMix, AutoAugment, and AugMix.The passage reports comparisons to a 10× increase in model size for clean accuracy and a 1,000× increase in labeled data for OOD robustness.
  • PIXMIX design: PIXMIX uses randomly selected mixing rounds, images from a mixing set or augmented clean images, and additive or multiplicative mixing operations.The implementation also applies randomly selected standard image augmentations such as rotation, solarization, and posterization.
  • Safety goals simultaneously: Prior methods, including augmentation, adversarial training, and pretraining approaches, have mixed effects across safety metrics or require task-specific modifications.The related work motivates a single method that improves performance across multiple safety metrics.
  • Complex synthetic images: The mixing set emphasizes fractals and feature visualizations because they provide structurally complex visual content beyond entropy-maximizing noise.These sources are collected from manually curated online sources and are contrasted with prior synthetic image distributions.

3. Approach

PIXMIX combines structurally complex pictures, especially fractals and feature visualizations, with a pipeline that repeatedly mixes them into clean training images. The approach is designed to improve multiple ML Safety measures simultaneously while retaining accuracy.

  • Picture Sources (PIX): PIXMIX integrates structurally complex patterns from fractals and feature visualizations into the training set.These picture sources are collectively treated as useful complex-structure inputs for augmentation.
  • Evaluation: The method is evaluated across corruption and rendition robustness, prediction consistency, confidence calibration, and anomaly detection.These tasks include ImageNet-C, ImageNet-R, and ImageNet-P, which assess distinct safety behaviors.
  • Picture Sources (PIX): Fractals provide visually diverse, highly non-accidental structures, while feature visualizations maximize neuron responses and often have high complexity.The authors collect 14,230 fractals and 4,700 feature visualizations for the mixing set.
  • Augmentation Pipeline (MIX): The Mix pipeline first optionally applies a standard augmentation, then performs a random number of additive or multiplicative mixing operations, up to k times.Each operation combines the current image with a freshly augmented clean image or an image from the mixing set.

4. Experiments

PIXMIX is evaluated across five safety tasks on CIFAR-10, CIFAR-100, and ImageNet using corruption, consistency, adversarial, calibration, anomaly-detection, and clean-accuracy measures. Across these experiments, it improves broadly over standard and prior augmentation methods, with especially strong results in calibration, corruption robustness, and overall safety trade-offs.

  • Results on CIFAR-10/100 Tasks: PIXMIX outperforms prior methods on five distinct CIFAR safety metrics and nearly matches Outlier Exposure for anomaly detection without a large known-outlier dataset.Lower is better except for anomaly detection; the latter uses AUROC, where higher is better.
  • Results on ImageNet Tasks: PIXMIX is the first augmentation method reported to achieve a Pareto improvement over the baseline across a broad range of safety measures.On ImageNet, it is usually first across evaluation settings and is described as near Pareto-optimal.
  • Results on CIFAR-10/100 Tasks: PIXMIX improves over the standard baseline on all safety measures in CIFAR experiments, while every other method decreases at least one metric.It is reported as the first method to improve performance in all CIFAR settings.
  • Results on ImageNet Tasks: 12.4% mCE improvement over the ImageNet corruption baseline and 5.1% over the next-best method make PIXMIX stronger than state-of-the-art augmentation methods.On rendition robustness, PIXMIX outperforms all methods except SIN, while clean accuracy increases 1.3% rather than declining.
  • Results on ImageNet Tasks: PIXMIX cuts calibration error in half on ImageNet-C and reduces absolute error by 14.9%, while its calibration error increases more slowly with corruption severity.It outperforms all methods on calibration tasks.
  • Mixing Set Ablations: Fractals + FVis provides substantially better results than alternative mixing sets, indicating that structural complexity is important to PIXMIX performance.The ablation compares synthetic datasets and 300K Random Images on CIFAR-100; real images can reach a 19.6% error rate, while fractals can provide more robustness.

5. Conclusion

PIXMIX is presented as a data augmentation technique that improves multiple machine-learning safety measures, including robustness, consistency, adversarial resilience, calibration, and anomaly detection. Across these tasks, it substantially improves on the baseline and achieves state-of-the-art performance in nearly all settings.

  • PIXMIX is a simple data augmentation technique designed to improve machine-learning safety measures.
  • PIXMIX is evaluated on corruption robustness, rendition robustness, prediction consistency, adversarial robustness, confidence calibration, and anomaly detection.
  • PIXMIX provides substantial improvements over the baseline on all existing safety metrics and achieves state-of-the-art performance in nearly all settings.

A. Additional Results

Additional experiments find that PIXMIX provides the best overall performance across reported CIFAR and ImageNet results, remains stable across hyperparameters, and nearly matches specialized outlier exposure for anomaly detection.

  • Mixing Strategies: Mixing only augmented clean images severely harms all safety metrics, whereas mixing-set images reduces calibration error but worsens robustness relative to the original PIXMIX strategy.
  • Full Results: PIXMIX provides the best overall performance across full results for CIFAR-10, CIFAR-100, and ImageNet.The CIFAR evaluations include CIFAR-10-C and CIFAR-100-C, while ImageNet includes the mT5D metric on ImageNet-P.
  • Noise-Based Augmentations: Noise-based augmentation methods can perform well on ImageNet-C by targeting noise corruptions but do not reliably improve many safety metrics.
  • Hyperparameter Sensitivity: PIXMIX performance on CIFAR-100 corruption robustness remains very stable across a range of β and k hyperparameters.
  • Places365 Anomaly Detection: PIXMIX nearly matches the state-of-the-art Outlier Exposure detector on Places365 anomaly detection despite being a general data augmentation technique.Both PIXMIX and Outlier Exposure are fine-tuned for 10 epochs using a ResNet-18 pre-trained on Places365.

B. Outlier Datasets

The anomaly-detection evaluation averages metrics across multiple out-of-distribution datasets, including synthetic noise, generated blobs, textures, house-number images, and disjoint scene categories.

  • Anomaly-detection performance is averaged across a suite of out-of-distribution datasets.
  • The suite includes Gaussian noise, Rademacher noise, algorithmically generated blobs, and textures from the Describable Textures Dataset.
  • The suite also includes SVHN house-number images and Places69, whose 69 scene categories are disjoint from Places365.

C. Broader Impacts

The broader discussion connects PIXMIX’s safety improvements to more reliable deployment and stronger oversight, while noting that anomaly detection can also be misused for surveillance. Additional tables show benefits from combining mixing components and augmentation methods, alongside limitations of noise-based approaches.

  • Broader Impacts: Improved robustness can support more reliable machine-learning systems in safety-critical applications such as self-driving cars.
  • Broader Impacts: Anomaly detection can enable human oversight and fallback policies when systems encounter inputs they were not designed to handle.
  • Broader Impacts: Anomaly detection could also be misused as a surveillance tool.
  • Additional Results: Combining PIXMIX with other data augmentation techniques can further improve performance, although PIXMIX is already strong on its own.
  • Additional Results: Combining fractals and feature visualizations yields the best performance in the mixing-set ablation, while removing either component lowers safety or clean-data performance.
  • Additional Results: Noise-based augmentations do not reliably improve performance across many safety metrics and are less effective on non-noise distribution shifts.
Loading 2112.05135v3…