Skip to content

Latest commit

 

History

37 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

General Information

This repository contains Euro NCAP tests in CARLA simulator.

  • test_1 folder contains CCRs(Car-to-Car Rear stationary) test scenario in which an ego car accelerates and then brakes in front of a stationary car from 100 [m].

The folder contains a few utilities:

  1. Controller - contains simple controller for the throttle/brake based on the current relative distance.
  2. Dynamics - retrieve information about the state of the ego car.
  3. Scene - functions to manage the simulation.
  4. Visualizer - functions to plot ground-truth bounding box around the stationary car.
  5. Analysis - parse the data.csv file and plot a few insights from the simulation.

  • test_2 folder holds the modified manual_control.py version, integrated with lane detector, visualize the vehicle's current lanes boundaries. (Currently contains a bug in the waypoint selection 28/02/2024)

Prerequisite

  1. CARLA docker image - version: 0.9.15

             docker pull carlasim/carla:0.9.15
    
  2. CARLA Python package, install with:

             pip install carla==0.9.15
    
  3. docker compose.

Install

  1. Clone this repository:

             git clone git@github.com:iftahnaf/ccr_ncap.git            
    

Note: make sure that you can run docker without sudo

Run

Running with docker-compose

Using docker-compose, you will launch server(CARLA simulator) and client(Python API client) services for the simulation. Running with:

    docker compose up

Changing the script is done via altering the command in the docker-compose.yml:

      command: >
        /bin/bash -c "sleep 10 && python3 test_1/main.py"

Running from terminal:

Open two terminals.

In the first terminal:

            docker run --privileged --gpus all --net=host -e DISPLAY=$DISPLAY carlasim/carla:0.9.15 /bin/bash ./CarlaUE4.sh -RenderOffScreen

In the second terminal:

            cd ccr_ncap/
            python3 ./test_1/main.py

About

NCAP CCR Tests Implemented in CARLA

Topics

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages