This is a guildeline with step-by-step instructions for those who want to quickly set up the environment for Carla.
Carla Documentation 0.9.12
Carla Documentation 0.9.11
Conda Docs
System: Wiondows/Linux
GPU: GPU RAM 6GB ↑
Disk space: 20 GB ↑
Python: 2.7 + 3.7 (a stable version for now Aug2021)
Python package: pygame, numpy (you can use pip to install)
Virtual environment: Anaconda
- The following guideline is based on the "Quick start package installation" in the official document. After basic file installation, we would build a virtual environment for a better version management.
-
Go to Carla Relaese page and download compressed package with a version you want.
-
Extract the compressed files (CARLA_0.9.XX.tar.gz) to a preferable folder. For GUI linux, you can directly extract files with "Right Click" and then "Extract to..." without tar commands in terminal.
Optional: Import Assets a. Diretly put package files (AdditionalMaps_0.9.XX.tar.gz or CARLA_0.9.10.1_RSS.tar.gz) into "Import" folder in the root folder of carla.* (Do not extract them!!) b. Run the script in the carla root folder
./ImportAssets.sh
-
Now you should be able to run a calar host simulator directly with the following command in carla root file.
./CarlaUE4.sh
-
After above steps, we are going to use conda to set up a virtual environment for Python version management in order to not influence current Python version of your OS. a. Conda setup: The following content is based-on Installing on Linux in conda offical website.
- Download a installer with the lastest version for Linux on Anaconda Installers, e.g. "64-Bit (x86) Installer (544 MB)" (Sep2021). (You can also choose Miniconda.)
- Navigate to your download file and run the following command using your exact filename to start install.
bash Anaconda3-2021.05-Linux-x86_64.sh
- After running "conda init", we can go to carla root folder to build a virtual environment with the command:
conda create --name py37 python=3.7
- Activate the specified conda environment
conda activate py37
- You can use the conda install command to install the required packages:
conda install numpy or conda install pygame
- Exit virtual conda environment
conda deactivate