Views
No views yet
Dream-VL, a VLM trained from:
config.json.1# Install minimal dependencies (`torch`, `transformers`, `timm`, `tokenizers`, `flash_attn`, ...)
2from transformers import AutoModel, AutoProcessor
3from PIL import Image
4import torch
5
6# Load Processor & VLA
7processor = AutoProcessor.from_pretrained("Dream-org/Dream-VLA-7B", trust_remote_code=True)
8vla = AutoModel.from_pretrained(
9 "Dream-org/Dream-VLA-7B",
10 attn_implementation="flash_attention_2", # [Optional] Requires `flash_attn`
11 torch_dtype=torch.bfloat16,
12 low_cpu_mem_usage=True,
13 trust_remote_code=True
14).to("cuda:0")
15
16# Grab image input & format prompt
17image: Image.Image = get_from_camera(...) # Replace with actual camera loading
18task_description = "pick up the block"
19conversation = [
20 {"role": "user", "content": [{"type": "image"}, {"type": "text", "text": f"What action should the robot take to {task_description}?"}]},
21]
22text = processor.apply_chat_template(conversation, tokenize=False, add_generation_prompt=True)
23inputs = processor(text=[text], images=[image], padding=True, return_tensors="pt").to("cuda:0", dtype=torch.bfloat16)
24
25# Predict Action (7-DoF; un-normalize for BridgeV2)
26action = vla.predict_action(**inputs, unnorm_key="bridge_orig", do_sample=False)
27
28# Execute...
29robot.act(action)1@article{ye2025dreamvla,
2 title={Dream-VL & Dream-VLA: Open Vision-Language and Vision-Language-Action Models with Diffusion Language Model Backbone},
3 author={Ye, Jiacheng and Gong, Shansan and Gao, Jiahui and Fan, Junming and Wu, Shuang and Bi, Wei and Bai, Haoli and Shang, Lifeng and Kong, Lingpeng},
4 journal={arXiv preprint arXiv:2512.22615}
5 year={2025}
6}