Skip to content

YeongHyeon/CVAE-AnomalyDetection-TF2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

[TensorFlow 2] Anomaly Detection using Convolutional Variational Auto-Encoder (CVAE)

Example of Anomaly Detection using Convolutional Variational Auto-Encoder (CVAE) [Related repository] [PyTorch Version].

Architecture

Simplified VAE architecture.

Problem Definition

'Class-1' is defined as normal and the others are defined as abnormal.

Results

Training

Restoration result by CVAE.

Latent vector space of training set, and reconstruction result of latent space walking.

Test

z_dim = 2

Left figure shows latent vector space of test set. Right figure shows box plot with restoration loss of test procedure.

z_dim = 128

Latent vector space of test set, box plot with restoration loss, and histogram of restoration loss.

Environment

  • Python 3.7.4
  • Tensorflow 2.1.0
  • Numpy 1.17.1
  • Matplotlib 3.1.1
  • Scikit Learn (sklearn) 0.21.3

Reference

[1] Kingma, D. P., & Welling, M. (2013). Auto-encoding variational bayes. arXiv preprint arXiv:1312.6114.
[2] Kullback Leibler divergence. Wikipedia