Convert single index to corresponding (ell, m) pair

def ind_lm(index, lmax):
    """Convert single index to corresponding (ell, m) pair"""
    import numpy as np
    lm = np.empty(2, dtype=np.float64)
    _ind_lm(index, lmax, lm)
    return lm