'Queries the auxillary graph for k-edge-connected components.
Parameters
k : Integer
Desired edge connectivity
Returns
k_edge_components : a generator of k-edge-ccs
Notes
Given the auxillary graph, the k-edge-connected components can be
determined in linear time by removing all edges with weights less than
k from the auxillary graph.  The resulting connected components are the
k-edge-ccs in the original graph.'

def k_edge_components(self, k):

    if (k < 1):
        raise ValueError('k    cannot    be    less    than    1')
    A = self.A
    aux_weights = nx.get_edge_attributes(A, 'weight')
    R = nx.Graph()
    R.add_nodes_from(A.nodes())
    R.add_edges_from((e for (e, w) in aux_weights.items() if (w >= k)))
    for cc in nx.connected_components(R):
        (yield cc)
