Balancing Reconstruction Error and Kullback-Leibler Divergence in Variational Autoencoders