Giter VIP home page Giter VIP logo

dtpp's Introduction

DTPP

This repository contains the source code for the ICRA'24 paper:

DTPP: Differentiable Joint Conditional Prediction and Cost Evaluation for Tree Policy Planning in Autonomous Driving

Zhiyu Huang1, Peter Karkus2, Boris Ivanovic2, Yuxiao Chen2, Marco Pavone2,3, and Chen Lv1

1 Nanyang Technological University, 2 NVIDIA Research, 3 Stanford University

Getting Started

1. Configure devkit and environment

To set up your development environment, please follow these steps:

  • Download the nuPlan dataset and configure the dataset as described here.
  • Install the nuPlan devkit as instructed here (tested version: v1.2.2).
  • Clone the DTPP repository and enter the directory:
git clone https://github.com/MCZhi/DTPP.git && cd DTPP
  • Activate the environment created when installing the nuPlan-devkit:
conda activate nuplan
  • Install PyTorch:
conda install pytorch==2.0.1 pytorch-cuda=11.7 -c pytorch -c nvidia
  • Add the following environment variable to your ~/.bashrc file (customizable):
export NUPLAN_EXP_ROOT="$HOME/nuplan/exp"

2. Data processing

Before training the DTPP model, you need to preprocess the raw data from nuPlan using:

python data_process.py \
--data_path nuplan/dataset/nuplan-v1.1/splits/mini \
--map_path nuplan/dataset/maps \
--save_path nuplan/processed_data

Three arguments are mandatory: --data_path to specify the path to the stored nuPlan dataset, --map_path to specify the path to the nuPlan map data, and --save_path to specify the path to save the processed data. Optionally, limit the number of scenarios with --total_scenarios argument.

3. Training

To train the DTPP model, run:

python train.py \
--train_set nuplan/processed_data/train \
--valid_set nuplan/processed_data/valid

Two arguments are mandatory: --train_set to specify the path to the processed training data and --valid_set to specify the path to the processed validation data.

Optional training parameters: --train_epochs, --batch_size, and --learning_rate.

4. Testing

To test the DTPP planning framework in nuPlan simulation scenarios, use:

python test.py \
--test_type closed_loop_nonreactive_agents \
--data_path nuplan/dataset/nuplan-v1.1/splits/mini \
--map_path nuplan/dataset/maps \
--model_path training_log/your/model

Choose one of the three options ('open_loop_boxes', 'closed_loop_nonreactive_agents', 'closed_loop_reactive_agents') for --test_type, and specify the path to your trained model --model_path. Ensure to provide --data_path and --map_path arguments as done in the data process step.

Adjust the --scenarios_per_type argument to control the number of scenarios tested per type.

Ensure that the model parameters in planner.py under _initialize_model match those used in training.

Citation

If you find this project useful in your research, please consider citing:

@article{huang2023dtpp,
  title={DTPP: Differentiable joint conditional prediction and cost evaluation for tree policy planning in autonomous driving},
  author={Huang, Zhiyu and Karkus, Peter and Ivanovic, Boris and Chen, Yuxiao and Pavone, Marco and Lv, Chen},
  journal={arXiv preprint arXiv:2310.05885},
  year={2023}
}

Contact

If you have any questions or suggestions, please feel free to open an issue or contact us ([email protected]).

(back to top)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.