dimod.Structured.to_networkx_graph#

Structured.to_networkx_graph()[source]#

Convert structure to NetworkX graph format.

Note that NetworkX must be installed for this method to work.

Returns:

A NetworkX graph containing the nodes and edges from the sampler’s structure.

Return type:

networkx.Graph