cs.LGNov 7, 2026

Self-contained Data Cleaning for Unsupervised Anomaly Detection

Authors: Jordan F. Masakuna, Ahmed Yacine, Djeff K. Nkashama, Arian Soltani, Marc Frappier, Pierre M. Tardif, Froduald Kabanza

Organizations: University of Sherbrooke, Sherbrooke, Canada · University of Kinshasa, Kinshasa, DR. Congo

Abstract

Training datasets for unsupervised anomaly detection are often assumed to be anomaly-free, but in practice, they frequently contain malicious or anomalous contamination. This contamination severely degrades the dependability and security of downstream detection models. While some contamination-robust methods exist, they rarely generalize across different model architectures and typically rely on a priori knowledge of the contamination ratio\textemdash information that is rarely available in real-world security operations. In this paper, we propose a novel, self-contained preprocessing framework for anomaly detection that identifies and removes training set contamination without relying on known contamination ratios. Our approach performs a dynamic analysis of the cosine similarity between each data point and its reconstruction during the early training stages of an auto-encoder, mapping points into a dynamic space where anomalous regions naturally exhibit lower density. By executing ``hard cleaning''\textemdash removing all identified anomalous candidates from the training pool\textemdash we systematically improve data quality. Because this cleaning occurs at the data level, the security and reliability improvements generalize seamlessly across various downstream anomaly detection architectures. Evaluating our framework across 8 distinct models and 10 security-relevant datasets, our approach achieves up to 100% contamination reduction, yielding average improvements of 11.2% in F1 score and 7.3% in classification accuracy.

Figures & tables

Explore similar work

CardsList
  1. Memory-Distilled Selection for Noise-Robust Anomaly Detection

    May 26, 2026Sirojbek Safarov, Jaewoo Park, Yoon Gyo Jung +4Industrial Anomaly DetectionData Selection

  2. Robustness of Anomaly Detection Models for Industrial Control Systems under Training-Time Data Contamination

    Aug 24, 2026Mustafa Umut Ozbek, Taiwo Ojo, Pooria Madani +2Industrial Control System SecurityAnomaly Detection