def __and__(self, graph): nodes = cluster.intersection(cluster.flatten(self), cluster.flatten(graph)) all = self | graph return cluster.subgraph(all, nodes, 0)
def __and__(self, node, distance=1): return cluster.intersection( self.flatten(distance), node.flatten(distance))
def __and__(self, node, distance=1): return cluster.intersection(self.flatten(distance), node.flatten(distance))