Source-linked AI summary

Robust, Deep and Inductive Anomaly Detection

Raghavendra Chalapathy, Aditya Krishna Menon, Sanjay Chawla

arXiv:1704.06743v3cs.LGcs.CVstat.ML

TL;DR

The paper addresses PCA’s sensitivity to gross perturbations, linearity, and robust PCA’s lack of inductive test-set detection. It introduces a deep robust autoencoder that learns nonlinear structure while modeling corruption, and reports effective anomaly detection across real-world settings.

  • Problem

    PCA is sensitive to gross perturbations and linear structure, while robust PCA does not support inductive anomaly detection on test instances.

  • Method

    A robust autoencoder learns nonlinear structure while an additional N term captures gross outliers, producing reconstructions for anomaly detection.

  • Results

    The robust autoencoder outperforms existing methods on CIFAR-10, convincingly outperforms SVD and AE on an inductive task, and effectively suppresses noise in image denoising.

  • Takeaways & Limitations

    Robustness, nonlinearity, and inductive prediction together support deployment for detecting subtle anomalies in live settings.

  • Takeaways & Limitations

    The method’s black-box nature leaves outlier description—explaining why a point is anomalous—as future work.

Abstract

from arXiv · show

PCA is a classical statistical technique whose simplicity and maturity has seen it find widespread use as an anomaly detection technique. However, it is limited in this regard by being sensitive to gross perturbations of the input, and by seeking a linear subspace that captures normal behaviour. The first issue has been dealt with by robust PCA, a variant of PCA that explicitly allows for some data points to be arbitrarily corrupted, however, this does not resolve the second issue, and indeed introduces the new issue that one can no longer inductively find anomalies on a test set. This paper addresses both issues in a single model, the robust autoencoder. This method learns a nonlinear subspace that captures the majority of data points, while allowing for some data to have arbitrary corruption. The model is simple to train and leverages recent advances in the optimisation of deep neural networks. Experiments on a range of real-world datasets highlight the model's effectiveness.

1 Anomaly detection: motivation and challenges

Anomaly detection seeks instances dramatically dissimilar from the rest, but PCA-based methods struggle with perturbations, nonlinear structure, and inductive test-set detection. The paper proposes a deep robust autoencoder to address these limitations.

  • Anomaly detection identifies instances that are dramatically dissimilar from other observations, which may reflect errors or a previously unknown process.
  • PCA projects high-dimensional data linearly into a lower-dimensional space and treats points far from their projections as anomalous.
  • A single extreme data point can change PCA’s projection orientation and mask anomalies.
  • Robust PCA limits anomaly effects but retains a linear projection and cannot perform inductive anomaly detection on test instances.
  • The proposed deep robust autoencoder uses nonlinear activations and hidden layers, improving detection on complex image data while supporting inductive anomaly detection.

2 Background and related work on anomaly detection

Anomaly detection methods include non-parametric outlier detection and reconstruction-based approaches, with PCA providing a linear low-dimensional representation. Subsequent methods address PCA’s linearity or sensitivity to corruption through nonlinear autoencoders, robust PCA, direct robust matrix factorization, and robust kernel PCA.

  • Problem setting: Anomaly detection identifies rows of a feature matrix that are dissimilar to the other rows.The matrix contains N data points and D features, and anomaly detection evaluates which rows are anomalous.
  • Non-parametric methods: Non-parametric approaches detect outliers using domain-dependent distance or density information, while one-class SVM learns a boundary around most data.Distance-based methods flag points far from neighbours; one-class SVM captures most of the data’s probability mass.
  • Reconstruction methods: Reconstruction-based methods use the discrepancy between an input and its reconstruction to assess whether a point is anomalous.A close reconstruction indicates normality, whereas a poor reconstruction indicates an anomaly.
  • PCA and nonlinear extensions: PCA reconstructs data by encoding it into a K-dimensional linear subspace and decoding it back, thereby assuming that normal behaviour is linearly represented.The latent dimension satisfies K ≪ D, with XU encoding and U^T decoding the data.
  • PCA and nonlinear extensions: Autoencoders relax PCA’s linearity by applying a nonlinear activation, implicitly projecting data onto a nonlinear manifold.The reconstruction is ˆX = f(XU)V, with sigmoid and ReLU among the possible activation functions.
  • Robust methods: Robust PCA separates data into a low-rank signal and sparse noise, allowing arbitrary entry perturbations but producing extreme all-signal or all-noise interpretations at λ’s limits.As λ approaches infinity, all points are treated as normal; as λ approaches zero, high-norm points are treated as anomalous.
  • Robust methods: DRMF explicitly constrains signal rank and anomaly sparsity, whereas robust kernel PCA captures nonlinear anomalies through a pre-specified feature mapping without explicitly handling gross outliers.DRMF requires a bespoke optimization algorithm because its objective is non-convex, while autoencoders learn their mapping implicitly.

3 From robust PCA to robust autoencoders

The robust autoencoder extends robust PCA with nonlinear representation learning, explicit outlier absorption, and inductive anomaly detection, while sacrificing convexity.

  • Robust autoencoder: The model extends robust PCA by learning a nonlinear manifold that explains most data while allowing gross outliers through an additional noise term.The reconstruction is computed as ˆX = f(XU)V, with N capturing gross outliers.
  • Robust autoencoder: For intermediate λ, the model augments a standard autoencoder with a noise absorption term that provides robustness.As λ approaches infinity, the model becomes a standard autoencoder; as λ approaches zero, it can memorize the training data.
  • Optimization: Alternating optimization updates the network parameters with deep-learning optimizers and the noise matrix with soft thresholding.The procedure alternates these updates until the overall objective changes below a threshold and supports online or streaming training.
  • Inductive detection: The anomaly detector is inductive because the learned robust representation can generalize to unseen points on the training data’s manifold.Robust PCA cannot make such predictions because it estimates parameters only for observations present in X.
  • Relation to robust PCA: The method captures nonlinear structure and enables inductive detection, but its objective is non-convex unlike robust PCA.The paper argues that the model can nevertheless be effectively trained with the described procedure.
  • Relation to existing models: The robust autoencoder differs from denoising autoencoders by inferring noise automatically and targeting anomaly identification rather than feature extraction.The paper presents the method as a nonlinear extension of RPCA for anomaly detection.

4 Experimental setup

The experiments evaluate robust convolutional autoencoders against classical, robust, kernel, and standard autoencoder baselines on three real-world datasets using qualitative and quantitative protocols.

  • Methods and datasets: The study focuses primarily on image anomaly detection and compares RCAE with Truncated SVD, RPCA, RKPCA, AE, and CAE.CAE is the non-robust convolutional autoencoder baseline, while RCAE is the proposed model.
  • Methods and datasets: The three datasets are restaurant activity snapshots, USPS handwritten digits, and CIFAR-10 images.CIFAR-10 contains 60,000 32 × 32 colour images across 10 classes.
  • Evaluation methodology: Restaurant anomalies are assessed qualitatively because the dataset has no ground-truth anomaly labels.The evaluation visually compares anomalies flagged by the different methods.
  • Evaluation methodology: USPS and CIFAR-10 use labelled training anomalies and are evaluated with AUPRC, AUROC, and P@10.AUPRC and AUROC measure ranking performance, while P@10 measures the anomalous fraction among the top 10 scored instances.
  • Evaluation methodology: CIFAR-10 anomalies are cats among dogs, while USPS anomalies are ‘7’s among ‘1’s.The CIFAR-10 setup uses 5,000 dog images and 50 cat images; USPS uses 220 ‘1’s and 11 ‘7’s.

5 Experimental results

Experiments evaluate robust autoencoders across non-inductive anomaly detection, inductive anomaly detection, and image denoising. RCAE identifies anomalies effectively on USPS and CIFAR-10, reconstructs restaurant backgrounds smoothly, generalizes to test anomalies, suppresses image noise, and has training times comparable to existing methods.

  • 5.1 Non-inductive anomaly detection: RCAE qualitatively outperforms RPCA on restaurant background reconstruction, identifying high-foreground-activity images and producing smoother backgrounds.The dataset lacks ground-truth anomalies, so evaluation is visual; Figure 1 compares the six most anomalous images.
  • 5.1 Non-inductive anomaly detection: All USPS ‘7’ images are identified as outliers with near certainty, whereas RPCA places some ‘1’ images among its top anomalies.RCAE’s top-ranked anomalous images correctly contain the ‘7’s.
  • 5.1 Non-inductive anomaly detection: RCAE clearly outperforms existing methods on CIFAR-10 anomaly detection, including the non-robust CAE baseline.The comparison indicates that explicitly modeling anomalies with the N term is important for this task.
  • 5.1 Non-inductive anomaly detection: RCAE distinguishes CIFAR-10 cats from dogs by learning the manifold of the majority dog images, unlike RPCA’s linear-subspace model.Cats are treated as anomalies in the 5000-dog, 50-cat dataset.
  • 5.2 Inductive anomaly detection results: On inductive CIFAR-10 detection, RCAE convincingly outperforms SVD and AE baselines and correctly identifies many cats in the test set.The model is trained on 5000 dogs and evaluated on 500 dogs plus 50 cats; the task is more challenging than single-dataset detection.
  • 5.3 Image denoising results: RCAE suppresses 10% salt-and-pepper noise with low reconstruction error, although its improvement over raw CAE is modest.All models are trained on 5000 CIFAR-10 dog images and evaluated by recovery of the original images.
  • 5.4 Comparison of training times: On the small restaurant dataset, training takes 1 minute for RPCA, 8.5 minutes for RKPCA, and 10 minutes for RCAE.The authors emphasize that RCAE can leverage deep-learning optimization advances, including GPU training.

6 Conclusion

The paper extends robust PCA into a nonlinear, inductive autoencoder, combining robustness, nonlinear anomaly discovery, and deployment on live data. It also identifies the autoencoder’s black-box nature as a direction for future work on explaining anomalies.

  • The proposed model extends robust PCA to a nonlinear autoencoder and is presented as robust, nonlinear, and inductive.
  • Robustness reduces sensitivity to anomalies, nonlinearity can reveal subtler anomalies, and inductive prediction supports deployment in live settings.
  • A key limitation is that autoencoders remain black-box representations, motivating future work on explaining why individual points are anomalous.
Loading 1704.06743v3…