Main MRPT website > C++ reference for MRPT 1.5.7
CGraphSlamOptimizer.h
Go to the documentation of this file.
1 /* +---------------------------------------------------------------------------+
2  | Mobile Robot Programming Toolkit (MRPT) |
3  | http://www.mrpt.org/ |
4  | |
5  | Copyright (c) 2005-2017, Individual contributors, see AUTHORS file |
6  | See: http://www.mrpt.org/Authors - All rights reserved. |
7  | Released under BSD License. See details in http://www.mrpt.org/License |
8  +---------------------------------------------------------------------------+ */
9 
10 #ifndef CGRAPHSLAMOPTIMIZER_H
11 #define CGRAPHSLAMOPTIMIZER_H
12 
14 #include <mrpt/obs/CSensoryFrame.h>
15 #include <mrpt/obs/CObservation.h>
19 #include <mrpt/utils/TParameters.h>
20 #include <mrpt/utils/CTimeLogger.h>
21 
24 
25 namespace mrpt { namespace graphslam { namespace optimizers {
26 
27 /**\brief Interface for implementing graphSLAM optimizer classes.
28  *
29  * Class should provide a generic interface from which real optimizers should
30  * inherit so that they abide to the necessary method calls used in the
31  * CGraphSlamEngine class. For an example of inheriting from this class see
32  * CLevMarqGSO.
33  *
34  * \note As a naming convention, all the implemented graphslam optimizer classes
35  * are suffixed with the GSO acronym.
36  *
37  * \ingroup mrpt_graphslam_grp
38  */
39 template<class GRAPH_t=typename mrpt::graphs::CNetworkOfPoses2DInf>
42 {
43  public:
44  /**\brief Handy typedefs */
45  /**\{*/
46  typedef typename GRAPH_t::constraint_t constraint_t; // type of underlying constraints
47  typedef typename GRAPH_t::constraint_t::type_value pose_t; // type of underlying poses (2D/3D)
48  /**\}*/
49 
52 
53  /**\brief Generic method for fetching the incremental action/observation
54  * readings from the calling function.
55  *
56  * Implementations of this interface should use (part of) the specified
57  * parameters and call the optimizeGraph function if the decision is to
58  * optimize the provided graph
59  *
60  * \return True if the optimization procedure was executed.
61  */
62  virtual bool updateState(
63  mrpt::obs::CActionCollectionPtr action,
64  mrpt::obs::CSensoryFramePtr observations,
65  mrpt::obs::CObservationPtr observation ) = 0;
66 
67  /**\brief Used by the caller to query for possible full graph optimization
68  * on the latest optimizer run
69  */
70  virtual bool justFullyOptimizedGraph() const {return false;}
71 
72  protected:
73  /**\brief method called for optimizing the underlying graph.
74  */
75  virtual void optimizeGraph() = 0;
76 
77 };
78 
79 } } } // end of namespaces
80 
81 #endif /* end of include guard: CGRAPHSLAMOPTIMIZER_H */
GRAPH_t::constraint_t constraint_t
Handy typedefs.
virtual bool updateState(mrpt::obs::CActionCollectionPtr action, mrpt::obs::CSensoryFramePtr observations, mrpt::obs::CObservationPtr observation)=0
Generic method for fetching the incremental action/observation readings from the calling function...
Interface for implementing node/edge registration deciders or optimizer classes.
virtual void optimizeGraph()=0
method called for optimizing the underlying graph.
This is the global namespace for all Mobile Robot Programming Toolkit (MRPT) libraries.
Interface for implementing graphSLAM optimizer classes.
virtual bool justFullyOptimizedGraph() const
Used by the caller to query for possible full graph optimization on the latest optimizer run...



Page generated by Doxygen 1.8.14 for MRPT 1.5.7 Git: 5902e14cc Wed Apr 24 15:04:01 2019 +0200 at lun oct 28 01:39:17 CET 2019