Skip to content

Implementation of paper Disentangled Conditional Variational Autoencoder for Unsupervised Anomaly Detection

License

Notifications You must be signed in to change notification settings

UMDimReduction/Disentangled-Conditional-Variational-Autoencoder-dCVAE-

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Disentangled Conditional Variational Autoencoder (dCVAE) for Unsupervised Anomaly Detection

Recently, generative models have shown promising performance in anomaly detection tasks. Specifically, autoencoders learn representations of high-dimensional data, and their reconstruction ability can be used to assess whether a new instance is likely to be anomalous. However, the primary challenge of unsupervised anomaly detection (UAD) is in learning appropriate disentangled features and avoiding information loss, while incorporating known sources of variation to improve the reconstruction. In this paper, we propose a novel architecture of generative autoencoder by combining the frameworks of $\beta$-VAE, conditional variational autoencoder (CVAE), and the principle of total correlation (TC). We show that our architecture improves the disentanglement of latent features, optimizes TC loss more efficiently, and improves the ability to detect anomalies in an unsupervised manner with respect to high-dimensional instances, such as in imaging datasets. Through both qualitative and quantitative experiments on several benchmark datasets, we demonstrate that our proposed method excels in terms of both anomaly detection and capturing disentangled features. Our analysis underlines the importance of learning disentangled features for UAD tasks.

Installation

   pip install -r requirements.txt

Usage

   cd ./dcvae/src

Run:

   python run.py vae --dataset fmnist --batch_size 64 --downstream_task umap --epochs 50

Results

Reconstructions

Reconstructions

Latent Representation (MNIST)

Latent Representation (MNIST)

Latent Representation (FMNIST)

Latent Representation (FMNIST)

Latent Representation (EMNIST)

Latent Representation (EMNIST)

Latent Representation (KMNIST)

Latent Representation (KMNIST)

License

License: MIT

About

Implementation of paper Disentangled Conditional Variational Autoencoder for Unsupervised Anomaly Detection

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages