graph.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <VirtualRobot/VirtualRobot.h>
4 
5 #include <SemanticObjectRelations/RelationGraph/json/AttributedGraph.h>
6 
7 #include <VisionX/interface/libraries/SemanticObjectRelations/Graph.h>
8 
9 
10 namespace armarx::semantic
11 {
12 
13  data::Graph toIce(const semrel::AttributedGraph& input);
14  semrel::AttributedGraph fromIce(const semantic::data::Graph& graph);
15 
16 
17  template <typename VA, typename EA, typename GA>
19  {
20  return toIce(semrel::toAttributedGraph(graph));
21  }
22 
23  template <typename VA, typename EA, typename GA>
24  data::Graph toIce(const semrel::RelationGraph<VA, EA, GA>& graph, const semrel::ShapeMap& objects)
25  {
26  return toIce(semrel::toAttributedGraph(graph, objects));
27  }
28 
29  template <typename GraphT>
30  GraphT fromIce(const semantic::data::Graph& graph)
31  {
32  return fromIce(graph).toGraph<GraphT>();
33  }
34 
35 }
semrel::RelationGraph
Definition: forward_declarations.h:28
armarx::semantic::toIce
data::Graph toIce(const semrel::AttributedGraph &input)
Definition: graph.cpp:15
armarx::aron::input
ReaderT::InputType & input
Definition: rw.h:19
armarx::Graph
boost::subgraph< CloudGraph > Graph
Definition: Common.h:54
armarx::semantic
Definition: ShapesSupportRelations.cpp:32
armarx::semantic::fromIce
semrel::AttributedGraph fromIce(const semantic::data::Graph &graph)
Definition: graph.h:30