[Paper Review] Neural Transformation Learning for Deep Anomaly Detection Beyond Images
This paper proposes NeuTraL AD, a self-supervised anomaly detection method that learns data transformations end-to-end for time series and tabular data, using a deterministic contrastive loss to ensure semantic consistency and view diversity. It achieves state-of-the-art performance, improving AUC by 10 percentage points on epilepsy time series and F1 by 2.9 points on arrhythmia tabular data compared to prior methods.
Data transformations (e.g. rotations, reflections, and cropping) play an important role in self-supervised learning. Typically, images are transformed into different views, and neural networks trained on tasks involving these views produce useful feature representations for downstream tasks, including anomaly detection. However, for anomaly detection beyond image data, it is often unclear which transformations to use. Here we present a simple end-to-end procedure for anomaly detection with learnable transformations. The key idea is to embed the transformed data into a semantic space such that the transformed data still resemble their untransformed form, while different transformations are easily distinguishable. Extensive experiments on time series demonstrate that our proposed method outperforms existing approaches in the one-vs.-rest setting and is competitive in the more challenging n-vs.-rest anomaly detection task. On tabular datasets from the medical and cyber-security domains, our method learns domain-specific transformations and detects anomalies more accurately than previous work.
Motivation & Objective
- To address the challenge of designing effective data transformations for anomaly detection in non-image data such as time series and tabular data.
- To develop a self-supervised method that jointly learns useful transformations and anomaly detection representations without relying on handcrafted or predefined augmentations.
- To improve anomaly detection performance beyond images by enabling end-to-end learning of transformations tailored to the data domain.
- To eliminate the need for adversarial training or regularization by introducing a deterministic contrastive loss that ensures semantic fidelity and view diversity.
Proposed method
- The method uses a set of learnable neural transformations applied to input data, with each transformation parameterized as a differentiable function (e.g., feedforward, residual, multiplicative) using learnable masks.
- A deterministic contrastive loss (DCL) is introduced to train both the transformations and the encoder jointly, ensuring that transformed views preserve semantic content while remaining distinguishable from one another.
- The DCL objective avoids negative sampling and noise distributions, making it non-stochastic and directly usable as an anomaly score.
- The encoder embeds both original and transformed samples into a shared semantic space, where the contrastive loss encourages positive pairs (original and transformed) to be close and different views to be far apart.
- The model is trained end-to-end with backpropagation, and the final anomaly score is derived directly from the DCL objective, enabling direct inference without additional thresholding.
- The number of transformations K is a hyperparameter, with performance improving and stabilizing as K increases beyond 10.
Experimental results
Research questions
- RQ1Can learnable neural transformations improve self-supervised anomaly detection performance on non-image data such as time series and tabular data?
- RQ2How does a deterministic contrastive loss compare to standard contrastive losses that rely on negative sampling in terms of anomaly detection performance and training stability?
- RQ3What is the impact of transformation parametrization (e.g., feedforward, residual, multiplicative) and the number of transformations K on detection accuracy?
- RQ4Can the method generalize across diverse data types without requiring domain-specific augmentation design?
Key findings
- On the epilepsy time series dataset, NeuTraL AD improved the AUC from 82.6% (SOTA) to 92.6%, representing a 10 percentage point gain.
- On the Arrhythmia tabular dataset, NeuTraL AD achieved an F1 score of 60.3%, a 2.9 percentage point improvement over the previous SOTA method GOAD.
- The method outperformed all baselines, including OC-SVM, LOF, DAGMM, GOAD, and DROCC, across all evaluated datasets in both one-vs.-rest and n-vs.-rest anomaly detection settings.
- Performance improved with increasing numbers of transformations K and stabilized when K exceeded approximately 10, indicating sufficient diversity in learned transformations.
- NeuTraL AD was robust to different transformation parametrizations (feedforward, residual, multiplicative) when K was large enough, showing generalization across architectures.
- The deterministic contrastive loss enabled direct use as an anomaly score, eliminating the need for additional thresholding or calibration steps.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.