41 #ifndef PCL_REGISTRATION_LUM_H_
42 #define PCL_REGISTRATION_LUM_H_
44 #include <pcl/pcl_base.h>
45 #include <pcl/registration/eigen.h>
46 #include <pcl/registration/boost.h>
47 #include <pcl/common/transforms.h>
48 #include <pcl/correspondence.h>
49 #include <pcl/registration/boost_graph.h>
59 namespace registration
109 template<
typename Po
intT>
113 typedef boost::shared_ptr<LUM<PointT> >
Ptr;
114 typedef boost::shared_ptr<const LUM<PointT> >
ConstPtr;
124 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
131 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
134 typedef boost::adjacency_list<boost::eigen_vecS, boost::eigen_vecS, boost::bidirectionalS, VertexProperties, EdgeProperties, boost::no_property, boost::eigen_listS>
SLAMGraph;
136 typedef typename SLAMGraph::vertex_descriptor
Vertex;
137 typedef typename SLAMGraph::edge_descriptor
Edge;
142 : slam_graph_ (new SLAMGraph)
143 , max_iterations_ (5)
144 , convergence_threshold_ (0.0)
169 typename SLAMGraph::vertices_size_type
224 setPointCloud (
const Vertex &vertex,
const PointCloudPtr &cloud);
251 getPose (
const Vertex &vertex)
const;
258 inline Eigen::Affine3f
274 const Vertex &target_vertex,
331 SLAMGraphPtr slam_graph_;
337 float convergence_threshold_;
342 #ifdef PCL_NO_PRECOMPILE
343 #include <pcl/registration/impl/lum.hpp>
346 #endif // PCL_REGISTRATION_LUM_H_
void setCorrespondences(const Vertex &source_vertex, const Vertex &target_vertex, const pcl::CorrespondencesPtr &corrs)
Add/change a set of correspondences for one of the SLAM graph's edges.
boost::shared_ptr< PointCloud< PointT > > Ptr
pcl::CorrespondencesPtr corrs_
Vertex addPointCloud(const PointCloudPtr &cloud, const Eigen::Vector6f &pose=Eigen::Vector6f::Zero())
Add a new point cloud to the SLAM graph.
boost::shared_ptr< const LUM< PointT > > ConstPtr
Eigen::Matrix< float, 6, 6 > Matrix6f
PointCloudPtr getPointCloud(const Vertex &vertex) const
Return a point cloud from one of the SLAM graph's vertices.
PointCloud::Ptr PointCloudPtr
SLAMGraphPtr getLoopGraph() const
Get the internal SLAM graph structure.
PointCloudPtr getTransformedCloud(const Vertex &vertex) const
Return a point cloud from one of the SLAM graph's vertices compounded onto its current pose estimate...
int getMaxIterations() const
Get the maximum number of iterations for the compute() method.
This file defines compatibility wrappers for low level I/O functions.
Eigen::Matrix< float, 6, 1 > Vector6f
void compute()
Perform LUM's globally consistent scan matching.
Globally Consistent Scan Matching based on an algorithm by Lu and Milios.
void setLoopGraph(const SLAMGraphPtr &slam_graph)
Set the internal SLAM graph structure.
Eigen::Matrix6f incidenceCorrection(const Eigen::Vector6f &pose)
Returns a pose corrected 6DoF incidence matrix.
boost::shared_ptr< const PointCloud< PointT > > ConstPtr
PointCloud::ConstPtr PointCloudConstPtr
SLAMGraph::edge_descriptor Edge
pcl::CorrespondencesPtr getCorrespondences(const Vertex &source_vertex, const Vertex &target_vertex) const
Return a set of correspondences from one of the SLAM graph's edges.
boost::adjacency_list< boost::eigen_vecS, boost::eigen_vecS, boost::bidirectionalS, VertexProperties, EdgeProperties, boost::no_property, boost::eigen_listS > SLAMGraph
Eigen::Vector6f getPose(const Vertex &vertex) const
Return a pose estimate from one of the SLAM graph's vertices.
SLAMGraph::vertices_size_type getNumVertices() const
Get the number of vertices in the SLAM graph.
Eigen::Affine3f getTransformation(const Vertex &vertex) const
Return a pose estimate from one of the SLAM graph's vertices as an affine transformation matrix...
boost::shared_ptr< LUM< PointT > > Ptr
PointCloudPtr getConcatenatedCloud() const
Return a concatenated point cloud of all the SLAM graph's point clouds compounded onto their current ...
void setPointCloud(const Vertex &vertex, const PointCloudPtr &cloud)
Change a point cloud on one of the SLAM graph's vertices.
boost::shared_ptr< Correspondences > CorrespondencesPtr
PointCloud represents the base class in PCL for storing collections of 3D points. ...
SLAMGraph::vertex_descriptor Vertex
pcl::PointCloud< PointT > PointCloud
void setMaxIterations(int max_iterations)
Set the maximum number of iterations for the compute() method.
void computeEdge(const Edge &e)
Linearized computation of C^-1 and C^-1*D (results stored in slam_graph_).
void setConvergenceThreshold(float convergence_threshold)
Set the convergence threshold for the compute() method.
float getConvergenceThreshold() const
Get the convergence threshold for the compute() method.
boost::shared_ptr< SLAMGraph > SLAMGraphPtr
void setPose(const Vertex &vertex, const Eigen::Vector6f &pose)
Change a pose estimate on one of the SLAM graph's vertices.