🚀 OpenVLA v0.1 7B
OpenVLA v0.1 7B是一个开源的视觉 - 语言 - 动作模型,它基于Open X - Embodiment数据集进行训练。该模型以语言指令和相机图像作为输入,能够生成机器人动作,可直接控制多种机器人,还能通过(参数高效)微调快速适配新的机器人领域。
注意事项
OpenVLA v0.1是我们为开发目的而训练的早期模型;若需获取我们的最佳模型,请查看[openvla/openvla - 7b](https://huggingface.co/openvla/openvla - 7b)。
所有OpenVLA的检查点以及我们的训练代码库均在MIT许可证下发布。如需了解完整详情,请阅读我们的论文并查看我们的项目页面。
🚀 快速开始
OpenVLA 7B可以直接用于控制预训练混合集中所涵盖领域的多种机器人。以下是一个在[BridgeV2环境]中使用Widow - X机器人进行零样本指令跟踪的示例,用于加载openvla - v01 - 7b
:
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 = (
"A chat between a curious user and an artificial intelligence assistant. "
"The assistant gives helpful, detailed, and polite answers to the user's questions."
)
prompt = f"{system_prompt} USER: What action should the robot take to {<INSTRUCTION>}? ASSISTANT:"
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模型的脚本,请查看我们的训练仓库。
✨ 主要特性
- 多机器人控制:可直接控制多种机器人。
- 快速适配:能通过(参数高效)微调快速适配新的机器人领域。
- 零样本使用:可对Open - X预训练混合集中看到的特定组合的实体和领域进行零样本机器人控制。
📚 详细文档
模型概述
使用方法
OpenVLA模型以语言指令和机器人工作空间的相机图像作为输入,预测由7自由度末端执行器增量组成的(归一化)机器人动作,形式为(x, y, z, 滚动, 俯仰, 偏航, 抓手)。要在实际的机器人平台上执行,动作需要根据每个机器人、每个数据集计算的统计数据进行反归一化。更多信息请查看我们的仓库。
OpenVLA模型可以进行零样本使用,以控制Open - X预训练混合集中看到的特定实体和领域组合的机器人(例如,[带有Widow - X机器人的BridgeV2环境](https://rail - berkeley.github.io/bridgedata/))。在给定最少的演示数据的情况下,它们还可以针对新任务和机器人设置进行高效的微调;详情请见此处。
适用范围说明
OpenVLA模型不能对新的(未见过的)机器人实体或预训练混合集中未涵盖的设置进行零样本泛化;在这些情况下,我们建议在所需的设置上收集演示数据集,并对OpenVLA模型进行微调。
📄 许可证
本项目采用MIT许可证。
📖 引用
@article{kim24openvla,
title={OpenVLA: An Open-Source Vision-Language-Action Model},
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}
}