#include <FPGATrackSimGNNRoadMakerTool.h>
|
| | JunctionAwareVisitor (int ¤t, std::vector< int > &in_control_vars, std::vector< std::vector< int > > &in_comps, std::unordered_map< Vertex, std::vector< Vertex > > &in_pred_map, ColorMap in_cmap) |
| template<typename VertexT, typename GraphT> |
| void | discover_vertex (VertexT v, const GraphT &g) |
| template<typename EdgeT, typename GraphT> |
| void | examine_edge (EdgeT e, const GraphT &g) |
| template<typename VertexT, typename GraphT> |
| void | process_edges (VertexT src, VertexT tar, const GraphT &g) |
◆ JunctionAwareVisitor()
| JunctionAwareVisitor::JunctionAwareVisitor |
( |
int & | current, |
|
|
std::vector< int > & | in_control_vars, |
|
|
std::vector< std::vector< int > > & | in_comps, |
|
|
std::unordered_map< Vertex, std::vector< Vertex > > & | in_pred_map, |
|
|
ColorMap | in_cmap ) |
Definition at line 291 of file FPGATrackSimGNNRoadMakerTool.cxx.
292 :
std::unordered_map< Vertex, std::vector< Vertex > > & m_pred_map
std::vector< std::vector< int > > & m_components
std::vector< int > & m_control_vars
◆ discover_vertex()
template<typename VertexT, typename GraphT>
| void JunctionAwareVisitor::discover_vertex |
( |
VertexT | v, |
|
|
const GraphT & | g ) |
◆ examine_edge()
template<typename EdgeT, typename GraphT>
| void JunctionAwareVisitor::examine_edge |
( |
EdgeT | e, |
|
|
const GraphT & | g ) |
Definition at line 306 of file FPGATrackSimGNNRoadMakerTool.cxx.
307{
308 auto src_node =
source(e,g);
309 auto tar_node =
target(e,g);
312
313
314 if ((
get(
m_color_map, tar_node) == boost::black_color) && (boost::out_degree(tar_node, g) > 0)){
315 m_control_vars[tar_node] = boost:: out_degree(tar_node,g) < 2 ? 1 : -2;
316 auto out_edges = boost::out_edges(tar_node, g);
317 for (auto it = out_edges.first; it != out_edges.second; ++ it){
320 }
321 }
322}
void process_edges(VertexT src, VertexT tar, const GraphT &g)
T * get(TKey *tobj)
get a TObject* from a TKey* (why can't a TObject be a TKey?)
◆ process_edges()
template<typename VertexT, typename GraphT>
| void JunctionAwareVisitor::process_edges |
( |
VertexT | src, |
|
|
VertexT | tar, |
|
|
const GraphT & | g ) |
Definition at line 325 of file FPGATrackSimGNNRoadMakerTool.cxx.
325 {
326 std::vector<int> src_comp;
327
331 src_comp.push_back(comp);
332 }
333 }
334
335
338 m_control_vars[tar_node] = boost::out_degree(tar_node, g) < 2 ? 1 : -2;
339 }
340
341
344 m_control_vars[tar_node] = boost::out_degree(tar_node, g) < 2 ? 1 : -2;
347 }
348
349
354 m_control_vars[tar_node] = boost::out_degree(tar_node, g) < 2 ? 1 : -2;
355
356 std::unordered_set<Vertex> visited;
358 if(visited.count(node)) return;
359 visited.insert(node);
361 if((std::find(node_comps.begin(), node_comps.end(),
m_current_comp) == node_comps.end()) &&
362 (src_comp.empty() || std::find(node_comps.begin(), node_comps.end(), src_comp[i]) != node_comps.end())){
364 }
367 }
368 };
370 }
371 }
372}
◆ m_color_map
| ColorMap JunctionAwareVisitor::m_color_map |
|
private |
◆ m_components
| std::vector<std::vector<int> >& JunctionAwareVisitor::m_components |
|
private |
◆ m_control_vars
| std::vector<int>& JunctionAwareVisitor::m_control_vars |
|
private |
◆ m_current_comp
| int& JunctionAwareVisitor::m_current_comp |
|
private |
◆ m_initial_comp
| int JunctionAwareVisitor::m_initial_comp |
|
private |
◆ m_n_iter
| int JunctionAwareVisitor::m_n_iter = 1 |
|
private |
◆ m_pred_map
| std::unordered_map<Vertex, std::vector<Vertex> >& JunctionAwareVisitor::m_pred_map |
|
private |
The documentation for this class was generated from the following files: