当前位置:网站首页>ROS learning (XX) robot slam function package -- installation and testing of rgbdslam
ROS learning (XX) robot slam function package -- installation and testing of rgbdslam
2022-07-07 01:52:00 【Ice cream with code】
List of articles
Preface
In the previous study ,slam The constructed maps are all two-dimensional maps , At present, many algorithms can realize the map construction of three-dimensional information , Robots not only know where obstacles are in the map , And also know what the obstacle is .
ROS Provides a variety of 3D SLAM Function pack ,rgbdslam That's one of them , This chapter mainly studies rgbdslam Installation and testing of .
One 、 New workspace
The order is as follows :
mkdir -p ~/catkin_rgbdslam_ws/src
cd ~/catkin_rgbdslam_ws/src
catkin_init_workspace
cd ~/catkin_rgbdslam_ws
catkin_make
Two 、 download rgbdslam_v2 Corresponding to the author g2o
The order is as follows :
cd ~/catkin_rgbdslam_ws/src
sudo apt-get install libsuitesparse-dev
git clone https://github.com/felixendres/g2o.git
cd g2o
mkdir build
cd build
cmake ..
make..
sudo make install
among , The second command is responsible for installing dependencies .
3、 ... and 、 install pcl1.8
download , The order is as follows :
cd ~
wget https://github.com/PointCloudLibrary/pcl/archive/pcl-1.8.0.tar.gz
tar -xvzf pcl-pcl-1.8.0.tar.gz
cd ~/pcl-pcl-1.8.0
gedit CMakeLists.txt
Add the following to CMakeLists.txt Of the 146 That's ok ( stay endif() after ), Add C++11 Support :
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
compile 、 install , The order is as follows :
cd ~/pcl-pcl-1.8.0
mkdir build
cd build
cmake ../
make VERBOSE=1
sudo make install
Four 、 To configure rgbdslam_v2
The order is as follows :
cd ~/catkin_rgbdslam_ws/src
git clone https://github.com/felixendres/rgbdslam_v2
cd rgbdslam_v2
gedit CMakeLists.txt
modify CMakeLists The contents of the document , take
find_package(PCL 1.7 REQUIRED COMPONENTS common io)
Change it to :
find_package(PCL 1.8 REQUIRED COMPONENTS common io)
And add the following at the lowest end :
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
modify /opt/ros/kinetic/share/pcl_ros/cmake/pcl_rosConfig.cmake file , Will all /usr/lib/x86_64-linux-gnu/libpcl_ Change the beginning to /usr/local/lib/libpcl_( A total of 34 individual )
5、 ... and 、 structure siftgpu library
The order is as follows :
cd ~/catkin_rgbdslam_ws/src/rgbdslam_v2/external/SiftGPU
sudo apt-get install libglew-dev
sudo apt-get install libdevil1c2 libdevil-dev
make
6、 ... and 、 compile rgbdslam_v2
The order is as follows :
cd ~/catkin_rgbdslam_ws
catkin_make
cd build/rgbdslam_v2
make VERBOSE=1
make install
If compiled opencv error , According to this blog openCV Step on the pit diary To operate , Then recompile .
7、 ... and 、 test
1、 A simple test
Open a new terminal , function roscore
roscore
Switch to /catkin_rgbdslam_ws/devel/lib/rgbdslam/ Under the table of contents , Open another terminal , Run the following command :
./rgbdslam
The interface is as follows :
If this interface displays normally , Then prove rgbdslam Installation successful .
2、 Dataset testing
Download datasets , Download address :http://vision.in.tum.de/data/datasets/rgbd-dataset/download#freiburg1_room, Will download okay .bag The documents are stored in catkin_rgbdslam_ws/rgdb_data Under the table of contents .
modify rgdbslam.launch file , Make sure the topic you subscribe to is consistent with the data set , The modification is as follows :
<param name="config/topic_image_mono" value="/camera/rgb/image_color"/>
<param name="config/topic_image_depth" value="/camera/depth/image"/>
Open the terminal , Enter the command as follows :
roscore
Switch to rgdbslam_v2/launch Under the table of contents , Open a new terminal , The order is as follows :
roslaunch rgbdslam rgbdslam.launch
The interface is as follows :
Switch to catkin_rgbdslam_ws/rgdb_data Under the table of contents , Open a new terminal , The order is as follows :
rosbag play rgbd_dataset_freiburg1_room.bag
When the data package starts publishing data , You can see the image data and slam The process of , as follows :
When the construction is finished , Directly select Save as point cloud data in the menu bar , I keep it in rgdb_data Under the table of contents , The file named quicksave.pcd.
have access to pcl_ros Function pack view the saved point cloud map :
rosrun pcl_ros pcd_to_pointcloud quicksave.pcd
边栏推荐
- 刨析《C语言》【进阶】付费知识【二】
- First experience of JSON learning - the third-party jar package realizes bean, list and map to create JSON format
- When grep looks for a process, it ignores the grep process itself
- Hutool post requests to set the body parameter to JSON data
- 盒子拉伸拉扯(左右模式)
- Clickhouse fields are grouped and aggregated, and SQL is queried according to the granularity of any time period
- C语言【23道】经典面试题【下】
- HDU 4661 message passing (wood DP & amp; Combinatorics)
- 长按按钮执行函数
- ROS学习(23)action通信机制
猜你喜欢
Shell script quickly counts the number of lines of project code
百度飞将BMN时序动作定位框架 | 数据准备与训练指南 (下)
ROS学习(22)TF变换
Comparison of picture beds of free white whoring
AcWing 1148. 秘密的牛奶运输 题解(最小生成树)
454 Baidu Mianjing 1
Appium automation test foundation uiautomatorviewer positioning tool
ROS学习(十九)机器人SLAM功能包——cartographer
sql中批量删除数据---实体中的集合
Mongodb checks whether the table is imported successfully
随机推荐
AcWing 1141. 局域网 题解(kruskalkruskal 求最小生成树)
ROS学习(25)rviz plugin插件
JVM memory model
IDEA常用的快捷键
LeetCode. Sword finger offer 62 The last remaining number in the circle
Appium foundation - appium inspector positioning tool (I)
2022/0524/bookstrap
C语言关于链表的代码看不懂?一篇文章让你拿捏二级指针并深入理解函数参数列表中传参的多种形式
【唯一】的“万字配图“ | 讲透【链式存储结构】是什么?
Scenario practice: quickly build wordpress blog system based on function calculation
C language instance_ three
ZOJ Problem Set – 2563 Long Dominoes 【如压力dp】
tansig和logsig的差异,为什么BP喜欢用tansig
What does security capability mean? What are the protection capabilities of different levels of ISO?
NPM install compilation times "cannot read properties of null (reading 'pickalgorithm')“
JS reverse -- ob confusion and accelerated music that poked the [hornet's nest]
AcWing 904. 虫洞 题解(spfa求负环)
How did partydao turn a tweet into a $200million product Dao in one year
454-百度面经1
我如何编码8个小时而不会感到疲倦。