Ubuntu16.04 安装Carla仿真软件

写于2020.4.3,此时最新的版本是0.9.8,安装环境为Ubuntu16.04

建议直接参考官网教程,忽略本教程https://carla.readthedocs.io/en/latest/start_quickstart/

一、Carla安装版本简介

Carla 安装分为Quick Start installation 和build installation,也就是快速安装和 编译安装。其中quick installation 是简易版,可以使用API(python、c++),但不包括高级的自定义和开发者选项。但是quick installation的最大好处是安装非常简单,所需的内存也比较小,大概十几个G。相比而言,build installation  需要安装Unreal engine 4(Ubuntu下大概70G) +Carla本身(20G)。所以没事就安装quick installation 版本吧。

二、Quick installation安装

      Quick installation安装的命令行摘要。

有两种方法安装:

a). 通过 deb package installation

b). 通过github installaion,具体而言是到https://github.com/carla-simulator/carla/blob/master/Docs/download.md是下载你所  需的版本。

简单的就按照下面的Option A) 即deb package installation 的方法

# Install required modules Pygame and Numpy. 
 pip install --user pygame numpy

# Option A) deb package installation of CARLA 0.9.8 (only Linux)
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 304F9BC29914A77D &&
sudo add-apt-repository "deb [arch=amd64 trusted=yes] http://dist.carla.org/carla-0.9.8/ all main"
sudo apt-get update
sudo apt-get install carla
cd /opt/carla/bin
./CarlaUE4.sh

# Option B) GitHub repository installation
#   Go to: https://github.com/carla-simulator/carla/blob/master/Docs/download.md
#   Download the desired package and additional assets. 
#   Extract the package. 
#   Extract the additional assets in `/Import`
#   Run CARLA (Linux)
./CarlaUE.sh
#   Run CARLA (Windows)
> CarlaUE4.exe

# Run a script to test CARLA
cd PythonAPI/examples
python3 spawn_npc.py

三、详细的安装介绍

系统要求:官方建议最少4G的GPU 、8G内存。

1.依赖项: Python modules: Pygame and Numpy 

 

 pip install --user pygame numpy

2.添加CARLA 0.9.8 repository到Linux系统

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 304F9BC29914A77D &&
sudo add-apt-repository "deb [arch=amd64 trusted=yes] http://dist.carla.org/carla-0.9.8/ all main"

3.安装CARLA并检查/opt/文件夹中的安装、

sudo apt-get update
sudo apt-get install carla
cd /opt/carla

4.在CARLA 文件夹下,开一个terminal,运行 ./CarlaUE4.sh

补充: ./CarlaUE4.sh在/opt/carla/bin 中

四、参考链接:

https://carla.readthedocs.io/en/latest/start_quickstart/

评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值