FREA
1.0.0
2024-09-05
令人興奮的消息! FREA 被 CoRL 2024 接受用於口頭報告?2024-08-10
探索我們的專案頁面,現在住在這裡?2024-08-10
代碼現已發布!2024-06-05
我們的論文在Arxiv上可用?該存儲庫包含論文的實作。
FREA:以可行性為引導生成具有合理對抗性的安全關鍵場景
陳克宇1 , 雷宇恆2 , 程浩1 , 吳浩然1 , 孫文超1 , 鄭四發1
1清華大學車輛與交通學院2香港大學
如果您覺得我們的工作有用,請給我們一顆星?
? FREA 將可行性作為指導,以產生對抗性但 AV 可行、安全關鍵的場景。
推薦系統:Ubuntu 20.04或22.04
第1步:安裝Carla(建議0.9.13)
第二步:設定conda環境
conda create -n frea python=3.8
conda activate frea
步驟 3:將此 git 儲存庫複製到適當的資料夾中
git clone [email protected]:CurryChen77/FREA.git
步驟 4:進入 repo 根資料夾並安裝軟體包:
cd FREA
pip install -r requirements.txt
pip install -e .
# Launch CARLA
./CarlaUE4.sh -prefernvidia -RenderOffScreen -carla-port=2000
# Launch in another terminal
python scripts/run.py --agent_cfg expert.yaml --scenario_cfg standard_train.yaml --mode collect_feasibility_data
# Merge data
python frea/feasibility/unify_offline_data.py
要使用我們論文中的離線資料集,請從此處下載並將它們放入feasibility
資料夾中。
# Train optimal feasible value function of AV
python train_feasibility.py
# Launch CARLA
./CarlaUE4.sh -prefernvidia -RenderOffScreen -carla-port=2000
# Train FREA
python scripts/run.py --agent_cfg expert.yaml --scenario_cfg fppo_adv_train.yaml --mode train_scenario
# Launch CARLA
./CarlaUE4.sh -prefernvidia -RenderOffScreen -carla-port=2000
# Train FPPO-RS
python scripts/run.py --agent_cfg expert.yaml --scenario_cfg fppo_rs_train.yaml --mode train_scenario
# Launch CARLA
./CarlaUE4.sh -prefernvidia -RenderOffScreen -carla-port=2000
# Train PPO
python scripts/run.py --agent_cfg expert.yaml --scenario_cfg ppo_train.yaml --mode train_scenario
# Launch CARLA
./CarlaUE4.sh -prefernvidia -RenderOffScreen -carla-port=2000
# Train FREA
python scripts/run.py --agent_cfg ppo.yaml --scenario_cfg fppo_adv_train.yaml --mode train_agent
# Launch CARLA
./CarlaUE4.sh -prefernvidia -RenderOffScreen -carla-port=2000
# Train FREA
python scripts/run.py --agent_cfg ppo.yaml --scenario_cfg standard_train.yaml --mode train_agent
# Launch CARLA
./CarlaUE4.sh -prefernvidia -windowed -carla-port=2000
# Evaluation FREA
python scripts/run.py --agent_cfg expert.yaml --scenario_cfg FPPO_adv_eval.yaml --mode eval --eval_mode analysis
# Launch CARLA
./CarlaUE4.sh -prefernvidia -windowed -carla-port=2000
# Evaluation FREA
python scripts/run.py --agent_cfg expert.yaml --scenario_cfg FPPO_adv_eval.yaml --mode eval --eval_mode render
確保評估已完成並將結果保存在資料夾中。
# Process the recorded data
python eval_analysis/process_data/process_all_data.py
# Plot the evaluation result
python eval_analysis/plot_data/plot_evaluation_result.py
# Launch CARLA
./CarlaUE4.sh -prefernvidia -windowed -carla-port=2000
# Set world spectator
python scripts/run.py --agent_cfg expert.yaml --scenario_cfg standard_eval.yaml --mode eval -sp
# Launch CARLA
./CarlaUE4.sh -prefernvidia -windowed -carla-port=2000
# Visualize AV route
python scripts/run.py --agent_cfg expert.yaml --scenario_cfg standard_eval.yaml --mode eval -viz_route
# Launch CARLA
./CarlaUE4.sh -prefernvidia -windowed -carla-port=2000
# Visualize BEV map
python scripts/run.py --agent_cfg expert.yaml --scenario_cfg FPPO_adv_eval.yaml --mode eval --eval_mode render
如果您發現我們的論文有用,請透過以下方式引用我們:
@inproceedings{
chen2024frea,
title={{FREA}: Feasibility-Guided Generation of Safety-Critical Scenarios with Reasonable Adversariality},
author={Keyu Chen and Yuheng Lei and Hao Cheng and Haoran Wu and Wenchao Sun and Sifa Zheng},
booktitle={8th Annual Conference on Robot Learning},
year={2024},
url={https://openreview.net/forum?id=3bcujpPikC}
}
此實作基於多個儲存庫中的程式碼。我們衷心感謝作者的出色工作。