Skip to main content
Version: Next

Open-Loop Inference

Bench2Drive-VL supports open-loop VQA evaluation via VQA dataset.

Write a config file

Write a config file under ./B2DVL_Adapter for inferencing framework.

your_infer_config.json
{
"TASK_CONFIGS": {
"INFER_SUBSET": false, // inference a subset of given dataset
"USE_CHECKPOINT": true, // record the process of inference
"SUBSET_FILE": "./infer_configs/subset.txt", // subset file, leave blank if not used
"CHECKPOINT_FILE": "./infer_configs/finished_scenarios.txt", // checkpoint file, leave blank if not used
"ENTRY_EXIT_FILE": "./infer_configs/entry_exits.json", // the file which specifies entry and exit point of certain scenario,
// you can create a file with "{}" as content if do not specify
"FRAME_PER_SEC": 10 // sensor frame
},
"INFERENCE_BASICS": {
"INPUT_WINDOW": 1,
"CONVERSATION_WINDOW": 2,
"USE_ALL_CAMERAS": true,
"NO_HISTORY_MODE": false,
"APPEND_QUESTION": true,
"APPENDIX_FILE": "./infer_configs/append_questions.json" // not used now, to be removed
},
"CHAIN": {
"NODE": [43, 50],
"EDGE": {
"43": [50],
"50": []
},
"INHERIT": {
"19": [43, 7],
"15": [7]
},
"USE_GT": []
}
}

Start to inference

Run the start up script you just wrote.

cd ./B2DVL_Adapter
python inference.py --model Qwen2.5VL --model_path /path/to/Qwen2.5VL-3B-Instruct --config_dir /path/to/your_infer_config.json --image_dir /path/to/Bench2Drive/dataset --vqa_dir /path/to/vqa/dataset --num_workers 4 --out_dir ./infer_outputs