mirror of
https://github.com/introlab/rtabmap_ros.git
synced 2026-10-12 12:39:50 +08:00
icp_odometry: auto set scan_cloud_max_points if received cloud is organized (we know full dimension)
This commit is contained in:
@@ -5,14 +5,16 @@
|
|||||||
Hand-held 3D lidar mapping example using only a Ouster OS-1 (no camera).
|
Hand-held 3D lidar mapping example using only a Ouster OS-1 (no camera).
|
||||||
Prerequisities: rtabmap should be built with libpointmatcher
|
Prerequisities: rtabmap should be built with libpointmatcher
|
||||||
Example:
|
Example:
|
||||||
$ roslaunch rtabmap_ros test_ouster.launch
|
$ roslaunch rtabmap_ros test_ouster.launch os1_hostname:=os1-XXXXXXXXXXXX.local os1_udp_dest:=192.168.1.XXX
|
||||||
$ rosrun rviz rviz -f map
|
$ rosrun rviz rviz -f map
|
||||||
$ Show TF and /rtabmap/cloud_map topics
|
$ Show TF and /rtabmap/cloud_map topics
|
||||||
|
ISSUE: You may have to reset odometry after receiving the first cloud if the map looks tilted. The problem seems
|
||||||
|
coming from the first cloud sent by os1_cloud_node, which may be poorly synchronized with IMU data.
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<!-- Required: -->
|
<!-- Required: -->
|
||||||
<arg name="os1_hostname" default=""/>
|
<arg name="os1_hostname"/>
|
||||||
<arg name="os1_udp_dest" default=""/>
|
<arg name="os1_udp_dest"/>
|
||||||
|
|
||||||
<arg name="frame_id" default="os1_sensor"/>
|
<arg name="frame_id" default="os1_sensor"/>
|
||||||
<arg name="rtabmapviz" default="true"/>
|
<arg name="rtabmapviz" default="true"/>
|
||||||
@@ -107,7 +109,7 @@
|
|||||||
<param name="Grid/GroundIsObstacle" type="string" value="true"/>
|
<param name="Grid/GroundIsObstacle" type="string" value="true"/>
|
||||||
|
|
||||||
<!-- ICP parameters -->
|
<!-- ICP parameters -->
|
||||||
<param name="Icp/VoxelSize" type="string" value="0.3"/>
|
<param name="Icp/VoxelSize" type="string" value="0.2"/>
|
||||||
<param name="Icp/PointToPlaneK" type="string" value="20"/>
|
<param name="Icp/PointToPlaneK" type="string" value="20"/>
|
||||||
<param name="Icp/PointToPlaneRadius" type="string" value="0"/>
|
<param name="Icp/PointToPlaneRadius" type="string" value="0"/>
|
||||||
<param name="Icp/PointToPlane" type="string" value="false"/>
|
<param name="Icp/PointToPlane" type="string" value="false"/>
|
||||||
|
|||||||
@@ -291,7 +291,13 @@ private:
|
|||||||
ROS_ERROR("TF of received scan cloud at time %fs is not set, aborting rtabmap update.", cloudMsg->header.stamp.toSec());
|
ROS_ERROR("TF of received scan cloud at time %fs is not set, aborting rtabmap update.", cloudMsg->header.stamp.toSec());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if(scanCloudMaxPoints_ == 0 && cloudMsg->height > 1)
|
||||||
|
{
|
||||||
|
scanCloudMaxPoints_ = cloudMsg->height * cloudMsg->width;
|
||||||
|
NODELET_WARN("IcpOdometry: \"scan_cloud_max_points\" is not set but input "
|
||||||
|
"cloud is not dense, for convenience it will be set to %d (%dx%d)",
|
||||||
|
scanCloudMaxPoints_, cloudMsg->width, cloudMsg->height);
|
||||||
|
}
|
||||||
int maxLaserScans = scanCloudMaxPoints_;
|
int maxLaserScans = scanCloudMaxPoints_;
|
||||||
if(containNormals)
|
if(containNormals)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user