library_name: transformers
tags:
- 机器人技术
- 视觉语言动作模型
- 图像文本到文本
- 多模态
- 预训练
license: mit
language:
- 英文
pipeline_tag: image-text-to-text
OpenVLA v0.1 7B
注:OpenVLA v0.1是我们早期为开发目的训练的模型;如需获取最佳模型,请参见openvla/openvla-7b。
OpenVLA v0.1 7B(openvla-v01-7b
)是一个基于Open X-Embodiment数据集中80万次机器人操作片段训练的开源视觉-语言-动作模型(训练数据混合比例与Octo相同)。该模型以语言指令和摄像头图像作为输入,生成机器人动作。它支持开箱即用地控制多种机器人,并可通过(参数高效的)微调快速适配新的机器人领域。
所有OpenVLA检查点及我们的训练代码库均以MIT许可证发布。
完整细节请参阅我们的论文和项目主页。
模型概要
用途
OpenVLA模型接收语言指令和机器人工作空间的摄像头图像作为输入,预测(归一化的)机器人动作,包括7自由度末端执行器增量(x, y, z, 横滚, 俯仰, 偏航, 夹持器)。要在实际机器人平台上执行,动作需要根据每个机器人和数据集计算的统计量进行反归一化。更多信息请参见我们的代码库。
OpenVLA模型可零样本用于控制预训练数据混合中特定组合的机器人和领域(例如使用Widow-X机器人的BridgeV2环境)。它们也能通过少量演示数据高效微调以适应新任务和机器人设置;参见此处。
超出范围: OpenVLA模型不会零样本泛化到未见过的机器人构型或预训练数据中未包含的设置;对于这些情况,我们建议在目标设置上收集演示数据集并对OpenVLA模型进行微调。
快速开始
OpenVLA 7B可开箱即用地控制预训练数据中已包含的多种机器人。例如,以下是在[BridgeV2环境]中使用Widow-X机器人零样本执行指令的代码示例:
from transformers import AutoModelForVision2Seq, AutoProcessor
from PIL import Image
import torch
processor = AutoProcessor.from_pretrained("openvla/openvla-7b", trust_remote_code=True)
vla = AutoModelForVision2Seq.from_pretrained(
"openvla/openvla-v01-7b",
attn_implementation="flash_attention_2",
torch_dtype=torch.bfloat16,
low_cpu_mem_usage=True,
trust_remote_code=True
).to("cuda:0")
image: Image.Image = get_from_camera(...)
system_prompt = (
"这是一段好奇用户与人工智能助手之间的对话。"
"助手会为用户的问题提供有用、详细且礼貌的回答。"
)
prompt = f"{system_prompt} 用户:机器人应采取什么动作来{<指令>}?助手:"
inputs = processor(prompt, image).to("cuda:0", dtype=torch.bfloat16)
action = vla.predict_action(**inputs, unnorm_key="bridge_orig", do_sample=False)
robot.act(action, ...)
更多示例(包括在自有机器人演示数据集上微调OpenVLA模型的脚本),请参见我们的训练代码库。
引用
BibTeX格式:
@article{kim24openvla,
title={OpenVLA: 开源视觉-语言-动作模型},
author={{Moo Jin} Kim and Karl Pertsch and Siddharth Karamcheti and Ted Xiao and Ashwin Balakrishna and Suraj Nair and Rafael Rafailov and Ethan Foster and Grace Lam and Pannag Sanketi and Quan Vuong and Thomas Kollar and Benjamin Burchfiel and Russ Tedrake and Dorsa Sadigh and Sergey Levine and Percy Liang and Chelsea Finn},
journal = {arXiv preprint arXiv:2406.09246},
year={2024}
}