def ensure_ndarray_or_None(A, shape=None, uniform=None, ndim=None, size=None, dtype=None, kind=None):
    r""" Ensures A is None or an ndarray and does an assert_array with the given parameters """
    if A is not None:
        return ensure_ndarray(A, shape=shape, uniform=uniform, ndim=ndim, size=size, dtype=dtype, kind=kind)
    else:
        return None
def ensure_ndarray_or_None ( A , shape = None , uniform = None , ndim = None , size = None , dtype = None , kind = None ) : if A is not None : return ensure_ndarray ( A , shape = shape , uniform = uniform , ndim = ndim , size = size , dtype = dtype , kind = kind ) else : return None
r""" Ensures A is None or an ndarray and does an assert_array with the given parameters