Table of Contents
Fetching ...

Revisiting VAE for Unsupervised Time Series Anomaly Detection: A Frequency Perspective

Zexin Wang, Changhua Pei, Minghua Ma, Xin Wang, Zhihan Li, Dan Pei, Saravan Rajmohan, Dongmei Zhang, Qingwei Lin, Haiming Zhang, Jianhui Li, Gaogang Xie

TL;DR

FCVAE reframes unsupervised time-series anomaly detection by conditioning a CVAE on frequency-domain information to capture both long-periodic heterogeneity and fine-grained short-periodic patterns. It introduces global and local frequency extractors (GFM and LFM) along with a target-attention mechanism, and employs CM-ELBO, missing data strategies, and last-point masking to enable robust unsupervised learning and accurate anomaly scoring. Across four public datasets and production deployment, FCVAE surpasses state-of-the-art baselines in Best F1 and Delay F1, with ablations confirming the value of frequency conditioning and the proposed architectural components. The approach is efficient for large-scale deployment, achieving high throughput in real-time cloud systems and offering practical impact for web-system anomaly detection.

Abstract

Time series Anomaly Detection (AD) plays a crucial role for web systems. Various web systems rely on time series data to monitor and identify anomalies in real time, as well as to initiate diagnosis and remediation procedures. Variational Autoencoders (VAEs) have gained popularity in recent decades due to their superior de-noising capabilities, which are useful for anomaly detection. However, our study reveals that VAE-based methods face challenges in capturing long-periodic heterogeneous patterns and detailed short-periodic trends simultaneously. To address these challenges, we propose Frequency-enhanced Conditional Variational Autoencoder (FCVAE), a novel unsupervised AD method for univariate time series. To ensure an accurate AD, FCVAE exploits an innovative approach to concurrently integrate both the global and local frequency features into the condition of Conditional Variational Autoencoder (CVAE) to significantly increase the accuracy of reconstructing the normal data. Together with a carefully designed "target attention" mechanism, our approach allows the model to pick the most useful information from the frequency domain for better short-periodic trend construction. Our FCVAE has been evaluated on public datasets and a large-scale cloud system, and the results demonstrate that it outperforms state-of-the-art methods. This confirms the practical applicability of our approach in addressing the limitations of current VAE-based anomaly detection models.

Revisiting VAE for Unsupervised Time Series Anomaly Detection: A Frequency Perspective

TL;DR

FCVAE reframes unsupervised time-series anomaly detection by conditioning a CVAE on frequency-domain information to capture both long-periodic heterogeneity and fine-grained short-periodic patterns. It introduces global and local frequency extractors (GFM and LFM) along with a target-attention mechanism, and employs CM-ELBO, missing data strategies, and last-point masking to enable robust unsupervised learning and accurate anomaly scoring. Across four public datasets and production deployment, FCVAE surpasses state-of-the-art baselines in Best F1 and Delay F1, with ablations confirming the value of frequency conditioning and the proposed architectural components. The approach is efficient for large-scale deployment, achieving high throughput in real-time cloud systems and offering practical impact for web-system anomaly detection.

Abstract

Time series Anomaly Detection (AD) plays a crucial role for web systems. Various web systems rely on time series data to monitor and identify anomalies in real time, as well as to initiate diagnosis and remediation procedures. Variational Autoencoders (VAEs) have gained popularity in recent decades due to their superior de-noising capabilities, which are useful for anomaly detection. However, our study reveals that VAE-based methods face challenges in capturing long-periodic heterogeneous patterns and detailed short-periodic trends simultaneously. To address these challenges, we propose Frequency-enhanced Conditional Variational Autoencoder (FCVAE), a novel unsupervised AD method for univariate time series. To ensure an accurate AD, FCVAE exploits an innovative approach to concurrently integrate both the global and local frequency features into the condition of Conditional Variational Autoencoder (CVAE) to significantly increase the accuracy of reconstructing the normal data. Together with a carefully designed "target attention" mechanism, our approach allows the model to pick the most useful information from the frequency domain for better short-periodic trend construction. Our FCVAE has been evaluated on public datasets and a large-scale cloud system, and the results demonstrate that it outperforms state-of-the-art methods. This confirms the practical applicability of our approach in addressing the limitations of current VAE-based anomaly detection models.
Paper Structure (28 sections, 7 equations, 11 figures, 3 tables)

This paper contains 28 sections, 7 equations, 11 figures, 3 tables.

Figures (11)

  • Figure 1: Comparison of four KPI reconstruction methods presented in our paper, highlighting anomalies in red ③. The green shade ⑤ represents the difference between the reconstructed values and the original values, the red shade ② represents a long period, and the blue ellipse ④ indicates peaks and valleys that are not properly reconstructed, the blue rectangle ① will be magnified in Figure \ref{['case']} for detailed comparison.
  • Figure 2: A detailed view of the region enclosed by a blue rectangle ① in Figure \ref{['overall-contrast']}, where the shaded area represents the value range before applying a sliding window average.
  • Figure 3: Overall Framework.
  • Figure 4: FCVAE Model Architecture.
  • Figure 5: Architecure of LFM.
  • ...and 6 more figures