10.4 Cartographer介绍与安装 1.Cartographer介绍 ![Cartographer 3D SLAM Demo](https://camo.githubusercontent.com/10d0032636bb1b2a266209bdc0b4fa48ab9ef9fb47dcf834701aa8a50384ddc3/68747470733a2f2f6a2e676966732e636f6d2f777033424a4d2e676966) Cartographer是Google开源的一个可跨多个平台和传感器配置以2D和3D形式提供实时同时定位和建图(SLAM)的系统。 > github地址:https://github.com/cartographer-project/cartographer > 文档地址:https://google-cartographer.readthedocs.io/en/latest 在小鱼呆过的机器人公司里,做建图最终方案都是采用了Cartographer,甚至花费大量人力物力对Cartographer算法进行裁剪,这足以表明Cartographer算法的优越性。 > Cartographer系统架构概述(简单看看即可,如果大家后面确定研究方向是SLAM可以深入学习): > ![系统概述](10.4Cartographer介绍与安装/imgs/high_level_system_overview.png) 2.Carttographer安装 2.1 apt安装 安装`carotgrapher` ``` sudo apt install ros-foxy-cartographer ``` 需要注意我们不是直接使用`cartographer`,而是通过`cartographer-ros`功能包进行相关操作,所以我们还需要安装下`cartographer-ros` ``` sudo apt install ros-foxy-cartographer-ros ``` 2.2 源码安装 将下面的源码克隆到src目录下: ``` git clone https://ghproxy.com/https://github.com/ros2/cartographer.git -b foxy git clone https://ghproxy.com/https://github.com/ros2/cartographer_ros.git -b dashing ``` 安装依赖 ``` rosdepc install -r --from-paths . --ignore-src --rosdistro $ROS_DISTRO -y ``` ``` absl依赖 ``` 编译 ``` colcon build --packages-up-to cartographer_ros ``` -------------- 技术交流&&问题求助: - **微信公众号及交流群:鱼香ROS** - **小鱼微信:AiIotRobot** - **QQ交流群:139707339** - 版权保护:已加入“维权骑士”(rightknights.com)的版权保护计划