路径:flightmare/src/flightmare/flightrl/examples
尝试运行:python run_drone_control.py

运行指令:

python3 run_drone_control.py --train 0 --render 1

前期准备:
anaconda建立python=3.6的库:

conda create -n flightmare python=3.6

开虚拟环境

source activate
conda activate flightmare

目前尝试出来的需要另外安装的依赖:

pip install ruamel.yaml
pip install stable_baselines
pip install tensorflow==1.13.1
  • 对于:ModuleNotFoundError: No module named 'rpg_baselines' :
    在路径/flightrl/setup.py中,将包的内容rpg_baselines后面添加成:'rpg_baselines', 'rpg_baselines.ppo', 'rpg_baselines.common', 'rpg_baselines.envs'
    再执行:
cd flightrl
pip install .

自己安装时此时有了报错:

ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
nes-py 8.1.6 requires gym>=0.17.2, but you have gym 0.11.0 which is incompatible.
nes-py 8.1.6 requires pyglet<=1.5.0,>=1.4.0, but you have pyglet 1.5.15 which is incompatible.
Successfully installed PyOpenGL-3.1.5 gym-0.11.0 rpg-baselines-0.0.1 stable-baselines-2.10.1

为了保证后面少出问题,根据提示进行了包的安装:

pip install gym==0.17.2
pip install nes-py==8.1.6
  • ModuleNotFoundError: No module named 'flightgym':
    包在路径:~/flightmare/src/flightmare/flightlib/tests/flightgym/
cd flightmare/flightlib
# it first compile the flightlib and then install it as a python package.
pip install .

------------- 同步更新 TBC -------------------

Logo

GitCode 天启AI是一款由 GitCode 团队打造的智能助手,基于先进的LLM(大语言模型)与多智能体 Agent 技术构建,致力于为用户提供高效、智能、多模态的创作与开发支持。它不仅支持自然语言对话,还具备处理文件、生成 PPT、撰写分析报告、开发 Web 应用等多项能力,真正做到“一句话,让 Al帮你完成复杂任务”。

更多推荐