Mitigating the reconstruction-detection trade-off in VAE-based unsupervised anomaly detection
For practitioners using VAEs for unsupervised anomaly detection, this work identifies and mitigates a key trade-off in model selection.
The paper reveals a trade-off between reconstruction quality and anomaly detection in β-VAE models, and shows that Sparse VAE improves detection while maintaining high reconstruction quality.
Variational autoencoders are widely used for unsupervised anomaly detection. Model selection however remains an open-question: to remain fully unsupervised, hyperparameters are often chosen to minimize the reconstruction error on normal samples. In this paper, we reveal a trade-off between reconstruction quality and anomaly detection among $β$-VAE models. Models with constrained latent space reach higher detection metrics but lower reconstruction quality. We also assess the performance variability across random seeds and show it is linked to the distance between normal and abnormal latent distributions. From this analysis, we justify and investigate two methods to mitigate the reconstructiondetection tradeoff: beta-scheduling and the Sparse VAE. The latter especially shows an improvement in detection while maintaining high reconstruction quality.