MCPcopy Create free account
hub / github.com/BirolLab/abyss / find_complex_transitive_edges

Function find_complex_transitive_edges

Graph/GraphAlgorithms.h:136–158  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

134 */
135template <typename Graph, typename OutIt>
136void find_complex_transitive_edges(Graph& g, OutIt out)
137{
138 typedef graph_traits<Graph> GTraits;
139 typedef typename GTraits::vertex_descriptor vertex_descriptor;
140 typedef typename GTraits::edge_iterator edge_iterator;
141
142 //ConstrainedSearch<Graph> anyPath(100000, 2, false);
143 edge_iterator efirst, elast;
144 for (boost::tie(efirst, elast) = edges(g); efirst != elast;
145 efirst++) {
146 vertex_descriptor u = source(*efirst, g);
147
148 Constraint c = std::make_pair(target(*efirst, g), 100000);
149 Constraints cs;
150 cs.push_back(c);
151 ContigPaths cp;
152
153 unsigned numVisited = 0;
154 constrainedSearch(g, u, cs, cp, numVisited);
155 if (cp.size() > 1)
156 *out++ = *efirst;
157 }
158}
159
160/**
161 * Remove transitive edges from the specified graph.

Callers 1

Calls 4

constrainedSearchFunction · 0.85
edgesFunction · 0.70
push_backMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected