Anomaly Detection via Latent Variables Learned by Variational Autoencoders