Qwen2.5-VL!Qwen2.5-VL!!Qwen2.5-VL!!!

简介: Qwen2.5-VL!Qwen2.5-VL!!Qwen2.5-VL!!!

今天,我们开源了全新的视觉理解模型Qwen2.5-VL——Qwen 模型家族的旗舰视觉语言模型,推出了3B、7B和72B三个尺寸版本,对比此前发布的 Qwen2-VL 实现了巨大的飞跃。


Qwen2.5-VL 的主要特点如下所示:


◆视觉理解:Qwen2.5-VL 不仅擅长识别常见物体,如花、鸟、鱼和昆虫,还能够分析图像中的文本、图表、图标、图形和布局。


◆Agent:Qwen2.5-VL 直接作为一个视觉 Agent,可以推理并动态地使用工具,初步具备了使用电脑和使用手机的能力。


◆理解长视频和捕捉事件:Qwen2.5-VL 能够理解超过 1 小时的视频,并且这次它具备了通过精准定位相关视频片段来捕捉事件的新能力。


◆视觉定位:Qwen2.5-VL 可以通过生成 bounding boxes 或者 points 来准确定位图像中的物体,并能够为坐标和属性提供稳定的 JSON 输出。


结构化输出:对于发票、表单、表格等数据,Qwen2.5-VL 支持其内容的结构化输出,惠及金融、商业等领域的应用。

模型性能


我们对视觉语言模型进行了全面的评估,比较了 SOTA 模型以及同尺寸规模模型中表现最好的模型。


在旗舰模型 Qwen2.5-VL-72B-Instruct 的测试中,它在一系列涵盖多个领域和任务的基准测试中表现出色,包括大学水平的问题、数学、文档理解、视觉问答、视频理解和视觉 Agent。值得注意的是,Qwen2.5-VL 在理解文档和图表方面具有显著优势,并且能够作为视觉 Agent 进行操作,而无需特定任务的微调。



在较小的模型方面,Qwen2.5-VL-7B-Instruct 在多个任务中超越了 GPT-4o-mini,而 Qwen2.5-VL-3B 作为端侧 AI 的潜力股,甚至超越了我们之前版本 Qwen2-VL 的 7B 模型。



模型能力案例


01 万物识别


Qwen2.5-VL 显著增强了其通用图像识别能力,大幅扩大了可识别的图像类别量级。不仅包括植物、动物、著名山川的地标,还包括影视作品中的 IP,以及各种各样的商品。


Prompt:What are these attractions? Please give their names in Chinese and English.

Qwen2.5-VL:

These attractions are:

1.Top left: The Great Pyramids of Giza (埃及的吉萨大金字塔)

2.Top right: The Great Wall of China (中国的长城)

3.Bottom left: The Statue of Liberty (美国的自由女神像)

4.Bottom right: The Terracotta Army (中国的秦始皇兵马俑)


02 精准的视觉定位


Qwen2.5-VL 采用矩形框和点的多样化方式对通用物体定位,可以实现层级化定位和规范的 JSON 格式输出。增强的定位能力为复杂场景中的视觉 Agent 进行理解和推理任务提供了基础。


Prompt:Detect all motorcyclists in the image and return their locations in the form of coordinates. The format of output should be like {“bbox_2d”: [x1, y1, x2, y2], “label”: “motorcyclist”, “sub_label”: “wearing helmat” # or “not wearing helmat”}.


Qwen2.5-VL:

[
    {"bbox_2d": [341, 258, 397, 360], "label": "motorcyclist", "sub_label": "not wearing helmat "},
    {"bbox_2d": [212, 332, 274, 448], "label": "motorcyclist", "sub_label": "not wearing helmat "},
    {"bbox_2d": [66, 124, 112, 198], "label": "motorcyclist", "sub_label": "not wearing helmat "},
    {"bbox_2d": [5, 235, 63, 320], "label": "motorcyclist", "sub_label": "wearing helmat "}
]


03 全面的文字识别和理解


Qwen2.5-VL 将 OCR 识别能力提升至一个新的水平,增强了多场景、多语言和多方向的文本识别和文本定位能力。同时,在信息抽取能力上进行大幅度增强,以满足日益增长的资质审核、金融商务等数字化、智能化需求。


Prompt:Read all texts in the image, output in lines.


Qwen2.5-VL:

平安喜樂 八方來財 順風順水順財神 暴富 大吉 諸事皆順 福 時來運轉 發財 如意 有錢有勢有前程 好運來


04 Qwen特色的文档解析


在 Qwen2.5-VL 中,我们在设计了一种更全面的文档解析格式,称为 QwenVL HTML 格式,它既可以将文档中的文本精准地识别出来,也能够提取文档元素(如图片、表格等)的位置信息,从而准确地将文档中的版面布局进行精准还原。基于精心构建的海量数据,QwenVL HTML 可以对广泛的场景进行鲁棒的文档解析,比如杂志、论文、网页、甚至手机截屏等等。


Prompt:QwenVL HTML

Qwen2.5-VL:


<html>
<body>
<h1 data-bbox="879 283 1605 348">Qwen2.5 Technical Report</h1>
<p data-bbox="1124 406 1360 456"></p>
<address class="author"><p>Qwen Team</p></address>
<div class="image" data-bbox="778 491 850 541"><img data-bbox="778 491 850 541"/></div>
<p data-bbox="885 491 1460 541">https://huggingface.co/Qwen</p>
<div class="image" data-bbox="778 541 850 589"><img data-bbox="778 541 850 589"/></div>
<p data-bbox="885 541 1708 589">https://modelscope.cn/organization/qwen</p>
<div class="image" data-bbox="792 589 850 639"><img data-bbox="792 589 850 639"/></div>
<p data-bbox="885 589 1584 639">https://github.com/QwenLM/Qwen2.5</p>
<h2 data-bbox="1143 681 1344 733">Abstract</h2>
<p data-bbox="434 785 2050 1252">In this report, we introduce Qwen2.5, a comprehensive series of large language models (LLMs) designed to meet diverse needs. Compared to previous iterations, Qwen 2.5 has been significantly improved during both the pre-training and post-training stages. In terms of pre-training, we have scaled the high-quality pre-training datasets from the previous 7 trillion tokens to 18 trillion tokens. This provides a strong foundation for common sense, expert knowledge, and reasoning capabilities. In terms of post-training, we implement intricate supervised finetuning with over 1 million samples, as well as multistage reinforcement learning, including offline learning DPO and online learning GRPO. Post-training techniques significantly enhance human preference, and notably improve long text generation, structural data analysis, and instruction following.</p>
<p data-bbox="434 1262 2050 1587">To handle diverse and varied use cases effectively, we present Qwen2.5 LLM series in rich configurations. The open-weight offerings include base models and instruction-tuned models in sizes of $0.5 \mathrm{~B}, 1.5 \mathrm{~B}, 3 \mathrm{~B}, 7 \mathrm{~B}, 14 \mathrm{~B}, 32 \mathrm{~B}$, and $72 \mathrm{~B}$ parameters. Quantized versions of the instruction-tuned models are also provided. Over 100 models can be accessed from Hugging Face Hub, ModelScope, and Kaggle. In addition, for hosted solutions, the proprietary models currently include two mixture-of-experts (MoE) variants: Qwen2.5-Turbo and Qwen2.5-Plus, both available from Alibaba Cloud Model Studio.</p>
<p data-bbox="434 1587 2050 2052">Qwen2.5 has demonstrated top-tier performance on a wide range of benchmarks evaluating language understanding, reasoning, mathematics, coding, human preference alignment, etc. Specifically, the open-weight flagship Qwen2.5-72B-Instruct outperforms a number of open and proprietary models and demonstrates competitive performance to the state-of-the-art open-weight model, Llama-3-405B-Instruct, which is around 5 times larger. Qwen2.5-Turbo and Qwen2.5-Plus offer superior cost-effectiveness while performing competitively against GPT-4o-mini and GPT-4o respectively. Additionally, as the foundation, Qwen2.5 models have been instrumental in training specialized models such as Qwen2.5-Math (Yang et al., 2024b), Qwen2.5-Coder (Hui et al., 2024), QwQ (Qwen Team, 2024d), and multimodal models.</p>
<div class="image" data-bbox="408 2275 2086 2800"><img data-bbox="408 2275 2086 2800"/></div>
<p data-bbox="289 2864 2202 3058">Figure 1: In the iterative development of the Qwen series, data scaling has played a crucial role. Qwen 2.5, which leverages 18 trillion tokens for pre-training, has demonstrated the most advanced capabilities within the Qwen series, especially in terms of domain expertise, underscoring the importance of scale together with mixture in enhancing the model’s capabilities.</p></body>
</body>
</html>


05 增强的视频理解


Qwen2.5-VL 的视频理解能力经过全面升级,在时间处理上,我们引入了动态帧率(FPS)训练和绝对时间编码技术。这样一来,模型不仅能够支持小时级别的超长视频理解,还具备秒级的事件定位能力。它不仅能够准确地理解小时级别的长视频内容,还可以在视频中搜索具体事件,并对视频的不同时间段进行要点总结,从而快速、高效地帮助用户提取视频中蕴藏的关键信息。


Prompt:Watch the video and list the paper titles in a table.


Qwen2.5-VL:

Here is a table listing the paper titles from the video:


Paper Title
A New Sequential Prediction Framework with Spatial-temporal Embedding
NeW CRFs: Neural Window Fully-connected CRFs for Monocular Depth Estimation
Deep Unified Representation for Heterogeneous Recommendation
OFA: Unifying Architectures, Tasks, and Modalities Through a Simple Sequence-to-Sequence Learning Framework
KoMen: Domain Knowledge Guided Interaction Recommendation for Emerging Scenarios Yiqing Xie
Vision-Language Pre-Training for Boosting Scene Text Detectors


06 能够操作电脑和手机的视觉Agent


通过利用内在的感知、解析和推理能力,Qwen2.5-VL 展现出了不错的设备操作能力。这包括在手机、网络平台和电脑上执行任务,为创建真正的视觉代理提供了有价值的参考点。


Prompt:

Please help me book a one-way ticket in the bookings app. The starting point is Chongqing Jiangbei Airport and the ending point is Beijing Capital Airport on January 28th

Qwen2.5-VL:

模型更新

与 Qwen2-VL 相比,Qwen2.5-VL 增强了模型对时间和空间尺度的感知能力,并进一步简化了网络结构以提高模型效率。


时间和图像尺寸的感知


在空间维度上,Qwen2.5-VL 不仅能够动态地将不同尺寸的图像转换为不同长度的 token,还直接使用图像的实际尺寸来表示检测框和点等坐标,而不进行传统的坐标归一化。这使得模型能够直接学习图像的尺度。在时间维度上,引入了动态 FPS (每秒帧数)训练和绝对时间编码,将 mRoPE id 直接与时间流速对齐。这使得模型能够通过时间维度 id 的间隔来学习时间的节奏。



更简洁高效的视觉编码器

视觉编码器在多模态大模型中扮演着至关重要的角色。我们从头开始训练了一个原生动态分辨率的 ViT,包括 CLIP、视觉-语言模型对齐和端到端训练等阶段。为了解决多模态大模型在训练和测试阶段 ViT 负载不均衡的问题,我们引入了窗口注意力机制,有效减少了 ViT 端的计算负担。在我们的 ViT 设置中,只有四层是全注意力层,其余层使用窗口注意力。最大窗口大小为 8x8,小于 8x8 的区域不需要填充,而是保持原始尺度,确保模型保持原生分辨率。此外,为了简化整体网络结构,我们使 ViT 架构与 LLMs 更加一致,采用了 RMSNorm 和 SwiGLU 结构。



下一步

在不久的将来,我们将进一步提升模型的问题解决和推理能力,同时整合更多模态。这将使模型变得更加智能,并推动我们向着能够处理多种输入类型和任务的综合全能模型迈进。


欢迎体验:

欢迎访问Qwen Chat (https://chat.qwenlm.ai) 并选择 Qwen2.5-VL-72B-Instruct 进行体验。


此外,我们也在 Hugging Face (https://huggingface.co/collections/Qwen/qwen25-vl-6795ffac22b334a837c0f9a5) 和 ModelScope (https://modelscope.cn/collections/Qwen25-VL-58fbb5d31f1d47) 上开源了 Qwen2.5-VL 的 Base 和 Instruct 模型,包含 3B、7B 和 72B 在内的 3 个模型尺寸,欢迎前往体验。

相关文章
|
监控 PyTorch 算法框架/工具
Qwen-VL怎么用自己的数据集微调
Qwen-VL怎么用自己的数据集微调
1658 0
|
7月前
|
JSON 文字识别 测试技术
Qwen2.5-VL Cookbook来啦!手把手教你怎么用好视觉理解模型!
今天,Qwen团队发布了一系列展示 Qwen2.5-VL 用例的Notebook,包含本地模型和 API 的使用。
2516 22
|
8月前
|
人工智能 编解码 JSON
Qwen2.5-VL:阿里通义千问最新开源视觉语言模型,能够理解超过1小时的长视频
Qwen2.5-VL 是阿里通义千问团队开源的视觉语言模型,具有3B、7B和72B三种不同规模,能够识别常见物体、分析图像中的文本、图表等元素,并具备作为视觉Agent的能力。
3610 18
Qwen2.5-VL:阿里通义千问最新开源视觉语言模型,能够理解超过1小时的长视频
|
7月前
|
JSON 文字识别 测试技术
超顶的视觉理解模型怎么用?Qwen2.5-VL Cookbook教会你!
超顶的视觉理解模型怎么用?Qwen2.5-VL Cookbook教会你!
|
9月前
|
JSON 文字识别 数据可视化
Qwen2-VL微调实战:LaTex公式OCR识别任务(完整代码)
《SwanLab机器学习实战教程》推出了一项基于Qwen2-VL大语言模型的LaTeX OCR任务,通过指令微调实现多模态LLM的应用。本教程详述了环境配置、数据集准备、模型加载、SwanLab集成及微调训练等步骤,旨在帮助开发者轻松上手视觉大模型的微调实践。
|
6月前
|
机器学习/深度学习 文字识别 测试技术
Qwen2.5-VL-32B: 更聪明、更轻量!
年前,阿里通义千问团队推出了 Qwen2.5-VL 系列模型,获得了社区的广泛关注和积极反馈。在 Qwen2.5-VL 系列的基础上,研究团队使用强化学习持续优化模型,并使用 Apache 2.0 协议开源 32B 这个备受喜爱的参数规模的新 VL 模型—— Qwen2.5-VL-32B-Instruct。相比此前发布的 Qwen2.5-VL 系列模型,本次推出的 32B 模型的特点如下:
2407 0
|
6月前
|
机器学习/深度学习 编解码 人工智能
Qwen2.5-VL Technical Report
Qwen2.5-VL是阿里云团队推出的Qwen系列最新旗舰模型,具备显著提升的基础能力和创新功能。它在视觉识别、对象定位、文档解析和长视频理解等方面实现突破,支持精准的边界框/点定位及复杂输入处理。通过技术创新如窗口注意力、动态帧率采样和绝对时间编码,该模型在多模态任务中表现出色,在多个基准测试中超越顶级闭源模型,适用于从边缘AI到高性能计算的广泛场景。