The template class for representing an abstract tree without specifing the dimensionality of the exact parameterization of the nodes. This definition is passed in via the Operation (Ops) template class. More...
#include <posegraph.h>
Classes | |
struct | Edge |
Definition of an edge in the graph based on the template input from Ops. More... | |
struct | Vertex |
Definition of a vertex in the graph based on the template input from Ops. More... | |
Public Types | |
typedef Ops::BaseType | BaseType |
typedef Ops::CovarianceType | Covariance |
typedef EVComparator< Edge * >::CompareMode | EdgeCompareMode |
typedef std::list< Edge * > | EdgeList |
typedef std::map< Edge *, Edge * > | EdgeMap |
typedef std::multiset< Edge *, EVComparator< Edge * > > | EdgeSet |
typedef Ops::InformationType | Information |
typedef Ops::ParametersType | Parameters |
typedef Ops::PoseType | Pose |
typedef Ops::RotationType | Rotation |
typedef Ops::TransformationType | Transformation |
typedef Ops::TranslationType | Translation |
typedef std::map< int, Vertex * > | VertexMap |
typedef std::set< Vertex * > | VertexSet |
Public Member Functions | |
Edge * | addEdge (Vertex *v1, Vertex *v2, const Transformation &t, const Information &i) |
Edge * | addIncrementalEdge (int id1, int id2, const Transformation &t, const Information &i) |
Vertex * | addVertex (int id, const Pose &pose) |
EdgeSet * | affectedEdges (Vertex *v) |
EdgeSet * | affectedEdges (VertexSet &vl) |
bool | buildMST (int id) |
bool | buildSimpleTree () |
void | clear () |
void | compressIndices () |
Edge * | edge (int id1, int id2) |
const Edge * | edge (int id1, int id2) const |
virtual void | initializeFromParentEdge (Vertex *v)=0 |
int | maxIndex () |
int | maxPathLength () |
Edge * | removeEdge (Edge *eq) |
Vertex * | removeVertex (int id) |
void | revertEdge (Edge *e) |
virtual void | revertEdgeInfo (Edge *e)=0 |
bool | sanityCheck () |
EdgeSet * | sortEdges () |
int | totalPathLength () |
template<class Action > | |
void | treeBreadthVisit (Action &act) |
template<class Action > | |
void | treeDepthVisit (Action &act, Vertex *v) |
TreePoseGraph () | |
Vertex * | vertex (int id) |
const Vertex * | vertex (int id) const |
virtual | ~TreePoseGraph () |
Public Attributes | |
EdgeMap | edges |
Vertex * | root |
EdgeSet * | sortedEdges |
VertexMap | vertices |
Protected Member Functions | |
void | fillEdgeInfo (Edge *e) |
void | fillEdgesInfo () |
Protected Attributes | |
EdgeCompareMode | edgeCompareMode |
The template class for representing an abstract tree without specifing the dimensionality of the exact parameterization of the nodes. This definition is passed in via the Operation (Ops) template class.
Definition at line 91 of file posegraph.h.
typedef Ops::BaseType AISNavigation::TreePoseGraph< Ops >::BaseType |
Definition at line 92 of file posegraph.h.
typedef Ops::CovarianceType AISNavigation::TreePoseGraph< Ops >::Covariance |
Definition at line 97 of file posegraph.h.
typedef EVComparator<Edge*>::CompareMode AISNavigation::TreePoseGraph< Ops >::EdgeCompareMode |
Definition at line 118 of file posegraph.h.
typedef std::list< Edge* > AISNavigation::TreePoseGraph< Ops >::EdgeList |
Definition at line 119 of file posegraph.h.
typedef std::map< Edge*, Edge* > AISNavigation::TreePoseGraph< Ops >::EdgeMap |
Definition at line 122 of file posegraph.h.
typedef std::multiset< Edge*, EVComparator<Edge*> > AISNavigation::TreePoseGraph< Ops >::EdgeSet |
Definition at line 123 of file posegraph.h.
typedef Ops::InformationType AISNavigation::TreePoseGraph< Ops >::Information |
Definition at line 98 of file posegraph.h.
typedef Ops::ParametersType AISNavigation::TreePoseGraph< Ops >::Parameters |
Definition at line 99 of file posegraph.h.
typedef Ops::PoseType AISNavigation::TreePoseGraph< Ops >::Pose |
Definition at line 93 of file posegraph.h.
typedef Ops::RotationType AISNavigation::TreePoseGraph< Ops >::Rotation |
Definition at line 94 of file posegraph.h.
typedef Ops::TransformationType AISNavigation::TreePoseGraph< Ops >::Transformation |
Definition at line 96 of file posegraph.h.
typedef Ops::TranslationType AISNavigation::TreePoseGraph< Ops >::Translation |
Definition at line 95 of file posegraph.h.
typedef std::map< int, Vertex* > AISNavigation::TreePoseGraph< Ops >::VertexMap |
Definition at line 120 of file posegraph.h.
typedef std::set< Vertex* > AISNavigation::TreePoseGraph< Ops >::VertexSet |
Definition at line 121 of file posegraph.h.
|
inline |
constructor
Definition at line 220 of file posegraph.h.
|
virtual |
Destructor
Edge* AISNavigation::TreePoseGraph< Ops >::addEdge | ( | Vertex * | v1, |
Vertex * | v2, | ||
const Transformation & | t, | ||
const Information & | i | ||
) |
Add an edge/constraint to the graph
Edge* AISNavigation::TreePoseGraph< Ops >::addIncrementalEdge | ( | int | id1, |
int | id2, | ||
const Transformation & | t, | ||
const Information & | i | ||
) |
Adds en edge incrementally to the tree. It builds a simple tree and initializes the structures for the optimization.
This function is for online processing. It requires that at least one vertex is already present in the graph. The vertices are represented by their ids.
Once the edge is introduced in the structure:
Vertex* AISNavigation::TreePoseGraph< Ops >::addVertex | ( | int | id, |
const Pose & | pose | ||
) |
Add a vertex to the graph
EdgeSet* AISNavigation::TreePoseGraph< Ops >::affectedEdges | ( | Vertex * | v | ) |
Returns a set of edges which are accected by the mofification of the vertex v. The set is ordered according to the level of their top node.
EdgeSet* AISNavigation::TreePoseGraph< Ops >::affectedEdges | ( | VertexSet & | vl | ) |
bool AISNavigation::TreePoseGraph< Ops >::buildMST | ( | int | id | ) |
Constructs the tree be computing a minimal spanning tree
bool AISNavigation::TreePoseGraph< Ops >::buildSimpleTree | ( | ) |
Constructs the incremental tree according to the input trajectory
void AISNavigation::TreePoseGraph< Ops >::clear | ( | ) |
Delete all edges and vertices
void AISNavigation::TreePoseGraph< Ops >::compressIndices | ( | ) |
remove gaps in the indices of the vertex ids
Edge* AISNavigation::TreePoseGraph< Ops >::edge | ( | int | id1, |
int | id2 | ||
) |
Returns the edge between the two vertices
const Edge* AISNavigation::TreePoseGraph< Ops >::edge | ( | int | id1, |
int | id2 | ||
) | const |
Returns a const pointer tothe edge between the two vertices
|
protected |
|
protected |
|
pure virtual |
Revert edge info. This function needs to be implemented by a subclass
Implemented in AISNavigation::TreePoseGraph3, and AISNavigation::TreePoseGraph2.
int AISNavigation::TreePoseGraph< Ops >::maxIndex | ( | ) |
compute the highest index of an vertex
int AISNavigation::TreePoseGraph< Ops >::maxPathLength | ( | ) |
Determines the length of the longest path in the tree
Edge* AISNavigation::TreePoseGraph< Ops >::removeEdge | ( | Edge * | eq | ) |
Remove an edge/constraint from the graph
Vertex* AISNavigation::TreePoseGraph< Ops >::removeVertex | ( | int | id | ) |
Remove a vertex from the graph
void AISNavigation::TreePoseGraph< Ops >::revertEdge | ( | Edge * | e | ) |
Trun around an edge (used to ensure a certain oder on the vertexes)
|
pure virtual |
Revert edge info. This function needs to be implemented by a subclass
Implemented in AISNavigation::TreePoseGraph3, and AISNavigation::TreePoseGraph2.
bool AISNavigation::TreePoseGraph< Ops >::sanityCheck | ( | ) |
performs a consistency check on the tree and the graph structure.
EdgeSet* AISNavigation::TreePoseGraph< Ops >::sortEdges | ( | ) |
Sort constraints for correct processing order
int AISNavigation::TreePoseGraph< Ops >::totalPathLength | ( | ) |
Determines the path length of all pathes in the tree
void AISNavigation::TreePoseGraph< Ops >::treeBreadthVisit | ( | Action & | act | ) |
Function to perform a breadth-first visit of the nodes in the tree to carry out a specific action act
void AISNavigation::TreePoseGraph< Ops >::treeDepthVisit | ( | Action & | act, |
Vertex * | v | ||
) |
Function to perform a depth-first visit of the nodes in the tree to carry out a specific action act
Vertex* AISNavigation::TreePoseGraph< Ops >::vertex | ( | int | id | ) |
Returns the vertex with the given id
const Vertex* AISNavigation::TreePoseGraph< Ops >::vertex | ( | int | id | ) | const |
Returns a const pointer to the vertex with the given id
|
protected |
Definition at line 265 of file posegraph.h.
EdgeMap AISNavigation::TreePoseGraph< Ops >::edges |
All edges
Definition at line 254 of file posegraph.h.
Vertex* AISNavigation::TreePoseGraph< Ops >::root |
The root node of the tree
Definition at line 248 of file posegraph.h.
EdgeSet* AISNavigation::TreePoseGraph< Ops >::sortedEdges |
The constraints/edges sorted according to the level in the tree in order to allow us the efficient update (pose computation) of the nodes in the tree (see the RSS07 paper for further details)
Definition at line 260 of file posegraph.h.
VertexMap AISNavigation::TreePoseGraph< Ops >::vertices |
All vertices
Definition at line 251 of file posegraph.h.