Instructions to use HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView") model = AutoModelForMultimodalLM.from_pretrained("HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView", device_map="auto") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView
- SGLang
How to use HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Docker Model Runner
How to use HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView with Docker Model Runner:
docker model run hf.co/HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView
Qwen3-VL-2B — Bench2Drive Front-View Driving VQA (LoRA, merged)
LoRA adaptation of Qwen3-VL-2B-Instruct for front-view autonomous-driving visual question answering on the Bench2Drive (Chat-B2D) benchmark. The vision encoder is frozen; LoRA is applied to the language model + multimodal aligner, then merged back into a single standalone checkpoint.
Input format: front camera current frame + 3 history frames (oldest→newest), with a driving-agent system prompt. Trained on driving data only (no general-domain replay) — this recipe was found to outperform general-mixed and data-scaled variants on both driving and general benchmarks.
Results (held-out front-view QA, n=2,500, deterministic split, zero clip overlap)
| Model | Recipe | BLEU-4 | ROUGE-L | CIDEr | MMStar |
|---|---|---|---|---|---|
| Qwen3-VL-2B (stock) | — | 3.00 | 14.15 | 0.47 | 43.67 |
| This model (v7) | B2D-only, 56k, 2 epochs | 45.40 | 74.30 | 436.4 | 52.60 |
General-ability retention (same scorers): AI2D 71.6 · ChartQA 77.2 · RealWorldQA 62.9 · ScienceQA 79.4 · MMStar 52.6 (stock MMStar 43.7 — general reasoning is preserved and, on several benchmarks, improved).
Usage
from transformers import AutoModelForImageTextToText, AutoProcessor
m = AutoModelForImageTextToText.from_pretrained("HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView", torch_dtype="auto", device_map="auto")
p = AutoProcessor.from_pretrained("HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView")
Training
Base Qwen3-VL-2B-Instruct · ViT frozen · LoRA r64/α128 on LLM + aligner · bf16 · 3×A100 · ms-swift. Driving metrics via pycocoevalcap (BLEU-4/ROUGE-L/CIDEr). Non-commercial research use.
- Downloads last month
- 20
Model tree for HqH1111/Qwen3-VL-2B-Bench2Drive-FrontView
Base model
Qwen/Qwen3-VL-2B-Instruct