Warning

This documents an unmaintained version of NetworkX. Please upgrade to a maintained version and see the current NetworkX documentation.

# sets¶

sets(G)[source]

Returns bipartite node sets of graph G.

Raises an exception if the graph is not bipartite.

Parameters : G : NetworkX graph (X,Y) : two-tuple of sets One set of nodes for each part of the bipartite graph.

>>> from networkx.algorithms import bipartite