import torch


def compute_gaussian_kl(z_mean, z_logvar):
    """Compute KL divergence between input Gaussian and Standard Normal."""
    return 0.5 * torch.mean(
        torch.square(z_mean) + torch.exp(z_logvar) - z_logvar - 1, [0])