def METHOD_NAME(X):
    """
    Helper function that iteratively returns the data stored in self.X
    Returns an iterable version of self.X
    """
    if hasattr(X, 'shape'):
        yield np.asarray(list(range(X.shape[0]))), []
    else:
        yield np.asarray(list(range(len(X)))), []