(self)
return result
Returns the membership vector of this cover.

        The membership vector of a cover covering I{n} elements is a list of
        length I{n}, where element I{i} contains the cluster indices of the
        I{i}th item.
Returns the membership vector of this cover.
Returns the membership vector of this cover .
def membership(self):
        """Returns the membership vector of this cover.

        The membership vector of a cover covering I{n} elements is a list of
        length I{n}, where element I{i} contains the cluster indices of the
        I{i}th item.
        """
        result = [[] for _ in range(self._n)]
        for idx, cluster in enumerate(self):
            for item in cluster:
                result[item].append(idx)
        return result
def membership ( self ) : result = [ [ ] for _ in range ( self . _n ) ] for idx , cluster in enumerate ( self ) : for item in cluster : result [ item ] . append ( idx ) return result