def mask_indices(n,mask_func,k=0):
    m = ones((n,n),int)
    a = mask_func(m,k)
    return where(a != 0)
Return the indices to access (n, n) arrays, given a masking function.
dataset/ETHPy150Open nipy/nitime/nitime/index_utils.py/mask_indices