<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def log_normalize(a, axis=None):
 """Normalizes the input array so that the exponent of the sum is 1. Parameters a : array Non-normalized input data. axis : int Dimension along which normalization is performed. Notes ----- Modifies the input **inplace**. """

    with np.errstate(under="ignore"):
        a_lse = logsumexp(a, axis)
    a -= a_lse[:, np.newaxis]