Main MRPT website > C++ reference for MRPT 1.5.6
CLogFileRecord.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 #ifndef CLogFileRecord_H
10 #define CLogFileRecord_H
11 
15 #include <mrpt/utils/TParameters.h>
16 
21 
22 namespace mrpt
23 {
24 namespace nav
25 {
27 
28  /** A class for storing, saving and loading a reactive navigation
29  * log record for the CReactiveNavigationSystem class.
30  * \sa CReactiveNavigationSystem, CHolonomicLogFileRecord
31  * \ingroup nav_reactive
32  */
33  class NAV_IMPEXP CLogFileRecord : public mrpt::utils::CSerializable
34  {
36 
37  public:
38  CLogFileRecord(); //!< Constructor, builds an empty record.
39 
40  /** The structure used to store all relevant information about each
41  * transformation into TP-Space.
42  * \ingroup nav_reactive */
44  {
45  std::string PTG_desc; //!< A short description for the applied PTG
46  mrpt::math::CVectorFloat TP_Obstacles; //!< Distances until obstacles, in "pseudometers", first index for -PI direction, last one for PI direction.
47  std::vector<mrpt::math::TPoint2D> TP_Targets; //!< Target(s) location in TP-Space
48  mrpt::math::TPoint2D TP_Robot; //!< Robot location in TP-Space: normally (0,0), except during "NOP cmd vel" steps
49  double timeForTPObsTransformation,timeForHolonomicMethod; //!< Time, in seconds.
50  double desiredDirection,desiredSpeed; //!< The results from the holonomic method.
51  double evaluation; //!< Final score of this candidate
53  CHolonomicLogFileRecordPtr HLFR; //!< Other useful info about holonomic method execution.
54  mrpt::nav::CParameterizedTrajectoryGeneratorPtr ptg; //!< Only for the FIRST entry in a log file, this will contain a copy of the PTG with trajectories, suitable to render trajectories, etc.
55  mrpt::nav::ClearanceDiagram clearance; //!< Clearance for each path
56  };
57 
59  uint32_t nPTGs; //!< The number of PTGS:
60  mrpt::aligned_containers<TInfoPerPTG>::vector_t infoPerPTG; //!< The info for each applied PTG: must contain "nPTGs * nSecDistances" elements
61  int32_t nSelectedPTG; //!< The selected PTG.
62 
63  /** Known values:
64  * - "executionTime": The total computation time, excluding sensing.
65  * - "estimatedExecutionPeriod": The estimated execution period.
66  */
67  std::map<std::string, double> values;
68  /** Known values:
69  * - "tim_start_iteration": Time of start of navigationStep() implementation.
70  * - "tim_send_cmd_vel": Time of sending cmdvel to robot.
71  * - "curPoseAndVel": Time of querying robot pose and velocities.
72  */
73  std::map<std::string, mrpt::system::TTimeStamp> timestamps;
74  std::map<std::string, std::string> additional_debug_msgs; //!< Additional debug traces
75  mrpt::maps::CSimplePointsMap WS_Obstacles, WS_Obstacles_original; //!< The WS-Obstacles
76  mrpt::math::TPose2D robotPoseLocalization, robotPoseOdometry; //!< The robot pose (from odometry and from the localization/SLAM system).
77  mrpt::math::TPose2D relPoseSense, relPoseVelCmd; //! Relative poses (wrt to robotPoseLocalization) for extrapolated paths at two instants: time of obstacle sense, and future pose of motion comman
78  std::vector<mrpt::math::TPose2D> WS_targets_relative; //!< The relative location of target(s) in Workspace.
79 
80  mrpt::kinematics::CVehicleVelCmdPtr cmd_vel; //!< The final motion command sent to robot, in "m/sec" and "rad/sec".
81  mrpt::kinematics::CVehicleVelCmdPtr cmd_vel_original; //!< Motion command as comes out from the PTG, before scaling speed limit filtering.
82  mrpt::math::TTwist2D cur_vel; //!< The actual robot velocities in global (map) coordinates, as read from sensors, in "m/sec" and "rad/sec".
83  mrpt::math::TTwist2D cur_vel_local; //!< The actual robot velocities in local (robot) coordinates, as read from sensors, in "m/sec" and "rad/sec".
84 
85  mrpt::math::CVectorFloat robotShape_x,robotShape_y; //!< The robot shape in WS. Used by PTGs derived from mrpt::nav::CPTG_RobotShape_Polygonal
86  double robotShape_radius; //!< The circular robot radius. Used by PTGs derived from mrpt::nav::CPTG_RobotShape_Circular
87 
88  // "NOP motion command" mode variables:
89  int16_t ptg_index_NOP; //!< Negative means no NOP mode evaluation, so the rest of "NOP variables" should be ignored.
91  mrpt::math::TPose2D rel_cur_pose_wrt_last_vel_cmd_NOP, rel_pose_PTG_origin_wrt_sense_NOP;
93  };
95 
96 }
97 }
98 
99 
100 #endif
101 
int32_t nSelectedPTG
The selected PTG.
unsigned __int16 uint16_t
Definition: rptypes.h:46
std::vector< mrpt::math::TPose2D > WS_targets_relative
Relative poses (wrt to robotPoseLocalization) for extrapolated paths at two instants: time of obstacl...
mrpt::math::CVectorFloat robotShape_y
The robot shape in WS. Used by PTGs derived from mrpt::nav::CPTG_RobotShape_Polygonal.
mrpt::math::TTwist2D cur_vel_local
The actual robot velocities in local (robot) coordinates, as read from sensors, in "m/sec" and "rad/s...
The virtual base class which provides a unified interface for all persistent objects in MRPT...
Definition: CSerializable.h:39
std::map< std::string, mrpt::system::TTimeStamp > timestamps
Known values:
mrpt::nav::ClearanceDiagram clearance
Clearance for each path.
mrpt::math::TPose2D rel_pose_PTG_origin_wrt_sense_NOP
mrpt::math::TPose2D robotPoseOdometry
The robot pose (from odometry and from the localization/SLAM system).
Column vector, like Eigen::MatrixX*, but automatically initialized to zeros since construction...
Definition: eigen_frwds.h:35
std::vector< mrpt::math::TPoint2D > TP_Targets
Target(s) location in TP-Space.
A cloud of points in 2D or 3D, which can be built from a sequence of laser scans. ...
uint32_t nPTGs
The number of PTGS:
Clearance information for one particular PTG and one set of obstacles.
A class for storing, saving and loading a reactive navigation log record for the CReactiveNavigationS...
mrpt::utils::TParametersDouble evalFactors
Evaluation factors.
CHolonomicLogFileRecordPtr HLFR
Other useful info about holonomic method execution.
2D twist: 2D velocity vector (vx,vy) + planar angular velocity (omega)
mrpt::nav::CParameterizedTrajectoryGenerator::TNavDynamicState ptg_last_navDynState
#define DEFINE_SERIALIZABLE_PRE_CUSTOM_BASE_LINKAGE(class_name, base_name, _LINKAGE_)
This declaration must be inserted in all CSerializable classes definition, before the class declarati...
__int16 int16_t
Definition: rptypes.h:45
mrpt::math::TPoint2D TP_Robot
Robot location in TP-Space: normally (0,0), except during "NOP cmd vel" steps.
int16_t ptg_index_NOP
Negative means no NOP mode evaluation, so the rest of "NOP variables" should be ignored.
mrpt::kinematics::CVehicleVelCmdPtr cmd_vel_original
Motion command as comes out from the PTG, before scaling speed limit filtering.
mrpt::kinematics::CVehicleVelCmdPtr cmd_vel
The final motion command sent to robot, in "m/sec" and "rad/sec".
mrpt::aligned_containers< TInfoPerPTG >::vector_t infoPerPTG
The info for each applied PTG: must contain "nPTGs * nSecDistances" elements.
mrpt::nav::CParameterizedTrajectoryGeneratorPtr ptg
Only for the FIRST entry in a log file, this will contain a copy of the PTG with trajectories, suitable to render trajectories, etc.
mrpt::maps::CSimplePointsMap WS_Obstacles_original
The WS-Obstacles.
std::map< std::string, double > values
Known values:
std::string PTG_desc
A short description for the applied PTG.
__int32 int32_t
Definition: rptypes.h:48
#define DEFINE_SERIALIZABLE(class_name)
This declaration must be inserted in all CSerializable classes definition, within the class declarati...
mrpt::math::CVectorFloat TP_Obstacles
Distances until obstacles, in "pseudometers", first index for -PI direction, last one for PI directio...
GLsizei const GLcharARB ** string
Definition: glew.h:3293
mrpt::nav::CParameterizedTrajectoryGenerator::TNavDynamicState navDynState
mrpt::math::TTwist2D cur_vel
The actual robot velocities in global (map) coordinates, as read from sensors, in "m/sec" and "rad/se...
Lightweight 2D pose.
unsigned __int32 uint32_t
Definition: rptypes.h:49
#define DEFINE_SERIALIZABLE_POST_CUSTOM_BASE_LINKAGE(class_name, base_name, _LINKAGE_)
Lightweight 2D point.
Dynamic state that may affect the PTG path parameterization.
mrpt::math::TPose2D relPoseVelCmd
std::vector< TYPE1, Eigen::aligned_allocator< TYPE1 > > vector_t
The structure used to store all relevant information about each transformation into TP-Space...
double evaluation
Final score of this candidate.
std::map< std::string, std::string > additional_debug_msgs
Additional debug traces.
double desiredSpeed
The results from the holonomic method.
double robotShape_radius
The circular robot radius. Used by PTGs derived from mrpt::nav::CPTG_RobotShape_Circular.



Page generated by Doxygen 1.8.6 for MRPT 1.5.6 Git: 4c65e84 Tue Apr 24 08:18:17 2018 +0200 at mar abr 24 08:26:17 CEST 2018