41 m_actions.push_back( CActionPtr( static_cast<CAction*>(
a.duplicate()) ) );
135 CActionRobotMovement2DPtr bestEst;
136 double bestDet = 1e3;
143 CActionRobotMovement2DPtr temp = CActionRobotMovement2DPtr( it->get_ptr() );
150 double det = temp->poseChange->getCovariance().det();
187 CActionRobotMovement2DPtr temp = CActionRobotMovement2DPtr( it->get_ptr() );
190 if ( temp->estimationMethod == method )
199 return CActionRobotMovement2DPtr();
220 CActionRobotMovement3DPtr act3D = getActionByClass<CActionRobotMovement3D>();
223 out_pose_increment = act3D->poseChange.mean;
226 CActionRobotMovement2DPtr act2D = getActionByClass<CActionRobotMovement2D>();
229 out_pose_increment =
CPose3D(act2D->poseChange->getMeanVal());
240 CActionRobotMovement3DPtr act3D = getActionByClass<CActionRobotMovement3D>();
243 out_pose_increment = act3D->poseChange;
246 CActionRobotMovement2DPtr act2D = getActionByClass<CActionRobotMovement2D>();
249 out_pose_increment.
copyFrom( *act2D->poseChange );
EIGEN_STRONG_INLINE Scalar det() const
void writeToStream(mrpt::utils::CStream &out, int *getVersion) const
Introduces a pure virtual method responsible for writing to a CStream.
Classes for serialization, sockets, ini-file manipulation, streams, list of properties-values, timewatch, extensions to STL.
bool getFirstMovementEstimationMean(mrpt::poses::CPose3D &out_pose_increment) const
Look for the first 2D or 3D "odometry" found in this collection of actions, and return the "mean" inc...
void copyFrom(const CPose3DPDF &o) MRPT_OVERRIDE
Copy operator, translating if necesary (for example, between particles and gaussian representations) ...
The virtual base class which provides a unified interface for all persistent objects in MRPT...
const_iterator end() const
Returns a iterator pointing to the end of the list: this is an example of usage:
#define THROW_EXCEPTION(msg)
IMPLEMENTS_SERIALIZABLE(CLogFileRecord_FullEval, CHolonomicLogFileRecord, mrpt::nav) IMPLEMENTS_SERIALIZABLE(CHolonomicFullEval
std::deque< mrpt::utils::poly_ptr_ptr< CActionPtr > >::const_iterator const_iterator
You can use CActionCollection::begin to get a iterator to the first element.
Declares a class for storing a collection of robot actions.
std::deque< mrpt::utils::poly_ptr_ptr< CActionPtr > >::iterator iterator
You can use CActionCollection::begin to get a iterator to the first element.
Represents a probabilistic 2D movement of the robot mobile base.
This base class is used to provide a unified interface to files,memory buffers,..Please see the deriv...
#define MRPT_THROW_UNKNOWN_SERIALIZATION_VERSION(__V)
For use in CSerializable implementations.
void clear()
Erase all actions from the list.
This namespace contains representation of robot actions and observations.
TEstimationMethod
A list of posible ways for estimating the content of a CActionRobotMovement2D object.
Classes for 2D/3D geometry representation, both of single values and probability density distribution...
iterator erase(const iterator &it)
Removes the given action in the list, and return an iterator to the next element (or this->end() if i...
Declares a class for storing a robot action.
#define CLASS_ID(class_name)
Access to runtime class ID for a defined class name.
This is the global namespace for all Mobile Robot Programming Toolkit (MRPT) libraries.
virtual CObject * duplicate() const =0
Returns a copy of the object, indepently of its class.
A class used to store a 3D pose (a 3D translation + a rotation in 3D).
void readFromStream(mrpt::utils::CStream &in, int version)
Introduces a pure virtual method responsible for loading from a CStream This can not be used directly...
CActionPtr get(size_t index)
Access the i'th action.DO NOT MODIFY the returned object, make a copy of ir with "CSerializable::dupl...
CActionRobotMovement2DPtr getBestMovementEstimation() const
Returns the best pose increment estimator in the collection, based on the determinant of its pose cha...
Declares a class that represents a Probability Density function (PDF) of a 3D pose ...
size_t size()
Returns the actions count in the collection.
std::deque< mrpt::utils::poly_ptr_ptr< CActionPtr > > m_actions
The robot "actionss".
void eraseByIndex(const size_t &index)
Remove an action from the list by its index.
CActionRobotMovement2DPtr getMovementEstimationByType(CActionRobotMovement2D::TEstimationMethod method)
Returns the pose increment estimator in the collection having the specified type. ...
unsigned __int32 uint32_t
GLubyte GLubyte GLubyte a
const_iterator begin() const
Returns a iterator to the first action: this is an example of usage:
bool getFirstMovementEstimation(mrpt::poses::CPose3DPDFGaussian &out_pose_increment) const
Look for the first 2D or 3D "odometry" found in this collection of actions, and return the "mean" inc...
void insert(CAction &action)
Add a new object to the list.