Linux 35.5 + JetPack v5.1.3@ego-planner-swarm编译安装

Linux 35.5 + JetPack v5.1.3@ego-planner-swarm编译安装

  • [1. 源由](#1. 源由)
  • [2. 编译&安装](#2. 编译&安装)
    • [Step 1:依赖库安装](#Step 1:依赖库安装)
    • [Step 2:建立工程](#Step 2:建立工程)
    • [Step 3:编译工程](#Step 3:编译工程)
    • [Step 4:安装工程](#Step 4:安装工程)
  • [3. 问题汇总](#3. 问题汇总)
    • [3.1 组件ros-noetic-roslint问题](#3.1 组件ros-noetic-roslint问题)
    • [3.2 uav_simulator/local_sensing - CUDA优化](#3.2 uav_simulator/local_sensing - CUDA优化)
    • [3.3 编译命令`catkin_make`问题](#3.3 编译命令catkin_make问题)
  • [4. 总结](#4. 总结)

1. 源由

ego-planner是一个单机版本,而ego-planner-swarm是一个多级飞行的版本,因此在此一起学习下,以便更好的理解该系列开源项目的整个进展和框架。

2. 编译&安装

  • 确认本地ROS版本:
bash 复制代码
$ rosversion --distro
noetic
  • 本次编译代码版本:
bash 复制代码
$ git log -n 1
commit 30de3c9e11e6a2e06d81561f9364f07ceba6774b (HEAD -> master, origin/master, origin/HEAD)
Author: Xin Zhou <[email protected]>
Date:   Thu Mar 16 21:00:03 2023 +0800

    Update README.md

Step 1:依赖库安装

bash 复制代码
$ sudo apt-get install libarmadillo-dev

Step 2:建立工程

bash 复制代码
$ mkdir -p ${YOUR_WORKSPACE_PATH}/src
$ cd ${YOUR_WORKSPACE_PATH}/src
$ git clone [email protected]:ZJU-FAST-Lab/ego-planner-swarm.git

Step 3:编译工程

bash 复制代码
$ cd ego-planner-swarm
$ catkin_make -j1

或者

bash 复制代码
$ cd ego-planner
$ catkin_make -DCMAKE_BUILD_TYPE=Release -j1

Step 4:安装工程

略,因为暂时不涉及软件的部署应用,相关模拟命令参考:

bash 复制代码
$ source devel/setup.bash && roslaunch ego_planner simple_run.launch

或者

  1. 运行Rviz虚拟环境
bash 复制代码
$ source devel/setup.bash
$ roslaunch ego_planner rviz.launch
  1. 运行模拟程序
bash 复制代码
$ source devel/setup.bash
$ roslaunch ego_planner swarm.launch

3. 问题汇总

3.1 组件ros-noetic-roslint问题

bash 复制代码
-- +++ processing catkin package: 'drone_detect'
-- ==> add_subdirectory(planner/drone_detect)
-- Could NOT find roslint (missing: roslint_DIR)
-- Could not find the required component 'roslint'. The following CMake error indicates that you either need to install the package with the same name or change your environment so that it can be found.
CMake Error at /opt/ros/noetic/share/catkin/cmake/catkinConfig.cmake:83 (find_package):
  Could not find a package configuration file provided by "roslint" with any
  of the following names:

    roslintConfig.cmake
    roslint-config.cmake

  Add the installation prefix of "roslint" to CMAKE_PREFIX_PATH or set
  "roslint_DIR" to a directory containing one of the above files.  If
  "roslint" provides a separate development package or SDK, be sure it has
  been installed.
Call Stack (most recent call first):
  planner/drone_detect/CMakeLists.txt:12 (find_package)


-- Configuring incomplete, errors occurred!
See also "/home/daniel/ZJU-FAST-Lab/ego-planner-swarm/build/CMakeFiles/CMakeOutput.log".
See also "/home/daniel/ZJU-FAST-Lab/ego-planner-swarm/build/CMakeFiles/CMakeError.log".
Invoking "cmake" failed

**解决方案:**安装组件ros-noetic-roslint

bash 复制代码
$ sudo apt-get install ros-noetic-roslint

3.2 uav_simulator/local_sensing - CUDA优化

bash 复制代码
$ git diff src/uav_simulator/local_sensing/CMakeLists.txt
diff --git a/src/uav_simulator/local_sensing/CMakeLists.txt b/src/uav_simulator/local_sensing/CMakeLists.txt
index 13c9911..5362408 100644
--- a/src/uav_simulator/local_sensing/CMakeLists.txt
+++ b/src/uav_simulator/local_sensing/CMakeLists.txt
@@ -6,7 +6,7 @@ ADD_COMPILE_OPTIONS(-std=c++11 )
 ADD_COMPILE_OPTIONS(-std=c++14 )

 #set(ENABLE_CUDA false)
-set(ENABLE_CUDA false)
+set(ENABLE_CUDA true)

 if(ENABLE_CUDA)
   find_package(CUDA REQUIRED)
@@ -20,7 +20,8 @@ if(ENABLE_CUDA)
 #       -gencode arch=compute_52,code=sm_52;
 #       -gencode arch=compute_60,code=sm_60;
 #       -gencode arch=compute_61,code=sm_61;
-      -gencode arch=compute_75,code=sm_75;
+#       -gencode arch=compute_75,code=sm_75;
+        -gencode arch=compute_87,code=sm_87;
   )

   SET(CUDA_PROPAGATE_HOST_FLAGS OFF)

3.3 编译命令catkin_make问题

bash 复制代码
[ 56%] Building CXX object uav_simulator/Utils/multi_map_server/CMakeFiles/multi_map_visualization.dir/src/multi_map_visualization.cc.o
/home/daniel/ZJU-FAST-Lab/ego-planner-swarm/src/uav_simulator/Utils/multi_map_server/src/multi_map_visualization.cc:5:10: fatal error: multi_map_server/MultiOccupancyGrid.h: No such file or directory
    5 | #include <multi_map_server/MultiOccupancyGrid.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [uav_simulator/Utils/multi_map_server/CMakeFiles/multi_map_visualization.dir/build.make:63: uav_simulator/Utils/multi_map_server/CMakeFiles/multi_map_visualization.dir/src/multi_map_visualization.cc.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:4588: uav_simulator/Utils/multi_map_server/CMakeFiles/multi_map_visualization.dir/all] Error 2
make: *** [Makefile:141: all] Error 2
Invoking "make -j1" failed

**解决方案:**更换编译命令

bash 复制代码
$ catkin_make

4. 总结

本次顺利实现了Jetson Orin Nano上的模拟导航飞行,同时看到有模拟的飞机遇到障碍没有飞出来,具体问题待进一步的研究了。

Jetson Orin Nano | ego-planner-swarm simulation

相关推荐
真的没有脑袋15 分钟前
模型训练相关的问题
人工智能·深度学习·算法·计算机视觉·面试
路由侠内网穿透23 分钟前
本地部署消息代理软件 RabbitMQ 并实现外部访问( Windows 版本 )
服务器·开发语言·windows·数据分析·rabbitmq·ruby
一刀到底21130 分钟前
craw4ai 抓取实时信息,与 mt4外行行情结合实时交易,基本面来觉得趋势方向,搞一个外汇交易策略
人工智能·python·mt4·craw4ai
gaosushexiangji34 分钟前
实验分享|基于sCMOS相机科学成像技术的耐高温航空涂层材料损伤检测实验
大数据·人工智能·科技
Jaaaaaaaaaaaaa42 分钟前
Domain Adaptation in Vision-Language Models (2023–2025): A Comprehensive Review
人工智能·语言模型·自然语言处理
付付付付大聪明1 小时前
使用BERT/BiLSTM + CRF 模型进行NER进展记录~
人工智能·深度学习·bert
时序数据说1 小时前
时序数据库IoTDB如何快速高效地存储时序数据
大数据·数据库·开源·时序数据库·iotdb
Jamence1 小时前
多模态大语言模型arxiv论文略读(103)
论文阅读·人工智能·语言模型·自然语言处理·论文笔记
Jamence1 小时前
多模态大语言模型arxiv论文略读(九十七)
论文阅读·人工智能·语言模型·自然语言处理·论文笔记
何双新1 小时前
linux命令 systemctl 和 supervisord 区别及用法解读
linux·运维·postgresql