README.md
- ros2 download link: https://github.com/ros2/ros2/releases/tag/release-dashing-20210610. There can download pre_built pkgs for different platforms and source pkgs.
- cartographer-master install tutorials
(1) unzip cartographer-master.zip file
(2) copy "thirdparty" directory to "cartographer-master" directory
(3) cd into "thirdparty" dir and "unzip" or "tar -xvf" these files
(4) compile every pkgs:
cd "pkg"
mkdir build & cd build
cmake .. -DBUILD_SHARED_LIBS=ON
make -j2
make install
remember compile them one by one: abseil googletest gflags glog lua boost protobuf ceres_solver
(5) cd "cartographer-master" dir
mkdir build & cd build
cmake .. -DBUILD_SHARED_LIBS=ON -DCMAKE_INSTALL_PREFIX=../install
make -j2
make install
just wait and you can get libs and includes in install dir
- install ros-melodic and cartographer_ros
if you want to try ros2,please follow the step-1. but cartographer support no well for ros2, so ros1 recommended.
(1) follow these steps by link:http://wiki.ros.org/cn/melodic/Installation/Ubuntu, if sudo rosdep init failed beacause of network,try "sudo vim /etc/hosts" and add "151.101.84.133 raw.githubusercontent.com" at the last line. Then cd main dir and "mkdir -p cartographer_ws/src" and cd to cartographer_ws/src and "catkin_init_workspace"
(2) "unzip cartographer_ros.zip" and copy to cartographer_ws/src that created before. please modify the CMakeLists.txt before the line with find_package(cartographer REQUIRED) as your own cartographer.so install_dir in all pkgs
"cd cartographer_ws"
"catkin_make -j2"
"source /opt/ros/melodic/setup.bash"
"source devel/setup.bash"
Attention: configuration_files ".lua" have been copied to cartographer_ws. so just test it.
- test cartographer_ros
(1) download bag datasets or record your own data
wget -P ~/Downloads https://storage.googleapis.com/cartographer-public-data/bags/backpack_2d/b2-2016-04-05-14-44-52.bag
wget -P ~/Downloads https://storage.googleapis.com/cartographer-public-data/bags/backpack_2d/b2-2016-04-27-12-31-41.bag
(2) run demo
roslaunch cartographer_ros demo_backpack_2d.launch bag_filename:=${BAG_DIR}/cartographer_paper_deutsches_museum.bag
- Have a wonderful learning trip. Thanks. and reference to the papers in the Books dir.