NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

An Iterative Method for Unsupervised Robust Anomaly Detection Under Data Contamination

Minkyung Kim, Jongmin Yu, Junsik Kim, Tae-Hyun Oh, Jun Kyun Choi

Introduction

The "normality assumption" is a fundamental challenge in unsupervised anomaly detection (AD). Most algorithms assume that training data consists exclusively of "normal" samples. However, in real-world scenarios, datasets are frequently "contaminated" with a small, unknown percentage of anomalies. When a model is trained on such data, it inadvertently learns to treat these anomalies as normal, leading to a "smeared" definition of normality and significantly degraded detection performance. While robust methods exist, they often require prior knowledge of the contamination ratio or extensive hyperparameter tuning, limiting their practical utility.

The Iterative Anomaly Detection (IAD) Framework

To address this, the authors introduce Iterative Anomaly Detection (IAD), a model-agnostic framework designed to enhance the robustness of standard AD models. IAD operates through a dual-loop process:

  1. Inner Loop (Training): A base model—such as an Autoencoder (AE), Deep SVDD, or Masked Autoregressive Flow (MAF)—is trained using a weighted loss function.
  2. Outer Loop (Refinement):
    • Importance Weighting: Following each training round, the model assigns an "importance weight" to every sample. Samples with high anomaly scores receive low weights, suppressing their influence on the model's definition of normality. This weighting uses a sigmoid-shaped function that automatically adapts to the score distribution of each round.
  3. Termination Criterion ($h$): To ensure stability, the authors propose a novel stopping criterion based on ranking stability. By monitoring how many samples cross the 50th percentile boundary of anomaly scores between rounds, the framework identifies when the model has converged to a stable representation.
Comparison of the standard learning process (a) and the proposed iterative learning framework (b).

Key Insights

The effectiveness of IAD stems from several core principles:

  • Self-Enforcing Filtering: IAD creates a virtuous cycle where downweighting suspicious samples leads to higher anomaly scores in subsequent rounds, further reducing their influence without requiring explicit labels.
  • Robustness via Ranking: By focusing on the relative rank of samples rather than absolute score values—which can fluctuate significantly—the termination criterion becomes much more resilient to the stochastic nature of deep learning.
  • Model Agnosticism: The framework can be seamlessly integrated with various base architectures, including one-class classification, probabilistic models, and reconstruction-based models.

Experimental Results

The authors evaluated IAD across diverse benchmarks, including multivariate tabular data (e.g., Satellite, Arrhythmia) and image datasets (MNIST, Fashion-MNIST), with contamination ratios ranging from 0.1% to over 30%.

AUC performance across different contamination ratios for Deep SVDD, MAF, and AE models. IAD consistently improves performance compared to the base models.

IAD demonstrated consistent improvements in the Area Under the ROC Curve (AUC) for all base models. For instance, on the highly contaminated Satellite dataset (31.6% anomalies), IAD improved Deep SVDD's AUC from 68.2% to 80.7%. Furthermore, the proposed ranking-based termination criterion ($h$) was shown to capture a significant portion of the potential performance gains compared to simpler heuristics.

Limitations and Future Outlook

While highly effective, IAD does introduce additional computational overhead due to its iterative nature. Additionally, the authors noted that Autoencoders can occasionally "memorize" even downweighted anomalies if training persists too long, suggesting that the choice of base model remains important. Future research may explore applying these iterative weighting techniques to more complex temporal or video data.

Summary updated

BibTeX
@article{kim2023iterative,
  author = {Minkyung Kim and Jongmin Yu and Junsik Kim and Tae-Hyun Oh and Jun Kyun Choi},
  title = {{An Iterative Method for Unsupervised Robust Anomaly Detection Under Data Contamination}},
  journal = {IEEE Trans. Neural Networks Learn. Syst.},
  year = {2023},
}
Figure