技术解读

以下内容由 GitRead 中文社区 编辑团队基于项目 README 与官方资料整理, 结合中文开发者的常见使用场景补充技术选型建议。具体以项目官方文档为准。

深度解析 MIV-XJTU 的 FSDrive 项目

项目背景与痛点

在自动驾驶领域,车辆如何实时感知、理解并处理复杂的交通环境是当前研究的难点。MIV-XJTU 的 FSDrive 项目正是针对这一痛点,提出了 “FutureSightDrive: Thinking Visually with Spatio-Temporal CoT for Autonomous Driving” 概念,该方法通过引入时空协作推理机制,极大提升了自动驾驶系统在复杂环境下的感知和决策能力。

该项目针对传统自动驾驶系统在处理时序(Temporal)和空间(Spatial)信息时存在的不足进行改进。传统的算法往往将时空信息割裂开来处理,无法充分挖掘时间上的前后依赖关系和空间上的几何布局信息,FSDrive 则解决了这一联合推理问题,使得系统能够在更复杂的环境中保持稳定表现。

核心技术揭秘

FSDrive 的核心在于其时空协作推理框架。通过组合时空卷积网络(STCNN)与图卷积网络(GCN),系统能够有效地处理时空信息,使得自动驾驶车辆在做出决策时更加智能和准确。具体实现步骤如下:

graph TD A[感知层] --> B{"环境理解"} B -->|"提取特征"| C[时空卷积层] B -->|"构建图结构"| D[图卷积层] C --> E[特征融合] D --> E E --> F[决策层] F --> G[执行指令]

首先,系统感知层获取原始数据。数据经过环境理解模块后进行特征提取和图结构构建。空间特征通过 STCNN 捕捉,而图结构由 GCN 补充。最后,经过特征融合模块,系统对最后的决策层进行输出,并发出执行指令。

关键算法设计以及实现原理,都充分挖掘了时空联合推理的优势,从而在复杂环境下提升自动驾驶的能力。

功能亮点与差异

FSDrive 的核心亮点在于其时空协作推理框架所构建出的完善的时空联合推理能力。相比于传统的解决方案,FSDrive 更能捕捉时间和空间上的联系,从而更好地处理动态场景的数据,在做出意义预测时更加鲁棒。这种特性使得 FSDrive 相较于其他系统在处理复杂动态场景时更显优势。

此外,FSDrive 的开放性和灵活性使它能够适应多种自动驾驶应用场景,包括但不限于高速公路驾驶、城市道路管理等。

应用场景与落地建议

在实际生产环境中使用 FSDrive 时,开发者们需要特别注意系统的鲁棒性和实时性。由于 FSDrive 的时空协作推理框架较为复杂,因此需要注意对系统进行优化,避免在复杂计算中出现瓶颈。此外,对于实时决策需求较高的场景,如紧急避险,需要针对系统做更详细的数据预处理,并适当优化计算资源分配。

FSDrive 特别适合处理复杂的环境感知和决策场景,尤其是具备多个时序和空间信息来源的环境。

综合评价

FSDrive 通过引入时空协作推理框架显著提升了自动驾驶系统的感知和决策能力,这种提升源自系统创新且深刻的算法设计。不过,我们也需要注意其计算复杂度较高,对于实时性能的要求也较为严格,这需要在实际部署过程中进行进一步优化。总体而言,FSDrive 展示出的技术实力与潜力使其成为解决复杂交通环境感知与决策问题的强有力候选者。

关于

GitHub 原始描述(英文)

[NeurIPS 2025 spotlight] Official implementation for "FutureSightDrive: Thinking Visually with Spatio-Temporal CoT for Autonomous Driving"

描述取自 GitHub 官方 API,保持仓库作者书写的原文。

简要分析

热度分
942
价值分
508
活跃状态
活跃

语言占比

Dockerfile
Makefile
Python
Shell

贡献者

README

FutureSightDrive: Thinking Visually with Spatio-Temporal CoT for Autonomous Driving

🎉🎉NeurIPS 2025 spotlight🎉🎉

arXiv Project Page

Shuang Zeng1,2, Xinyuan Chang1, Mengwei Xie1, Xinran Liu1, Yifan Bai2,3, Zheng Pan1, Mu Xu1, Xing Wei2,

1Amap, Alibaba Group, 2Xi’an Jiaotong University, 3DAMO Academy, Alibaba Group

FutureSightDrive (FSDrive): The proposed spatio-temporal CoT enables end-to-end autonomous driving VLA to think visually about trajectory planning and unify visual generation and understanding with minimal data, advancing autonomous driving towards visual reasoning for the first time.

https://github.com/user-attachments/assets/a99a14a3-a892-4cbe-ac1f-66b777d9081b

Table of Contents

🛠️ Installation

Create the required environment through the following steps:

git clone https://github.com/MIV-XJTU/FSDrive.git && cd FSDrive

conda create -n FSDrive python=3.10 -y && conda activate FSDrive

# CUDA 12.4
pip install torch==2.5.1 torchvision==0.20.1 torchaudio==2.5.1 --index-url https://download.pytorch.org/whl/cu124

cd LLaMA-Factory && pip install -e ".[metrics,deepspeed,liger-kernel,bitsandbytes]" --no-build-isolation

cd .. && pip install -r requirements.txt

📦 Data Preparation

1、Download nuScenes

Download the complete dataset from nuScenes and extract it to ./LLaMA-Factory/data/nuscenes

Or establish a soft connection:

ln -s /path/to/your/nuscenes LLaMA-Factory/data

We used pre-cached data from the nuScenes dataset. The data can be downloaded at Google Drive. The file cached_nuscenes_info.pkl is located in the directory ./create_data. The metrics folder is placed in the directory ./tools/data.

2、Extract visual tokens

Separately extract the visual tokens of the front view from both the pre-trained and fine-tuned data, to facilitate supervised MLLM:

python MoVQGAN/pretrain_data.py
python MoVQGAN/sft_data.py

3、Construct data

Construct pre-training and fine-tuning data that conform to the LLaMA-Factory format respectively:

python create_data/pretrain_data.py
python create_data/sft_data.py --split train # Change to "val" for constructing the validation set

Follow the LLaMA-Factory tutorial and add the dataset information in the file ./LLaMA-Factory/data/dataset_info.json.

🚀 Training

Enter the working directory of LLaMA-Factory:

cd LLaMA-Factory

1、Pre-train

First, pre-train the VLM to activate its visual generation capabilities:

llamafactory-cli train ../configs/pretrain.yaml

2、SFT

Then, based on the pre-trained parameters, fine-tune the VLM to think visually about trajectory planning:

llamafactory-cli train ../configs/sft.yaml

🎯 Infer

Run the following command in the LLaMA-Factory directory to infer test dataset:

python scripts/vllm_infer.py \ 
--model_name_or_path saves/qwen2_vl-2b/sft \
--dataset val_cot_motion \
--template qwen2_vl \
--cutoff_len 32768 \
--max_new_tokens 2048 \
--max_samples 100000 \
--image_resolution 524288 \
--save_name results.jsonl \
--temperature 0.1 \
--top_p 0.1 \
--top_k 10

📈 Evaluation

First, under the FSDrive directory, match the predicted results with the tokens to facilitate the evaluation:

cd ..

python tools/match.py \
--pred_trajs_path ./LLaMA-Factory/results.jsonl \
--token_traj_path ./LLaMA-Factory/data/val_cot_motion.json

Then evaluate the L2 and collision rate indicators for the end-to-end trajectory planning:

python tools/evaluation/evaluation.py \
# Change to "stp3" and use the ST-P3 calculation method
--metric uniad \  
--result_file ./LLaMA-Factory/eval_traj.json

👀 Visualization

Use the following command under the FSDrive directory to visualize the trajectory:

python tools/visualization/visualize_planning.py \
--pred-trajs-path ./LLaMA-Factory/results.jsonl \
--tokens-path ./LLaMA-Factory/eval_traj.json \  
--output-path ./vis_traj

Use the following command under the FSDrive directory to restore the visual tokens to the pixel space and visualize the CoT:

python ./MoVQGAN/vis.py \
--input_json ./LLaMA-Factory/eval_traj.json \
--output_dir ./vis_cot

📜 Citing

If you find FSDrive is useful in your research or applications, please consider giving us a star 🌟 and citing it by the following BibTeX entry:

@article{zeng2025futuresightdrive,
  title={FutureSightDrive: Thinking Visually with Spatio-Temporal CoT for Autonomous Driving},
  author={Zeng, Shuang and Chang, Xinyuan and Xie, Mengwei and Liu, Xinran and Bai, Yifan and Pan, Zheng and Xu, Mu and Wei, Xing},
  journal={arXiv preprint arXiv:2505.17685},
  year={2025}
}

🙏 Acknowledgement

Our work is primarily based on the following codebases:LLaMA-Factory, MoVQGAN, GPT-Driver, Agent-Driver. We are sincerely grateful for their work.

评论

暂无评论