def METHOD_NAME(x):
    """Log-softmax, computed with NumPy
    The computation is performed with 64-bit floats.
    """
    if x.dtype is not np.float64:
        x = x.astype(np.float64)
    x = x - np.max(x)
    return x - np.log(np.sum(np.exp(x)))