Ingesting Maps in CARLA Built From Source

This section describes the process of ingesting maps into CARLA that has been built from source. If you are using a package (binary) version of CARLA to ingest maps then follow the guidelines here instead.

The ingestion process involves importing the relevant map files by compiling them into a package. This package can then be opened in the Unreal Engine editor and customized before generating the pedestrian navigation file and finally adding it to the package.

Before you begin

  • Ensure you are using a version of CARLA that has been built from source. If you are using a packaged (binary) version of CARLA then follow the tutorial here.
  • You should have at least two files, <mapName>.xodr and <mapName>.fbx that have been generated from a map editor such as RoadRunner.
  • These files should have the same value for <mapName> in order to be recognised as the same map.
  • You can ingest multiple maps into the same package. Each map should have a unique name.

Map ingestion

1. Place the map files to be imported in the Import folder found in the CARLA root directory.

2. Run the command below to ingest the files:

make import

Note that there are two optional parameter flags that can be set:

  • --package=<package_name> specifies the name of the package. By default, this is set to map_package. Two packages cannot have the same name, so using the default value will lead to errors on a subsequent ingestion. It is highly recommended to change the name of the package. Use this flag by running the command:
make import  ARGS="--package=<package_name>"
  • --no-carla-materials specifies that you do not want to use the default CARLA materials (road textures etc). You will use the RoadRunner materials instead. This flag is only required if you are not providing your own .json file. Any value in the .json file will override this flag. Use this flag by running the command:
make import  ARGS="--no-carla-materials"

A folder will be created in Unreal/CarlaUE4/Content with the name of your map package. It will contain config files, overdrive information, static asset information and navigation information.

Next steps

You will now be able to open your map in the Unreal Editor and run simulations. From here, you will be able to customize the map and generate the pedestrian navigation data. We recommend generating the pedestrian navigation after all customization has finished, so there is no chance of obstacles blocking the pedestrian paths.

CARLA provides several tools and guides to help with the customization of your maps:

Once you have finished with the customization, you can generate the pedestrian navigation information.

If you have any questions about the process, then you can ask in the forum.