
Hi All, I am having difficulty in constructing a reverse_edge_map from an existing CSR. My CSR was created as "edges_are_unsorted", I need to create a reverse_edge_map out of it? Here is my attempt:1 BGL_FORALL_EDGES(e, g, BOOST_Graph)2 {3 // Get source and target of the edge4 BOOST_Graph::vertex_descriptor src = boost::source(e, g);5 BOOST_Graph::vertex_descriptor dst = boost::target(e, g);678 // Get reverse edge9 graph_traits<BOOST_Graph>::out_edge_iterator ei, ei_end;10 for (tie(ei, ei_end) = edge_range(dst, src, g); ei != ei_end; ++ei) 11 {12 rev[*e] = *ei;13 break; // I know there is only one reverse edge in my graph14 } 15 } I got compile error on line 10: error C2784: 'std::pair<Config::out_edge_iterator,Config::out_edge_iterator> boost::edge_range(Config::vertex_descriptor,Config::vertex_descriptor,const boost::adj_list_helper<Config,Base> &)' : could not deduce template argument for 'const boost::adj_list_helper<Config,Base> &' from 'BOOST_Graph' where BOOST_Graph is a CSR graph that has been instantiated as "edges_are_unsorted" prior to the loop. Any help is appreciated. -Thanks, Dan _________________________________________________________________ Got a phone? Get Hotmail & Messenger for mobile! http://go.microsoft.com/?linkid=9724464